Water level indicator is one of the most popular project over internet but the problem with that is, it uses metal electrode as a result corrosion is occur. When we pass DC current in water it starts to react with metal in presence of oxygen and corrosion is occur.
This problem is minimizing by using alternating current instead of direct current but there is always risk of electric shock which can be dangerous if is handled by non-technical person. By keeping this problem in mind, we had designed a ultrasonic water level meter which utilize wireless approach. Thus, there is no problem of corrosion, no more messy wires and receiver can be placed anywhere user found easy.
The circuit of Ultrasonic Water Level Meter presented below surmount the above flaw and display the water level in a 16×4 alphanumeric display for better visual effect. The project posted here is capable to measure the depth of water up to 4 meters with the accuracy of 5mm.
Circuit Description of Ultrasonic Water Level Meter
Talking about the construction of “Ultrasonic Water Level Meter” it uses microcontroller for processing. ATmega328 is an 8-bit microcontroller, ultrasonic sensor and 433 MHz RF module. As the project Ultrasonic Water Level Meter uses wireless approach it uses transmitter and receiver unit.
Transmitter Unit: The transmitter circuit is shown in figure 1. The entire circuit of transmitter is built around 8-bit microcontroller ATmega328, ultrasonic sensor, 433 MHz RF transmitter module and few other electronic components like resistors, capacitors etc. for working flawlessly.
Port D of ATmega328 is used to communicate with ultrasonic sensor. Trigger pin and echo pin of ultrasonic is connected to PD3 and PD4 (pin 5 and 6) of ATmega 328 respectively. Port B is used to communicate with 433 MHz RF transmitter module. DATA pin of 433 MHz transmitter module is connected to pin PB4 (pin 19) of ATmega328 as shown in circuit diagram. A spiral antenna is used here in order to increase the transmitter range of RF module.
Receiver Unit: The receiver circuit of Ultrasonic Water Level Meter is shown in figure 2. The entire circuit of receiver is built around 8-bit microcontroller. ATmega 328, 16×4 LCD module, 433 MHz RF receiver and few other electronics components like resistors, capacitors etc. for working flawlessly.
A 16×4 LCD module is used in this project in order to display results. Port D is dedicated for LCD and is configured in 4-bit mode by connecting higher bit data line of LCD (pin 11, 12, 13, and 14) to port PD5, PD6, PD7 and PB0 (i.e. pin 11, 12, 13 and 15) as shown in figure 2. Similarly, E and RS pin of LCD is connected to pin 5 and 6 of microcontroller ATmega328. The RW pin of LCD is grounded to perform write operation in LCD. Variable resistor VR1 is used to adjust the contrast of LCD. DATA pin of 433 MHz receiver module is connected pin 4.
RESET Circuit: ATmega328 is designed for power ON reset but sometime we need external reset circuit. The reset circuit for ATmega328 is designed using 10K pull up resistor, a switch and a capacitor. The value of capacitor is chosen such that it charges and make reset pin high for two machine cycles. Capacitor is connected in series to resistor.
Power Supply Circuit: The system is powered by two individual 12V battery supply i.e. one for transmitter unit while other for receiver unit. As we all know that most of the electronics components works on 5V thus the input voltage in need to convert. Thus, we had used a 5V series voltage regulator. Capacitor connected to output is used to filter out the ripple if any available.
Working of the Circuit:
- Burn program on ATmega328 using arduino bootloader and wire the entire circuit as shown in diagram.
- Fix the ultrasonic sensor on the top of tank say, in the middle of cap of tank.
- Connect power supply to both of unit.
- LCD shows the level of water tank with the accuracy of 5mm i.e. even change of water level in CM LCD shows the result.
- For accuracy, the reading is taken 8 times a seconds and average is shown in LCD.
- A counter is provided in right most side of LCD in order to show the transmitter circuit works properly and data is received.
- If transmitter and receiver fail to work, LED1 and LED2 connected to pin 19 of microcontroller stop blinking respectively.
Software: The software for ultrasonic water level meter is written in arduino programming language and compiled using arduino IDE. Click the link below to download software. The folder contains software code for transmitter, receiver and the required library file.
PARTS LIST OF ULTRASONIC WATER LEVEL METER
|Resistors (all ¼-watt, ± 5% Carbon)|
|R1, R3 = 330 Ω
R2, R4 = 10 KΩ
VR1 = 10 KΩ Potmeter
|C1, C2, C4, C5 = 22pF (Ceramic Disk)
C3, C8 = 470 µF, 25V (Electrolytic Capacitor)
C6 = 100Nf (Ceramic Disk)
C7 = 10 µF, 16V (Electrolytic Capacitor)
C9, C10 = 100nF (Ceramic Disk)
|IC1, IC3 = ATmega328P-PU MCU with Arduino Uno bootloader
IC2, IC4 = 7805, voltage regulator
TX1 = 433MHz RF transmitter Module
RX2 = 433MHz RF Receiver Module
LED1, LED2 = 5mm LED
Ultrasonic Module = HC-SR04
|BATT1, BATT2 = 12V Battery
ANT1, ANT2 = Spiral Antenna
XTAL1, XTAL2 = 16MHz Crystal Oscillator
LCD1 = 16×4 Alphanumeric Display
SW1, SW2 = Tactile Switch