![]() Here we are using PORTB to connect to LCD data port (D0-D7). Software: Atmel studio 6.1, progisp or flash magic. ![]() Hardware: ATMEGA32, Power supply (5v), AVR-ISP PROGRAMMER, JHD_162ALCD (16x2LCD), 1000uF capacitor, 10KΩ resistor (2 pieces), HC-SR04 sensor. ![]() Here the width of the signal must be taken in multiple of uS(micro second or 10^-6). This distance is calculate as, distance (in cm) = width of pulse output (in uS) / 58. ![]() Now based on the parameters, sound speed (220m/s) and time taken for the echo to reach the source, it provides output pulse proportional to distance.Īs shown in figure, at first we need to initiate the sensor for measuring distance, that is a HIGH logic signal at trigger pin of sensor for more than 10uS, after that a sound vibration is sent by sensor, after a echo, the sensor provides a signal at the output pin whose width is proportional to distance between source and obstacle. The sensor here generates a sound vibration in ultrasonic range upon giving a trigger, after that it waits for the sound vibration to return. Ultrasonic sensor “HC-SR04” provides an output signal proportional to distance based on the echo. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |