A simple projects demonstrating use of Ultrasonic sensor to measure distance. This project make use of PIC microcontroller and 40Khz ultrasonic transducers pair for measuring distance from obstacle and displaying it on 7-Segment LED display.

The working of project is based on the simple phenomenon of sound traveling. The time from transmission of the pulse to reception of the echo is the time taken for the sound energy to travel through the air to the object and back again.

Since the speed of sound is constant through air measuring the echo reflection time lets you calculate the distance to the object using the DST equation :

Distance = (s * t)/2 (in metres)

You need to divide by 2 as the distance is the round trip distance i.e. from transmitter to object and back again.

The 40Khz signal is generated form controller itself and given to ultrasonic transmitter via amplifier circuit. Receiver part includes preamplifier, peak detector and threshold circuit.

Block Diagram of PIC Sonar

Circuit Diagram:

for complete theory and code visit PIC Sonar project page
Tags ultrasonic distance measurementPIC projectsPIC sonarpic interfacing ultrasonic sensor
printer friendly create pdf of this news item

Submit comment

(Required; Min length 5)
(Required; will not be displayed)



Fri Oct 07 2022, 09:29 pm
Fri Oct 07 2022, 03:53 pm
Thu Oct 06 2022, 12:42 pm
Thu Oct 06 2022, 04:39 am
Wed Oct 05 2022, 03:36 pm
Mon Oct 03 2022, 10:44 am
Mon Oct 03 2022, 08:23 am
Sun Oct 02 2022, 11:15 pm