This circuit along with ultrasonic sensor module HC-SR04 detects an object in front of it and gives a linear indication of the distance between the object and the sensor using output LED and a speaker. The speaker starts to make a sound when the object is 1m apart from the sensor as the object approaches nearer and nearer to the sensor the sound gets louder. This indicates that the intensity of sound is proportional to the distance between the object and the sensor.
How HC-SR04 ultrasonic module works?
The HC-SR04 sensor has one transmitter and one receiver. The transmitter produces ultrasound which has a frequency of 40KHz and therefore it's inaudible to human ears. The receiver is tuned to pick up ultrasound, as most of the objects reflect sound, the sound reflected back by the object in front of the sensor is detected by the receiver circuit. A signal proportional to the time it takes for sound to reach the object and then back to the receiver is generated by the echo pin of HC-SR04. This signal is a PWM signal, the pulse width increases as objects move far and decreases as the object moves nearer. This helps to determine the distance between the sensor and the object.
The trig pin of HC-SR04 needs to be given a low trigger pulse in order for the transmitter to generate ultrasound. Ultrasound is generated in bursts of 40KHz signal. This tells us that a periodic pulse generator ( astable multivibrator) is needed for the trig pin to keep the sensor active.
Supply is provided through the ground and VCC pins.
Circuit diagram and description.
The circuit shown above is of ultrasonic proximity indicator. It has three main blocks:-
- HC-SR04 sensor module.
- Astable multivibrator.
- High pass filter.
Astable multivibrator:- This part of the circuit is made by cascading two negative edge detectors. Its function is to provide trigger pulses to the trig pin of HC-SR04. The frequency of this signal is 1KHz. Switch S1 is used as a kick to start the oscillation when the circuit is first turned on.
Demo of astable multivibrator by cascading two negative edge detectors:-
High pass filter:- This is the final detection circuit to which the output led and speaker is connected. The circuit is similar to the negative edge detector circuit but here its role is completely different.
Here its function is to detect the change in pulse width of the signal coming from the echo pin. This circuit attenuates signal with low off-time and amplifies when the signal with high off-time.
On the output side along with a led, I have used a speaker of high impedance which I removed from the old landline telephone.
Applications.
- In industries to count objects passing on a conveyor belt.
- It can be used in robots to detect obstruction.
- Water level indicator.
- Intrusion alarm system.
If you found this blog useful and want to support me, then you can donate me. The money you give will be used to make more advance electronics projects and setting up better lab.
Comments
Post a Comment