Water Level Monitoring of House Overhead Tank from Anywhere in the World
1384 6
AKSHAY BADHE

Water Level Monitoring of House Overhead Tank from Anywhere in the World

In buildings, bungalows, etc water is stored in overhead tanks. Overhead tanks ensure continuous...

Description:-

In buildings, bungalows, etc water is stored in overhead tanks. Overhead tanks ensure continuous flow of water to our homes so that various devices like washing machines, purifiers can work. The water in these tanks needs to be regularly monitored. This has to be done by climbing to the top of the building every time and then check the water level which is a tedious process. In order to make it easier I have made this project using which we can monitor the level of water just by using our mobile phone that to from anywhere in the world. The only thing that we need is a WiFi network in the vicinity of our tank. I made this project using a Nodemcu esp8266 wifi module, ultrasonic sensor, and blynk app. Ultrasonic sensor is used for the distance measurement by sending ultrasonic waves. Nodemcu processes the data and gives us the distance which is sent to the blynk app over the internet by wifi module. Also, we can use relay module in order to control the motor to fill the tank, sitting anywhere in the world. It was not possible for me too illustrate this. But yes we can not only just monitor the water level but also fill the tank from anywhere in the world.

Project Used Hardware

NODEMCU Esp8266 WiFi module, Ultrasonic sensor, container (water tank)

Project Used Software

Blynk app, Arduino ide

Project Hardware Software Selection

Overhead Tank Hardware

NODEMCU is the main part of the project. It not only processes the raw data from the sensor but also sends the distance measured, over the internet to the blynk server or the app on our mobile. ULTRASONIC SENSOR is used for the distance measurement using ultrasonic waves. The transmitter emits ultrasonic waves which collide with water surface and reflect back after sometime which are then received by receiver and the distance is calculated using the relation distance=speed X time. CONTAINER to store the water. ARDUINO IDE is used to program the Nodemcu module. BLYNK APP is used to display the distance measured which can be viewed from anywhere.

Circuit Diagram

Overhead Tank Circuit Diagram

The Trig pin of sensor is connected to the D1 pin of the Nodemcu. Echo pin is connected to the pin D2 of Nodemcu. Vcc is connected to power supply of 5V. Gnd is connected to the ground of supply.

Code

#define BLYNK_PRINT Serial 
#include <Blynk.h> 
#include<ESP8266WiFi.h> 
#include<BlynkSimpleEsp8266.h>   
BlynkTimer timer;   
char auth[]="WnTu5G_WiGe8dlE12UzXAwFgHXqnS1YZ"; 
char ssid[]="$$$$Akboss$$$$"; 
char pass[]="akboss07";   
int trig=D1; 
int echo=D2; 
int duration; 
int distance;    
void setup() { 
  Blynk.begin(auth,ssid,pass); 
  Serial.begin(9600); 
  pinMode(trig,OUTPUT); 
  pinMode(echo,INPUT); 
  timer.setInterval(1000L,sensor); 
}   
void loop() { 
  Blynk.run(); 
  timer.run();   
}  
void sensor(){ 
  digitalWrite(trig,LOW); 
  delayMicroseconds(2); 
  digitalWrite(trig,HIGH); 
  delayMicroseconds(10); 
  digitalWrite(trig,LOW); 
  duration=pulseIn(echo,HIGH); 
  distance=duration*0.034/2; 
  Serial.print("Distance:"); 
  Serial.println(distance); 
  Blynk.virtualWrite(V0,distance);    
}