Although ultrasonic sensors have been around for several decades, their popularity in sensing applications continues due to their capability, flexibility and relatively low cost. Products like unmanned aerial vehicles (drones), robots and (semi-) autonomous vehicles have only served to increase the need for this type of sensor.
It is important to be aware of how ultrasonic sensors are used, along with their benefits, to understand the continuing importance of ultrasonic sensors for object detection in today’s applications.
The basics of ultrasonic sensors
Comprised of a transmitter and receiver, an ultrasonic sensor produces a sound, or “chirp,” at a frequency that is normally in the 23-kHz to 40-kHz range. This is above the 20-kHz level that humans can generally hear, giving rise to the term “ultrasonic.”
Object detection is performed by a transmitter sending out a chirp that bounces off an object within range and the time elapsed for the echo to reach the receiver (co-located with the transmitter). Knowing that the speed of sound in the air is 343 meters/second, the distance traveled can be calculated easily, remembering to halve the distance as the chirp has traveled “there and back.”
Distance = (elapsed time × speed of sound) ÷ 2
Units can be changed to suit a particular application or situation as needed. However, the basic formula reflects the simplicity of the principles behind the operation of ultrasonic sensors.
Jeff Smoot, vice president of engineering at CUI Devices discusses the basics of ultrasonic sensors, where they are used, and what specs are most important. If you haven’t thought about using ultrasonic sensors, Jeff fills us in on the benefits of these devices in new applications like IoT. – Gina Roos, editor-in-chief, Electronic Products.
Ultrasonic sensor operation
Ultrasonic sensing requires two fundamental elements: a transmitter and a receiver. They are co-located as close together as possible to reduce errors caused by the transmit and echo paths not being perpendicular to the object being detected. These errors can be reduced by using ultrasonic transceivers that integrate the transmitter and receiver into a single unit, which also significantly reduces the space occupied by the sensing solution.
The chirps generated by the transmitter have more in common with spread beam light from a flashlight than the coherent light from a laser, so designers must consider the spread and beam angle. As the chirps propagate further from the sensor, they cover a wider area in terms of height and width, which is why coverage specifications are quoted in terms of beam width or beam angle as opposed to a numeric detection area.
Different manufacturers use different methods to specify beam angle, so when selecting a suitable option, designers must establish whether the datasheet provides the full angle of the beam or the angle of variation from a straight line.
The angle of the beam, however it is expressed, also has an impact on the overall range of the device. In general, the narrower the beam, the greater the detection range. This is because the chirp energy is more focused and can travel further before it dissipates to an unusable level.
The decision as to which beam angle to use is an important decision and is application-related. Wide beams are better for general detection, while narrow beams avoid false positives by narrowing the detection area.
Ultrasonic transducers can be sourced either as a transmitter/receiver pair or as a single unit combining both parts—commonly referred to as an ultrasonic transceiver. Analog types are actuated by a signal to the transmitter, while the receiver returns a signal when the chirp’s echo is detected. By modifying the drive circuit, designers can adjust pulse length and include encoding as needed by the application. Analog ultrasonic sensors require a timer circuit (or a host controller) to carry out the timing necessary to determine distance.
However, digital ultrasonic sensors integrate the timing and decoding into the receiver and can simply report the distance to a host microcontroller, often over a standardized communication bus.
In most cases, the ultrasonic components are sourced as discrete components and then incorporated into a design. It is also possible to purchase subassemblies that include a PCB and other components, preconfigured as a basic range finder. These modules are useful for less experienced designers, eliminating design risk and speeding time to market, but the tradeoff is limited flexibility.
Pros and cons
In common with all technologies, ultrasonic sensors suit some situations and applications better than others.
Pros
- Ultrasonic sensors detect any solid material and transparent materials, such as water, glass and acrylic, regardless of their color.
- A wide choice of detection ranges—from a few centimeters to about 5 meters, although distances up to 20 meters are possible.
- The technology is well-established over several decades.
- Measurements are precise, and 1% accuracy or better is typical.
- Measurements can be made multiple times per second, which is useful for tracking moving objects.
- Components are generally inexpensive, as they do not incorporate rare materials.
- Because they are based on sound, they work well in electrically noisy environments, especially when chirps contain some form of encoding.
Cons
- They are dependent upon the speed of sound for measurement accuracy; therefore, temperature and humidity can affect measurements to an extent.
- They can detect an object within the sensing area but are unable to detect the precise location within the sensing area. Also, they cannot detect features like color or shape.
- They are relatively small and ideal for larger applications, such as vehicles, but can be too large for some projects.
- In outdoor applications, they can become wet, frozen or dirty—all of which will affect performance and/or cause erratic behavior.
- They cannot work in a vacuum because they use sound waves.
Recommended
Ultrasonic sensors find new applications in IoT
Typical applications for ultrasonic sensors
One of the most common applications for ultrasonic sensors is non-contact sensing of liquid levels in a tank or other container. They can detect any liquid irrespective of color or opacity and are especially useful with food-grade liquids because no contact is needed to make the measurement.
Another common application is object detection. This is a very wide application area and can include parking detectors on cars, guidance for autonomous vacuum cleaners or mowers, people detection, detecting/counting objects on moving belts and intruder alarms, to name just a few.
While these are the two most common types of applications, more unique uses involve using transmitters and receivers separately. Because the sound produced is outside the range of human hearing but within the range of many animals, they can be used to scare off unwanted animals. As an example, an ultrasonic solution can be used as a bird deterrent near airport runways. The detectors can be used alone as simple noise detectors, detecting noises that humans cannot hear with the naked ear.
Ultrasonic sensor technology is well-established, developed over several decades, so they are widely available and well-understood. Despite their longevity, they continue to be extremely relevant in many of today’s applications, especially in all types of autonomous vehicles, from lawnmowers to cars.
A combination of simplicity, low cost and robustness makes them a popular solution for all types of presence-detection, distance-measurement or object-counting applications, while their ability to be adapted and configured broadens their use significantly.
About the author
Since joining CUI Devices in 2004, Jeff Smoot, VP of engineering at CUI Devices, has revitalized the company’s quality and engineering departments with an emphasis on developing, supporting and bringing products to market. With a focus on the customer’s success, he also spearheaded the establishment of an application engineering team to provide enhanced in the field and online engineering design and technical support to engineers during their design process. Outside of the office, Jeff enjoys the outdoors (skiing, backpacking, camping), spending time with his wife and four children, and being a lifelong fan of the Denver Broncos.
Learn more about CUI Devices