Sign In

Published by on

For sensing distance to obstacles, an HC-SR04 sensor module has been used. It has an ultrasonic transducer which generates the ultra sonic waves, an ultra sonic receiver and control circuitry built on a small PCB.

hcsr04 sensor

Front View of HC-SR04

hcsr04 sensor

Back View of HC-SR04

For interfacing with microcontroller it provides two lines namely TRIGGER and ECHO. The trigger pin is an input pin, the MCU sends a 10uS high pulse on this line to tell the HC-SR04 to start a taking a measurement.

triggering an HC-SR04 from PIC MCU

As soon as the HC-SR04 receives this pulse it sends out ultrasonic waves and waits for it to goto the obstacle and come back to the sensor. The sensor then emits a pulse on the ECHO line whose width is equal to this time. By simple calculation we can find the distance to obstacle.

hcsr04 echo pulse

Three such such sensors are used in this project to find obstacle in front, left and right of the user.

triple hcsro4

We cordially thanks the following peoples who shared this page on various social networks and insprided us to develop more quality contents!

Sai Sudha, Kavya, Shivam Kumar, Meenu, Shailesh, , Luis, Ahroke, Avinash Gupta,

Comments