There are two kinds of ultrasonic sensors

a) Propagation-Path Sensors

 decode changes on propagation to get a fast measurement of temperature, pressure variations or gas concentration. 

b) Distance-Sensors

 detect echoes from objects and evaluate their propagation time and amplitude. Examples are distance meters and presence detectors. 

I will report only about Ultrasonic Distance-Sensors

They measure the presence of stationary or moving objects. Mostly the distance, position and level.

Their advantage is their

  1. excellent long term stability
  2. low power consumption
  3. low cost realization
  4. directional sensitivity
  5. the high structural resolution due to the large bandwidth (from 1.7 to 50 feet depending on model)
  6. remote measurement
  7. nothing touches the target
  8. sensitivity to all kinds of objects
  9. resistance to wetness, dirt or wear
  10. the texture, color or opacity of an object are generally not a problem.

Example of the PING)))TM Ultrasonic Distance Sensor (#28015) by ParallaxBig text

That's how you connect your sensor

Theory of Operation

The PING))) sensor detects objects by emitting a short ultrasonic burst and then "listening" for the echo. Under control of a host microcontroller (trigger pulse), the sensor emits a short 40 kHz (ultrasonic) burst. This burst travels through the air at about 1130 feet per second, hits an object and then bounces back to the sensor. The PING))) sensor provides an output pulse to the host that will terminate when the echo is detected, hence the width of this pulse corresponds to the distance to the target.

This test was made in the Parallax lab,
with room temperature, indoors,
on linoleum floor to minimize floor reflections in the data.
The Sensor was connected to a BASIC Stamp microcontroller module.

graphics from:



ONE First Model Mini A: 0-5 VDC 10 bit analog output with fully independent zero and span adjustments over the entire operating range.
Then TWO Model Mini S: adjustable NPN open collector outputs; transistors are continuously energized during detection period.

weight requirements: 8-16 VDC; 30 ma maximum current.


  1. What does the "gain set" do?
  2. What does Zero Pot and Full Scale Pot stand for?
  3. What is the "Common" button for?
  4. What's a NPN open collector output?

this datasheet was taken from

Parameter and Value
Required Current............................ 30 mA
DC Voltage Operating Range...........DC 8 -16V
Output Range..................................0-5VDC
Sensor Distance Range....................6" - 10' adjustable
Operating Temperature.................-40 to 85C

The most important part is the transducer.

graphics from