### Dual ultrasonic sensors combine for 2D echolocation

Ultrasonic sensors are great tools for measuring linear distance or object presence. As shown in this experiment by “lingib,” two sensors can also be combined to determine not just linear distance to a sensor, but its position in an X/Y plane.

For his experiment, he hooked two of these units up to an Arduino Uno at a known distance from each other, with one emitter blanked out with masking tape. The non-blanked emitter pulses an ultrasonic signal, which is bounced back to it as well as the second sensor by the measured object. From the time it takes to receive the return signal, distance to each sensor can be inferred, giving a triangle with each side known. Trigonometry is then used to pinpoint the item’s position, and a Processing sketch displays coordinates on lingib’s computer.

This Instructable explains how to pinpoint the location of an object using an Arduino, two ultrasonic sensors, and Heron’s formula for triangles. There are no moving parts.

Heron’s formula allows you to calculate the area of any triangle for which all sides are known. Once you know the area of a triangle, you are then able to calculate the position of a single object (relative to a known baseline) using trigonometry and Pythagoras.

The accuracy is excellent. Large detection areas are possible using commonly available HC-SR04, or HY-SRF05, ultrasonic sensors.

Construction is simple … all you require is a sharp knife, two drills, a soldering iron, and a wood saw.