Instead of radar wave we are sending ultrasonic wave.
Ultrasonic water level sensor arduino code.
Open a new sketch file by clicking new.
This project is very basic.
Ultrasonic method is similar to radar.
S signal pin is an analog output pin and will always be connected to the analog inputs pin in arduino.
For water below the quarter level only led at pin 8 will be on.
Follow the circuit diagram and make the connections as shown in the image given below.
Incoming analog signal read and appointed sensor serial println sensor.
1 arduino uno r3.
Arduino water level indicator circuit.
1 ultrasonic sensor hc sr04 procedure.
Arduino water level indicator and control using ultrasonic sensor hc sr04r.
The ping sensor measures distance using sonar.
Anyone can do it.
Vcc pin is the power supply pin for the sensor.
This arduino water level indicator uses an ultrasonic sensor or ping sensor to determine the level of water in the tank.
Transmitter circuit transmitter circuit is shown in the figure below fig1 in this circuit an ultrasonic sensor is connected to pin d9 and d10 pin of arduino.
The circuit will do basically what the aforementioned one will do rather efficiently.
We made water level meter with arduino platform we used arduino mega2560 but any arduino will work.
Open the arduino ide software on your computer.
S this output goes to any analog signal on arduino.
Thus a 20cm is subtracted from the measured distance value.
Arduino water level sensor using ultrasonic sensor etc.
Materials needed for this arduino water level indicator and control using ultrasonic sensor hc.
Arduino water level sensor.
The ultrasonic module is placed 20cm above from the maximum water level.
Coding in the arduino language will control your circuit.
An ultrasonic well above human hearing pulse is transmitted from the unit and distance to target is determined by measuring the time required for the echo return.
We connect the sensor to an arduino and as per the changing water level new signal readings would be sent letting us know the level.
The water sensor has 3 output pins.
Communication started with 9600 baud void loop int sensor analogread a1.
And the leds on pin 9 10 11 gets on as the water level crosses the quarter half and three quarter heights respectively.
The recommended power of the water level sensor is between 3 3v 5v.
Wrote serial port let s prepare the circuit.
The ultrasonic sensor is not waterproof though so we will need to keep it protected.
Analog output will vary depending on the voltage provided to the sensor.
This procedure is ideal for our needs because ultrasonic sensors are accessible and low priced.