Download as pdf or txt
Download as pdf or txt
You are on page 1of 43

IOT BASED WATER CONTROLLING AND MONITORING SYSTEM USING

AN ARDUINO

Thesis submitted to the SASTRA Deemed to be University


in partial fulfillment of the requirements
for the award of the degree of

Submitted by

KAMALI.D (121006032)
PUSHKARANI.T.L(121006060)

JUNE 2021

SCHOOL OF ELECTRICAL & ELECTRONICSENGINEERING


THANJAVUR, TAMIL NADU, INDIA – 613 401

i
SCHOOL OF ELECTRICAL & ELECTRONICS ENGINEERING
THANJAVUR – 613 401

Bonafide Certificate

This is to certify that the thesis titled “IOT Based Water Controlling and Monitoring System Using

An Arduino” submitted in partial fulfillment of the requirements for the award of the degree of B. Tech.

Electronics & Instrumentation Engineering to the SASTRA Deemed to be University, is a bona-fide

record of the work done by

1. KAMALI.D (121006032)

2. PUSHKARANI.T.L (121006060)

during the final semester of the academic year 2020-21, in the School of Electrical & Electronics

Engineering, under my supervision. This thesis has not formed the basis for the award of any degree,

diploma, associateship, fellowship or other similar title to any candidate of any University.

Signature of Project Supervisor :


Name with Affiliation : Dr. G.Balasubramanian(SAP / EIE / EEE)

Date :

Project Viva-voce held on

Examiner1 Examiner2

ii
SCHOOL OF ELECTRICAL & ELECTRONICS ENGINEERING
THANJAVUR – 613 401

Declaration

We declare that the thesis titled “IOT Based Water Controlling and Monitoring System Using
An Arduino” submitted by us is an original work done by us under the guidance of
Dr.G.Balasubramanian, SAP / EIE / EEE, School of Electrical & Electronics Engineering,
SASTRA Deemed to be University during the final semester of the academic year 2020-2021, in the
School of Electrical & Electronics Engineering. The work is original and wherever we have used
materials from other sources, we have given due credit and cited them in the text of the thesis. This
thesis has not formed the basis for the award of any degree, diploma, associate-ship, fellowship or
other similar title to any candidate of any University.

Signature of the candidate(s) : D.Kamali


T.L.Pushkarani

Name of the candidate(s) : KAMALI.D(121006032)


PUSHKARANI.T.L (121006060)

Date :

iii
ACKNOWLEDGEMENT

First and foremost, we are thankful to God Almighty for giving us the potential and strength to
work on this project fruitfully. I express our gratitude to Dr.S.VAIDHYASUBRAMANIAM,
Vice-Chancellor, SASTRA Deemed to be University for providing us with an encouraging
platform for the course of study.

We also thank Dr. R. CHANDRAMOULI, Registrar, SASTRA Deemed to be University, for


providing us the opportunity to work in the SEEE, SASTRA Deemed to be University for the
course of the work.

We render our solicit thanks to Dr. K. THENMOZHI, Dean, SEEE and I respect and thank
Dr.A.KRISHNAMOORTHY, Associate Dean, EIE for providing us an opportunity to do
the project work and giving us all support and guidance which made me complete the project
duly.

We owe a debt of earnest gratitude towards our guide Dr.G.Balasubramanian, SAP, EIE
for his continued support and guidance throughout the course of our work. The intriguing
questions raised by our panel members helped us in shaping this project to its worth.

We also extend our sincere thanks to our parents and friends for their continuous moral
support and encouragement, along with our guide, this work would not have been what it is
today.

iv
LIST OF FIGURES

Figure No Name of The Figure Page


No
3.1 Arduino nano pin out description 5
3.2 Arduino nano pin details 6
3.3 LCD display module 7
3.4 Water Flow sensor YF- S201 8
3.5 YF – S201 water flow sensor pin details 8
3.6 Solenoid valve 9
3.7 Relay working 10
3.8 Relay module with pin description 11
3.9 NPN relay switch circuit 12
3.10 Two channel relay 12
3.11 ESP12E module 13
3.12 ESP32 pin out diagram 13
4.1 Proposed block diagram 15
4.2 Overall circuit connection diagram 17
4.11 Overall hardware module 19
6.1 Output for rate and volume of water flow 29
6.2 Output for alert notification in mail 30
6.3 Output in IoT platform 30
6.4 Overall output of the system 31

v
LIST OF TABLES

Table. No Table. Name Page.no


3.1 Technical requirements of Arduino nano 6
3.2 LCD pin description 7
3.3 Specifications of NODE MCU 13

vi
ABBREVIATIONS

SV Solenoid Valve
AS Alert System
LCD Liquid Crystal Display
IoT Internet of Things

vii
ABSTRACT

Key words: Water Distribution, Distribution Monitoring, Control, Email Notification, LCD

Water is one of humanity's most prized possessions. However, the water level of natural resources is
rapidly dwindling and the demand for water is growing as a result of reduced rainfall. Residential development
has increased water demand to meet everyone’s needs and people use water for a variety of activities depending
on their needs.

As a result, this project is used to track the flow of water level using a flow sensor and control a valve
to maintain a water level in a main water tank, as well as it sends real-time warning alerts to users via email.
This proposed scheme is primarily applicable to apartment buildings and residential colonies in society.

The aim of this project is to improve water storage, control, and distribution in order to conserve water
and make effective use of it. This proposed device is constructed in such a way that it can continuously track
the available water level. The proposed system has been implemented using an embedded system, with
communication through IoT. As a result, this proposed device will be useful for monitoring and controlling
water using Arduino and a Wi-Fi module via an IoT platform.

A municipal government concerned about the areas it governs cannot physically send an individual to
monitor each and every family's water consumption every day. As a result, they can easily monitor the amount
of water consumed by the residents of that city.

The local government can know the level of water in real time and fill the tank on time by installing IoT
based water level monitoring systems in all of the important municipal water tanks. They can also understand
the water consumption in the region by installing IoT-based water level monitoring systems in all of the
important municipal water tanks. Higher-level governments will use these collected data to draw national-level
conclusions about water consumption.

It will also give users an email update, acting as a warning system for the users and the range and volume
of flow will be displayed on the LCD monitor. If the water level rises above the limit given in the code, the
buzzer will sound to warn the user that they have reached their daily limit of water. As a result, the new system
would be beneficial to both the government and individuals who need to track and regulate the water level in
tanks.

viii
TABLE OF CONTENTS

ACKNOWLEDGEMENT……………………………………………………...…………..iv
LIST OF FIGURES…………………………………………………..……………………..v
LIST OF TABLES……………………………………………………………...…..............vi
ABBREVIATIONS…………………………………………………………………...........vii
ABSTRACT………………………………………………………………………..…..…..viii
CHAPTER 1 INTRODUCTION……………………………………………………….......3
CHAPTER 2 REVIEW OF LITERATURE………………………….…………………...4
CHAPTER 3 HARDWARE SPECIFICATION…………………………………………..5
3.1 ARDUINO NANO ……………………………………………………………………....5
3.1.1 ARUDINO NANO PIN OUT DESCRIPTION…………………………………..…….5
3.1.2 FEATURES OF ARDUINO…………………………………………………………....5
3.1.3 TECHNICAL DETAILS……………………………………………………………….6
3.2 LCD DISPLAY…………………………………………………….……………………..6
3.2.1 LCD DISPLAY MODULE……………………………………………………………..6
3.2.2 LCD PIN DESCRIPTION…………………………………………………….………..7
3.3 FLOW SENSOR……………………………………………………………………….…8
3.4 SOLENOID VALVE……………………………………………………………..………9
3.5 RELAY …………………………………………………………………………………10
3.5.1 RELAY WORKING ……………………………………………………………….....10
3.5.2 RELAY TERMINOLOGY……………………………………………………………10
3.5.3 5 - PIN RELAY……………………………………………………………………….11
3.5.4 NPN RELAY SWITCH CIRCUIT……………………………………………………11
3.6 NODE MCU ……………………………………………………………………………12
3.6.1 NODE MCU – ESP-12E MODULE………………………………………………….12
3.6.2 NODE MCU ESP32 SPECIFICATIONS…………………………………………….13

1
CHAPTER 4 METHODOLOGY………………………………………………………14
4.1 WATER DISTRIBUTION SYSTEM………………………………………………...14
4.1.1 PROPOSED METHODOLOGY BLOCK DIAGRAM ……………………………15
4.2 ARDUINO NANO……………………………………………………………………14
4.3 FLOW SENSOR……………………………………………………………………...14
4.4 CONTOL VALVE …………………………………………………………………..15
4.5 RELAY CONTROL………………………………………………………………….15
4.6 IOT MODULE – NODE MCU………………………………………………………16
4.7 BUZZER ALERT…………………………………………………………………….16
4.8 EMAIL ALERT………………………………………………………………………16
4.9 OVERALL CIRCUIT DIAGRAM…………………………………………………...17
4.10 CIRCUIT DESCRIPTION………………………………………………………….18
4.11 OVERALL HARDWARE MODULE………………………………………………19
CHAPTER 5 ARDUINO CODE……………………………………………………….20
5.1 ARDUINO CODE……………………………………………………………………20
5.2 WIFI CODE…………………………………………………………………………..24
CHAPTER 6 RESULTS AND DISCUSSIONS………………………………………….28
6.1 OUTPUT FOR RATE OF FLOW AND VOLUME OF WATER…………………...28
6.2 OUTPUT FOR ALERT NOTIFICATION IN MAIL………………………………...29
6.3 OUTPUT IN IOT PLATFORM……………………………………………………....29
6.4 OVERALL OUTPUT OF THE SYSTEM……………………………………………30
CHAPTER 7 CONCLUSION…………………………………………………………..31
CHAPTER 8 REFERENCES……………………………………………………….….32
CHAPTER 9 SIMILARITY REPORT………………………………………………..34

2
CHAPTER 1

INTRODUCTION

Drinking water utilities in today’s world faces a variety of challenges in real time as a result of dwindling
water supply, global warming, population growth and pollution. As a result, better methodologies for real-time
water distribution monitoring and controlling are needed.

Water distribution is one of the problems that is not taken seriously in urban areas. There are several
problems which is concerning about water. A minor problem is a battle between residents of apartments over
who gets water according to their needs. This project will describe the system that will supply water in
channelized form from the first to the last user in each block.

A solenoid valve can assist in regulating the flow rate of water when it exceeds a predetermined limit.
By controlling the solenoid valve turning ON and OFF, water is supplied for a set period of time at the necessary
flow rate.

Another option we considered was that there might be a greater need for water on occasion. In such
situations, you can send a message requesting more water and the amount of water you receive will be
determined by the available water storage. The system can keep track of how much water is being used and
how much storage space is available at the central location.

For source of water surveillance and water plant service, online water monitoring technologies have
been made considerable progress. The installation and calibration of a large distributed array of monitoring
sensors using their technologies has a high cost. The algorithm proposed on the latest technology must be
suitable for a specific environment.

This project designed and built with a low-cost system for real-time water delivery, monitoring and
controlling using IoT by focusing on the mentioned issues. Flow sensors are used to calculate the physical
distribution parameters of the water in our design. The central controller processes the sensed values.

This project's central controller is an Arduino NANO. The Node MCU module connects to the internet
and accesses the processed data from the core controller. With a special Thing Speak IoT account, the sensed
data can be viewed in an internet browser. IoT is used to monitor the flow of water in the pipeline based on the
consistency of the water in the web page. Furthermore, the controlling and monitoring is done via mobile using
Wi-Fi provided by the IoT module.

3
CHAPTER - 2

REVIEW OF LITERATURE

IoT-Based Framework for Smart Water Supply Systems Management

Rosiberto Gonçalves, Jesse J. M. Soares and Ricardo M. F. Lima – “An IoT-Based Framework for Smart
Water Supply Systems Management”, MDPI journal, Future Internet, 2020.
In this paper, a web based mobile application consisting of so many options for the user to
record the flow rate using flow sensor and to transmit the same to remote monitoring station
using IoT and it is also provided with electronically operated solenoid valve to supply water to
consumers. The valve turns on/off by the central processing unit Arduino Nano to stop the
water supply whenever the flow rate exceeds a predefined limit. This project deals with
automated monitoring and controlling the flow rate of water along with it can be automatically
shut ON/OFF the valve.

Real Time Internet of Things (IoT) Based Water Quality Management System

Saif Allah H, AlMetwally and et al – “Real Time Internet of Things (IoT) Based Water Quality Management
System”, Science Direct, 2020.
The objective of the project is continuous and real time monitoring of water supply
in IoT platform. Water supply with continuous monitoring makes proper distribution so that, we
have a record of available amount of water in tanks, flow rate, abnormality in distribution line using
different sensors with controllers and arduino nano as minicomputer can monitor data and control
application operation from cloud with efficient client server communication.

IOT based water distribution system

D.Devasena, R.Ramya, T.Darshan and et al - “IOT based water distribution system”, International Journal of
Engineering and Advanced Technology(IJEAT), Volume – 8, Issue-6, August – 2019.
In this paper, the user to record the flow rate and controlling the water in the tank to monitoring
the overhead tanks i.e filling the water tanks or stopping the pumping based on the available
water level and monitoring the distribution of water. And proposed a methodology for ensuring
the water level in the tank with help of the flow sensor. This result show that the proposed
system has good feasibility. It reduces the cost of monitoring and controlling system at the
same time.

IOT based smart water management, monitoring and distribution system for an apartment

Navin Rapelli - MIT - AOE, Alandi Pune, Maharashtra, India – “IOT based smart water
management, monitoring and distribution system for an apartment”, Proceedings of the Fourth
International Conference on Communication and Electronics Systems, IEEE Conference, 2019.
Based on the current situation of the urban water cycle based systematic use of information
technology infrastructure and environmental sensor technologies. As means of evaluating
urban water cycles, this study proposed an evaluation equation that can be used to evaluate the
water flow, level to monitor and control the water from tank and supplied to individual houses.
Which have become affected by urbanization and industrialization and proposed a
methodology for ensuring the flow and level of water cycle to be supplied to apartment are
monitored and controlled by following urban development, we put forward a monitoring
hardware system is composed of Arduino, flow sensor is used.

4
CHAPTER 3
HARDWARE SPECIFICATION

3.1 ARDUINO NANO


The Arduino Nano has similar features to the Arduino UNO, but it comes in a different box. The
Nano, like the Arduino UNO, has an ATmega328P microcontroller built in. The key difference is that the UNO
board comes in a PDIP (Plastic Dual-In-line Package) with 28 pins, while the Nano board comes in a TQFP
(plastic quad flat pack) with 32 pins. The extra two pins on the Arduino Nano are used for ADC functionality;
while the Arduino UNO has six ADC ports, the Nano board has eight ports.

The Nano board lacks the DC power jack found on other Arduino boards, instead it is opting for a mini-
USB connector. This port is used for serial control as well as programming. Nano has a fascinating feature in
that, it can choose the strongest power source based on its possible difference and the power source selector
jumper is ineffective.

3.1.1 ARDUINO NANO PINOUT DESCRIPTION


The fig 3.1 shows all the functionalities of each pin using the pin-out diagram below as a guide.

Fig – 3.1 Arduino NANO Parts

3.1.2 FEATURES OF ARDUINO


• Arduino's Flash Memory is 32 KB
• Static RAM is 2 KB
• EEPROM is 1 KB
• Arduino's CLK Speed is 16 MHz
5
We can deduce from the figure – 3.2 that the Arduino Nano has a total of 36 pins. Fig 3.2 shows all of
the pin section by section, as well as a comprehensive style of the board.

Fig – 3.2 Arduino NANO Pin Details


3.1.3 TECHNICAL DETAILS
Table 3.1: Technical Details Of Arduino Nano
Parameters Specifications
1) At mega 328 Microcontroller
2) Digital I/O pins 14
3) Operating voltage 5 volt
4) Input voltage 7 – 12 volt
5) Clock speed 16 MHz
6) Analog input pin 8

3.2 LCD DISPLAY


3.2.1 LCD DISPLAY MODULE
16X2 LCD (Liquid Crystal Display) is an electronic display module. In this proposed system, LCD is
used to display the alert message when volume of water used by the user exceeds a limit (> 1Litre) which is
coded in the Arduino code. And also it displays the rate of flow of water for 2 houses as for this proposed
system.

6
Fig 3.3 LCD Display Module

3.2.2 LCD PIN DESCRIPTION


Table – 3.2: LCD Pin description
Pin
Function Name
No
1 Ground (0V) Ground
2 Supply voltage; 5V (4.7V – 5.3V) Vcc
3 Contrast adjustment; through a variable resistor VEE
4 Selects command register when low; and data register Register
when high Select
5 Low to write to the register; High to read from the Read/write
register
6 Sends data to data pins when a high to low pulse is Enable
given
7 DB0
8 DB1
9 DB2
10 DB3
8-bit data pins
11 DB4
12 DB5
13 DB6
14 DB7
15 Backlight VCC (5V) Led+
16 Backlight Ground (0V) Led-

The table 3.2 shows the pin out description of the LCD display module

7
3.3 FLOW SENSOR
Large industrial operational, commercial and residential structures, all demands a lot of water. This
requirement is met by using the municipal water supply system. The rate of flow of water must be determined
in order to monitor the amount of water supplied and utilized. For this, water flow sensors are employed.

Fig – 3.4 Water Flow Sensor YF-S201


The figure 3.4 shows the YF – S201 flow sensor. Water flow sensors are installed at the water source or
pipes to compute the amount of water passed through the pipe by measuring the rate of flow. The rate of flow
of water is expressed in liters per hour or cubic meters.
Using water flow sensor YF-S201 with Arduino to measure the water or liquid flow is quite straight
forward, this Article discuss the water flow sensor and how does the water flow sensor operates and how to
connect it to Arduino or other controller. Water is crucial to all needs, thus this article will show you how to
build water flow meter to monitor the volume of water flowing through pipelines.

Fig – 3.5 YF-S201 Water Flow Sensor Pin Details

The figure 3.5 shows the pin details of water flow sensor. With only three wires, this water flow sensor
may be readily interfaced with any microcontroller or Arduino board. It requires only the sensor has to be fitted
between water pipelines and it simply requires +5V VCC to give pulse output.

8
With each revolution, an embedded magnetic Hall-Effect sensor generates an electrical pulse.
The Red/VCC (5-24V DC Input), Black/GND (0V) and Yellow/OUT are the three wires that comes with
“YFS201 Hall Effect Water Flow Sensor” (pulse output). Using a proper conversion method, we can simply
calculate the water flow rate (in liter/hour – L/hour) by counting the pulses from the sensor output.

3.4 SOLENOID VALVE


A solenoid valve that is controlled by electricity and it is shown in the figure 3.6. The properties of the
electric current they employ, the strength of the magnetic field they generate, the mechanism they employ to
govern the fluid and the type and properties of fluid they control all differ among the solenoid valves.

Fig – 3.6 Solenoid Valve

In fluidics, Solenoid valves are the most commonly utilized control elements. Shut down, release,
dosage, distribute or mix fluids are among their responsibilities. They are used in wide range of settings.
Solenoids provide quick and safe switching, high reliability, long service life, good medium compatibility of
the materials used, low control power and compact design.

“1/2″ Electric Solenoid Water Air Valve Switch 12V DC (Normally Closed) controls the flow of fluid
air and serves as a valve for high-pressure water or any other fluid. This liquid valve would be perfect for any
robotic gardening project. Two “½” (Nominal NPT) outlets are available. The valve is normally closed. The
valve opens when 12V DC is connected to the two terminals, allowing the water to flow through.

The valve is controlled by solenoid coil that is powered by DC 12volt source. It opens the flow of
liquid as soon as power is turned ON and stops/blocks the flow when the supply voltage is removed, when it is
typically at normally closed assembly. High-end water heaters, intelligent drinking fountains, water heaters,
straight drinking machines, the usage of significant number of water purification machines, steam machines,
Energy-saving air-conditioning, water treatment, cooling equipment and water industry and other industries.

9
3.5 RELAY
3.5.1 RELAY WORKING
A relay is a switch that is controlled by electricity. A set of input terminals for a single or multiple
control signals, as well as set of functioning contact terminals, make up the device. The switch may have any
number of contacts in any contact forms, including make connections, break contacts and combination of two.

The following simplified circuit diagram shown in figure 3.7 is often used to easily understand how a
relay operates:

Fig – 3.7 Relay Working

When voltage is applied to a coil, magnetic field forms around it, pulling the hinged armature down
into the contact. The 'high' current circuit between the terminals is now complete and the relay is said to be
powered. The spring pushes the armature back into its 'at rest' position when voltage is removed from the coil
terminal and breaks the circuit between the terminals. So, by turning On or OFF the low current circuit (the
coil), we turn ON or OFF the high current circuit.

3.5.2 RELAY TERMINOLOGY


Because there is one high current circuit and a contact that is either open or closed depending on whether
the relay is at rest or energized, the ISO tiny relay we looked at above is referred to as make & break relay. IT
has four pins (or terminal) on the body and is referred to as make and break relay. The relay is referred to as
Normally Open (NO) if the contact is broken while the relay is at the rest and Normally Closed (NC) if the
contact is closed when the relay is at the rest (NC). Relay that are normally open at the most prevalent.

10
3.5.3 5-PIN RELAY

Fig – 3.8 Relay Module with Pin Description

Low level signals from an electronic such as those obtained from an IC stage or a low current transistor
stage, may, never less, be incapable of directly controlling the relay. Because, a relay demands a greater current,
which are typically unavailable from an IC source or a low current transistor stage. In order to resolve the
mentioned problem, a relay control step is required for all electronic circuits which need this service.

A relay driver is nothing more than extra transistor stage connected to the relay that has to be turned
ON. T In most cases, the transistor is used only to operate the relay in response to the commands received from
the preceding control stage.

3.5.4 NPN RELAY SWITCH CIRCUIT


The coil powered by an NPN transistor switch, micro controller in a standard relay switch circuit, as
indicated, depending upon the input voltage level and it is shown in the figure 3.9. When the transistor base
voltage of is zero (or negative), it is cut-off and serves as an open switch. In this state, no Collector current
flows and the relay coil is de-energized since relay are current devices, if the no current flows into the base, the
relay coil is de- energized.

The current flowing from Base to Emitter (B to E) regulates the bigger relay coil current flowing
through the transistor from the Collector to Emitter, if a large enough positive current is presently driven into
the Base to saturate the NPN transistor. The amount of relay coil current flowing into the Collector in most
bipolar switching transistor would be between 50 to 800 times that of the base current to drive the transistor
into saturation. The current gain or beta value (β) of the general purpose BC547 shown is typically about 290
at 2mA.

11
Fig – 3.9 NPN Relay Switch Circuit

This figure 3.10 shows it can be used to Control lamp, fan, valve, solenoid and motors etc. Input Logic
-5v level from MUC. Relay drive by interfacing with BC547.

Fig – 3.10 Two Channel Relay

3.6 NODE MCU


3.6.1 NODE MCU – ESP-12E MODULE
The development board includes the ESP-12E module with ESP32 chip having Tensilica Xtensa® 32-
bit LX106 RISC CPU that supports RTOS and runs at 80 to 160 MHz configurable clock frequency and it is
shown in the figure 3.11.

12
Fig – 3.11 ESP 12E Module

The figure 3.12 shows function ability of each pin using the pin out diagram below as a guide. As the
operating voltage range of is 3V to 3.6V, the board comes with a LDO voltage regulator to maintain the voltage
stable at 3.3V, while ESP32 operational voltage range is 3 – 3.6V. When ESP32 draws up to 80mA during RF
transmissions, it can dependably supply up to 600mA, which should be more than enough. The regulate output
is likewise separated to one of the board sides and labelled as 3V3. The power can be supplied to external
components via this pin.

Fig – 3.12 ESP 32 Pin Out diagram

3.6.2 NODE MCU ESP32 SPECIFICATIONS


Table – 3.3 : Specifications Of Node MCU
Parameters Specifications
1) Clock speed 80 MHz
2) Operating voltage 3.3 volt
3) Input voltage 7 – 12 volt
4) Digital I/O pins 16
5) Analog input pins 1
6) Flash memory 4 MB
7) SRAM 64 KB
13
CHAPTER 4
METHODOLOGY

4.1 WATER DISTRIBUTION SYSTEM

The entire project is separated into three components, first of which is real time water flow monitoring.
The second module will ensure water is distributed evenly across each block. The third module uses an IoT
based notification application to distribute the water on demand and according to water usage.

The first step in putting a monitoring system in a place is to measure the water flow with flow sensor,
which will give the exact flow available. For distribution purpose, this level can be converted into volume. Then
using IoT alert the water to each flat based on the number of people’s requirements (Node MCU).

The water flow provided in each flat will be measured by Flow meter in each flat. After a predetermined
amount of time has passed, Arduino will turn OFF the water supply. The water usage information will be
updated in real time and a message will be sent to the registered cell phone number then water supply is depleted,
so that user will aware of the water usage.

Data will be validated against the available storage based on the requested amount of water and only
portion of of available water will be released for the requested user. Extra water used on demand will be factored
into final charge. The proposed block diagram depicts entire system layout.

4.2 ARDUINO NANO

The Arduino is a controller that takes readings from the flow meter based on each flat's predefined
stage. The Arduino is depicted in the diagram. This controller is used to construct the entire embedded device.
It will be in charge of turning ON and OFF the valve as well as IoT data communication.

4.3 FLOW SENSOR

This sensor is used to calculate the flow rate of water that passes through a customer pipeline. This flow
rate can also be used to measure the total amount of water that passes through a pipeline. In such cases, Q=
V*A is used to calculate the liquid flow rate, where Q is the water flow rate through the pipe, V is the average
velocity of the flow, and A is the pipe's cross - sectional area. Formula: Liters = Pulses / (7.5 * 60). Every
consumer's pipeline has flow sensors mounted.

A flow meter is a device that measures the amount of water that flows through it. When water is
pumped into the tubing, the turbines spin, and the flow meter responds by providing pulses. The amount of
water flowing is used to calculate this.

14
4.1.1 PROPOSED METHODOLOGY BLOCK DIAGRAM

Power Supply

Solenoid
Valve 1 Arduino
NANO
Flow
Sensor 1
Buzzer
Indication

WiFi
Solenoid
Valve 2

Flow
Sensor 2

Fig – 4.1 Proposed Block Diagram

4.4 CONTROL VALVE

This system controls the flow of water by turning it ON and OFF based on the state of the flow
meter. A solenoid is used to turn ON and OFF the tap in the valve. As current begins to flow, a magnetic field
is generated, which aids in the control of valve turning ON and OFF.

The valve chosen for this application is a 22-way usually open valve. In its resting state, it allows
water to flow. It has two orifice seats and two ports. The solenoid valve can be opened or closed with a short
electrical impulse. The residual effect of a permanent magnet is adequate to keep the valve in a certain working
position while consuming no electrical energy. The valve will maintain its original location, i.e., open, if the
electrical impulse has the opposite polarity.

4.5 RELAY CONTROL

A relay is a switching system that uses 12 volt DC power supply to run. It is used to open or close
the water flow by turning on or off a control valve. The Arduino NANO controller will be used to power this
relay.

15
4.6 IOT MODULE – NODEMCU

The Wi-Fi module is used to upload all of the data from the Arduino to the cloud, where it will be
monitored as well as approve requests for additional water use and submit updates to the user. The Wi-Fi module
operates at 2.4GHz and supports a variety of protocols, including MQTT, HTTP, and HTTPS. It operates
between 3.3 and 3.6 volts and has general-purpose input and output terminals.

Computing devices embedded in everyday objects are connected to the internet, allowing them to
send and receive data. It can transmit data through a network without the need for human-to-human or human-
to-computer interaction. Thing speak and Firebase cloud servers are used to store data in this project.

Thing Speak is a free IoT platform that includes MATLAB analytics. It is used to store and
retrieve data from items over the internet using the HTTP protocol. It has apps that allow you to analyze and
visualize data. The Firebase cloud server is used to continuously store and display real-time data in an Android
mobile application that has been developed.

4.7 BUZZER ALERT

We needed one open server for internet communication since data is sent to the cloud and can
be received by clients as well as stored on the server. These sensors will detect any changes in the device, and
the controller will activate the buzzer to warn the user and monitor the water consumption in their home
automatically.

4.8 EMAIL ALERT

Furthermore, it aims to prevent the tank from overusing water during the operation, thus reducing
water consumption, and, most importantly, to warn users through an e-mail warning system as well as a buzzer
alert system. These sensors will detect any changes in the device and the Wi Fi module will send an e-mail to
the user, notifying them of the change and automatically controlling their water consumption.

16
4.9 OVERALL CIRCUIT DIAGRAM

Fig – 4.2 Overall Circuit Connection Diagram

17
4.10 CIRCUIT DESCRIPTION
The figure 4.2 depicts the circuit diagram for the Arduino NANO with Sensor Interface, connection
of the YF-S201 Water Flow Sensor's Red and Black wires to +5V and GND, respectively. Using the Arduino's
Interrupt function, only Digital I/O Pins 2 and 3 can be connected to the Water Flow Sensor's Output. In this
project, Water Flow Sensor's output (yellow wire) to Arduino NANO's Digital I/O Pin 2 is attached.

The solenoid operates between 6 and 12 volts, which is too large for the Arduino's regular 5 volts.
To get around this problem, in this 9V power supply is used – the solenoid will run on 9V and the Arduino's
built-in voltage regulator will convert that 9V to the 5V it needs. the Arduino Uno's "Vin" pin is used which is
next to the ground pin, to get access to the raw voltage going into the DC barrel jack.

The LCD module's RS pin is attached to the Arduino's digital pin 8. The LCD's R/W pin is grounded.
The LCD module's enable pin is connected to the Arduino's digital pin 9. The LCD module and the Arduino
are connected in 4-bit mode in this project. Just four of the LCD's digital input lines (DB4 to DB7) are used in
this way. This method is very simple, needs fewer connections and allows the users to almost fully leverage the
LCD module's capabilities. The digital lines DB4, DB5, DB6, and DB7 are connected to the Arduino NANO's
digital pins 7, 6, 5, and 4.

The 10K potentiometer is used to change the display's contrast. The external power jack on the
board can be used to power the Arduino. The +5V needed in other sections of the circuit can be tapped from
the Arduino board's 5V source.

• The YS-S20 flow sensor comes with three wired systems and can be used with any microcontroller or
Arduino board.
• The Liquid Crystal Display will show the current status of the water level (LCD).
• A flow meter is installed in the main and branch pipes to calculate the water flow rate.

18
4.11 OVERALL HARDWARE MODULE

19
CHAPTER 5
ARDUINO CODE
5.1 ARDUINO CODE

20
21
22
23
5.2 WIFI CODE

24
25
26
27
CHAPTER 6
RESULTS AND DISCUSSION

6.1: OUTPUT FOR RATE OF FLOW AND VOLUME OF WATER

The figure 6.1 shows the output for the rate of flow and volume of water for two houses which is displayed in
LCD module and if it exceeds the limit, it will alert the user by turning ON buzzer.

Fig – 6.1: Output for rate and volume of water flow

28
6.2: OUTPUT FOR ALERT NOTIFICATION IN MAIL

The figure 6.2 shows the output for the alert notification to the user in mail through the Wi-Fi module by
using IoT for 2 houses.

Fig – 6.2: Output for alert notification in mail

6.3: OUTPUT IN IOT PLATFORM

The figure 6.3 shows the output in the graph form which indicates the rise of flow of water and if the users
exceed the usage of 1litre, sends automatically mail notification to the users.

Fig – 6.3: Output in IoT Platform

29
6.4: OVERALL OUTPUT OF THE SYSTEM

The figure 6.4 shows the overall output which displays the rate of flow and volume of water in the tank in
LCD display through flow sensor, the usage of water by the users in IoT platform (Thing Speak) and alert
notification to the users via email through Wi Fi module.

Fig – 6.4 : Overall output of the system

30
CHAPTER 7
CONCLUSION

The proposed frame work is truly Internet of Things based. This system allows for safe and continuous
monitoring. Since there is no need to go out into the field for testing, manual labor is reduced, making the
system more efficient, dependable, low cost and accurate. Changing a location of control valves has no effect
on the flow rate. In addition, the main water tank water level is automatically maintained.

Water waste can be reduced by using this method. A common man's need for water is met at his
fingertips with Digital Water Supply. Since there is no human involvement in the supply chain, the majority of
issues that arise are avoided. Furthermore, there is no water waste era leads to encouraging of water
conservation.

Maintaining water quality in the future by automatically adding chlorine. This device not only tracks
the water supply, but it is also used to detect and prevent water theft. The future scope of this project is
monitoring the quality of water level by using PH sensor and other applicable sensors.

The system has been implemented successfully. The system has been effectively implemented. The
suggested system is a fully automated system that can monitor, distribute, and bill three different tasks in one
unit. Water wastage is completely regulated by offering a billing mechanism for each individual's water usage.
It's also a cost-effective technology that allows users to conserve both water and money. A water usage alert
has been issued from time to time. Our initiative will meet this generation's critical requirement to protect future
generations from water shortages.

31
CHAPTER 8
REFERENCES

[1] Navin Rapelli - Department of Electronics & Telecommunication Engineering, MIT - AOE, Alandi Pune,
Maharashtra, India – “IOT based smart water management, monitoring and distribution system for an
apartment”, Proceedings of the Fourth International Conference on Communication and Electronics Systems,
IEEE Conference, 2019.

[2] Chetan S. Patel – Dept of Instrumentation & Control Engineering, Vishwakarma Institute of Technology,
Pune, India – “Design and Development of IOT Based SMART water distribution network for Residential
areas”, Proceedings of the Fourth International Conference on Communication and Electronics Systems IEEE
Conference, 2019.

[3] D.Devasena, R.Ramya, T.Darshan and et al - “IOT based water distribution system, International Journal of
Engineering and Advanced Technology(IJEAT), Volume – 8, Issue-6, August – 2019.

[4] Rosiberto Goncalves, Jesse J. M. Soares and Ricardo M. F. Lima – “An IoT-Based Framework for Smart
Water Supply Systems Management”, MDPI journal, Future Internet, 2020.

[5] Revanth C.B,” e-Water supply system using Python, Raspberry Pi and IOT”, International Research Journal
of Engineering and Technology (IRJET)- August 2017.

[6] Kusuma S S1, Anil G N2 “An IOT based Water Supply Monitoring and Controlling System”, International
Research Journal of Engineering and Technology (IRJET), Volume - 05 Issue - 02, Feb- 2018.

[7] Panindrareddy, Eswaran, “Metro overhead tanks monitoring system using ZigBee based WSN”, IEEE
conference on Information and Communication Technologies, 2013.

[8] H. Lim, W. Kim and J. Jung, "Integrated Water Cycle Management System for Smart Cities", 2nd
International Conference on Green Energy and Applications (ICGEA), Singapore, 2018, pp. 55-58.

[9] C. J. T. Dinio et al., "Automated Water Source Scheduling System with Flow Control System", IEEE 10th
International Conference on Humanoid, Nanotechnology, Information Technology, Communication and
Control, Environment and Management (HNICEM), Baguio City, Philippines, 2018, pp. 1-5.

32
References:

• Navin Rapelli - Department of Electronics & Telecommunication Engineering, MIT - AOE, Alandi
Pune, Maharashtra, India – “IOT based smart water management, monitoring and distribution system
for an apartment”, Proceedings of the Fourth International Conference on Communication and
Electronics Systems, IEEE Conference, 2019.

• Chetan S. Patel – Dept of Instrumentation & Control Engineering, Vishwakarma Institute of


Technology, Pune, India – “Design and Development of IOT Based SMART water distribution
network for Residential areas”, Proceedings of the Fourth International Conference on
Communication and Electronics Systems IEEE Conference, 2019.

33
CHAPTER 9

APPENDIX

SIMILARITY CHECK REPORT

34
35

You might also like