SNS-US020 is low cost ultrasonic sensor, perfect for your next robot project. It measures the distance by sending ultrasonic waves and reading back when the reflected wave. SNS-US020 operates with 5V and requires only 3mA in active mode. Note that for best results the reflection must be in hard surface, soft surfaces tend to absorb ultrasonic waves and weak the reflected signal. Can be used directly with Arduino with the provided code. Works perfectly up to 200 cm. All claims you will see on the net for similar devices that works up to 4-7 meters are false, so small sender/receiver can't achieve such distance in real world.
SNS-US020 operation is as follows: If trigger input is held high for more than 10 uS tthe module sends 8 pulses with 40kHz and listen to receive the reflected signal, then calculates the distance assuming speed of sound 340m/s. No temperature compensation is used for the calculation so there is error in the measurement depend on ambient temperature. In software section there is simple Arduino code project where musical instrument is made with two sensors, moving your hands in the front of the sensors change generated tone pitch and frequency, so you can play music by moving your hands.