IoT Projects
Dec 02, 2021

HC-SR04 Ultrasonic Sensor

This is the HC-SR04 ultrasonic distance sensor. This economical sensor provides 2cm to 400cm of non-contact measurement functionality with a ranging accuracy that can reach up to 3mm. Each HC-SR04 module includes an ultrasonic transmitter, a receiver and a control circuit.

There are only four pins that you need to worry about on the HC-SR04: VCC (Power), Trig (Trigger), Echo (Receive), and GND (Ground). You will find this sensor very easy to set up and use for your next range-finding project!

This sensor has additional control circuitry that can prevent inconsistent "bouncy" data depending on the application.

HC-SR04 Sensor Features

- Operating voltage: +5V

- Theoretical  Measuring Distance: 2cm to 450cm

- Practical Measuring Distance: 2cm to 80cm

- Accuracy: 3mm

- Measuring angle covered: <15°

- Operating Current: <15mA

- Operating Frequency: 40Hz

HC-SR04 Ultrasonic Sensor - Working

As shown above the HC-SR04 Ultrasonic (US) sensor is a 4 pin module, whose pin names are Vcc, Trigger, Echo and Ground respectively. This sensor is a very popular sensor used in many applications where measuring distance or sensing objects are required. The module has two eyes like projects in the front which forms the Ultrasonic transmitter and Receiver. The sensor works with the simple high school formula that

Distance = Speed × Time

The Ultrasonic transmitter transmits an ultrasonic wave, this wave travels in air and when it gets objected by any material it gets reflected back toward the sensor this reflected wave is observed by the Ultrasonic receiver module as shown in the picture below

Now, to calculate the distance using the above formulae, we should know the Speed and time. Since we are using the Ultrasonic wave we know the universal speed of US wave at room conditions which is 330m/s. The circuitry inbuilt on the module will calculate the time taken for the US wave to come back and turns on the echo pin high for that same particular amount of time, this way we can also know the time taken. Now simply calculate the distance using a microcontroller or microprocessor.

Applications

- Used to avoid and detect obstacles with robots like biped robot, obstacle avoider robot, path finding robot etc.

- Used to measure the distance within a wide range of 2cm to 400cm

- Can be used to map the objects surrounding the sensor by rotating it

- Depth of certain places like wells, pits etc can be measured since the waves can penetrate through water

Roger

Roger

Hello! My name is Roger Chung I'm a Electromechanical Engineer and Full Stack Developer. I am passionate about technology, especially in the creation of web application about Internet of Things and Machine Learning.

Leave a Reply

Related Posts

Categories