Project Report
Project Report
AND
WATER QUALITY MANAGEMENT SYSTEM
A PROJECT REPORT
Submitted by
Of
BACHELOR OF ENGINEERING
IN
TIRUNELVELI
1
JUNE 2025
BONAFIDE CERTIFICATE
Certified that this project report “ TWAD Smart Water Distribution and
Water Quality Management System ” is the Bonafide work of
KATHIRESAN S - 950821106033
MUPPIDATHI E - 950821106043
Signature of the HOD with date Signature of the Supervisor with date
The report of the project was submitted by the above students on fulfilment
for the award of the Bachelor of Engineering degree in Electronics and
Communication Engineering of Anna University Chennai were evaluated and
confirmed to be a complete report of the work done by the above students.
3
INTERNAL EXAMINER EXTERNAL EXAMINER
4
ACKNOWLEDGEMENT
I thank the almighty, for the blessings that have been showered upon us to
bring forth the success of the project work.
First and foremost, we thank the glorious almighty for blessing us with all
that was required for the completion of our project. We express our sincere
thanks to our principal Dr. P. LATHA, M.E., Ph.D., MISTE, for permitting us
to carry out this project work successfully.
5
and friends who have been the constant source of our strength throughout our
life.
ABSTRACT
6
7
TABLE OF CONTENTS
1. Introduction
2. Literature Review
System Implementation
8
9
10
CHAPTER 1
INTRODUCTION
The adoption of digital technologies like IoT, cloud computing, and AI has
revolutionized sectors like transportation and healthcare. Water management
systems too must evolve by integrating these technologies for smarter, more
responsive operations.
12
Consumers today demand transparency and accountability in public
services. A smart system can provide real-time updates on water quality and
supply status to users via mobile apps or dashboards, enhancing trust and
promoting community participation.
During natural disasters like floods or droughts, smart water systems can
provide critical data for emergency response. They enable authorities to make
informed decisions quickly, preventing large-scale disruptions in water access.
13
CHAPTER 2
LITERATURE REVIEW
[1] M. S. Islam, M. S. Hossain, and N. S. Islam, "A Smart IoT Based Water
Quality Monitoring System Using MQTT Protocol," 2019 International
Conference on Robotics, Electrical and Signal Processing Techniques
(ICREST), Dhaka, Bangladesh, pp. 378–382, 2019.
This paper presents an IoT-based water quality monitoring system that uses
the MQTT protocol for efficient data transmission. Key parameters such as pH,
turbidity, and temperature are monitored through sensors. The MQTT protocol
enables low-latency communication between sensors and a central database. The
system architecture includes microcontrollers, cloud platforms, and real-time
alert mechanisms. It emphasizes cost-effectiveness, scalability, and flexibility.
The paper demonstrates real-time visualization and analytics of water quality
data. It highlights the role of IoT in improving public health and environmental
monitoring. The system can be deployed in both urban and rural areas. Its
modular design ensures easy integration with smart city infrastructure. The
approach supports proactive decision-making for water safety.
15
and policymakers. It underlines the need for interdisciplinary collaboration in
water management.
16
[7] S. Kartakis, S. Yang, and J. A. McCann, "Reliability or Sustainability:
Optimal Data Stream Estimation and Scheduling in Smart Water
Networks," ACM Transactions on Sensor Networks (TOSN), Mar. 2017.
This research addresses the trade-off between data reliability and energy
sustainability in smart water networks. It proposes algorithms for optimal data
stream scheduling from sensor nodes. The system balances real-time monitoring
needs with limited energy resources. Techniques include predictive sampling and
adaptive data transmission. The study demonstrates improved network lifetime
without compromising on accuracy. Case studies validate the approach using
simulated water systems. The findings are crucial for designing energy-efficient
IoT deployments. It also considers wireless network latency and bandwidth
constraints. The approach supports fault tolerance and resilience in harsh
environments. The paper is significant for long-term deployments in remote
areas.
17
[9] F. R. Ishengoma, "A Novel Design of IEEE 802.15.4 and Solar Based
Autonomous Water Quality Monitoring Prototype using ECHERP,"
International journal of Computer Science & Network Solutions, Oct. 2014.
Though focused on solid waste, this paper is relevant to water projects due
to its smart city context. It discusses the role of IoT and automation in managing
urban services. Technological interventions include smart bins, sensor networks,
and data platforms. Lessons can be applied to water distribution and quality
monitoring systems. The paper identifies administrative, financial, and
behavioural challenges. It emphasizes the need for integrated smart city
strategies. Policy recommendations are offered for sustainable infrastructure
development. The research promotes technology-driven solutions for urban
challenges. It encourages interdisciplinary approaches to public service
optimization. The findings highlight Tamil Nadu's potential as a model for smart
governance.
18
19
CHAPTER 3
SYSTEM IMPLEMENTATION
20
3.3 DESIGN
Water Level Monitoring : A Water Level Sensor continuously tracks the water
level inside the tank.
Water Quality Assessment : Temperature sensor measure water quality
parameters and send data to the Arduino Board.
Automated Pump Regulation :
• Pump 1 activates to fill the tank when the water level is low and stops when
it reaches a predefined threshold.
IoT Integration : The system uses a Wi-Fi module to connect to an IoT web
server for remote monitoring.
21
3.4 BLOCK DIAGRAM
22
This intelligent system ensures efficient and automated water distribution
and quality management across multiple zones.
3.6 CIRCUIT DIAGRAM
23
12VCC
TR1
BR1 5VCC
1 3
R1
VI VO
1k
C1 7805 C2
G N D
1000u U2 470u LED
2
BRIDGE
TRAN-2P2S
LCD1
LM016L
12V
12 Vcc
VDD
VSS
VEE
RW
RS
D 0
D 1
D 2
D 3
D 4
D 5
D 6
D 7
12Vcc RL1
E
12V
1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
From 1C
U1 Pump 1
13 2 U3
PD0/RXD/PCINT16 PB0/ICP1/CLKO/PCINT0
12 3 9 12Vcc
PD1/TXD/PCINT17 PB1/OC1A/PCINT1 COM
11 5 1 16 12Vcc
PD2/INT0/PCINT18 PB2/SS/OC1B/PCINT2 1B 1C
10 4 2 15
PD3/INT1/OC2B/PCINT19 PB3/MOSI/OC2A/PCINT3 2B 2C
9 2 3 14
PD4/T0/XCK/PCINT20 PB4/MISO/PCINT4 3B 3C
8
PD5/T1/OC0B/PCINT21 PB5/SCK/PCINT5
3 4
4B 4C
13 12Vcc RL2
7 5 1 2 5 12 12V
PD6/AIN0/OC0A/PCINT22 PB6/TOSC1/XTAL1/PCINT6 5B 5C
7
PD7/AIN1/PCINT23 PB7/TOSC2/XTAL2/PCINT7
4 16MHZ 6
6B 6C
11
From 2C
7 10
7B 7C
7 13
AREF PC0/ADC0/PCINT8
1 12 ULN2003A
AVCC PC1/ADC1/PCINT9
11
PC2/ADC2/PCINT10
7
7
ADC6
ADC7
PC3/ADC3/PCINT11
PC4/ADC4/SDA/PCINT12
10
9 5VCC Pump 2
8
PC5/ADC5/SCL/PCINT13
7
PC6/RESET/PCINT14
12Vcc
GND
GND
24
3.7 CIRCUIT DESCRIPTION
25
CHAPTER 4
HARDWARE DETAILS
DESCRIPTION OF INPUT:
ANALOG INPUT:
DIGITAL INPUT:
ATMEGA-328 IC:
The table below gives a description for each of the pins, along with their
function.
Pin
Description Function
Number
1 PC6 Reset
2 PD0 Digital Pin (RX)
3 PD1 Digital Pin (TX)
4 PD2 Digital Pin
5 PD3 Digital Pin (PWM)
6 PD4 Digital Pin
7 Vcc Positive Voltage (Power)
8 GND Ground
9 XTAL 1 Crystal Oscillator
10 XTAL 2 Crystal Oscillator
11 PD5 Digital Pin (PWM)
12 PD6 Digital Pin (PWM)
13 PD7 Digital Pin
14 PB0 Digital Pin
15 PB1 Digital Pin (PWM)
16 PB2 Digital Pin (PWM)
28
17 PB3 Digital Pin (PWM)
18 PB4 Digital Pin
19 PB5 Digital Pin
Positive voltage for ADC
20 AVCC
(power)
21 AREF Reference Voltage
22 GND Ground
23 PC0 Analog Input
24 PC1 Analog Input
25 PC2 Analog Input
26 PC3 Analog Input
27 PC4 Analog Input
28 PC5 Analog Input
FEATURES:
29
o Optional boot loader with lock bits
In System Programming (ISP) by via boot loader
True Read-While-Write operation
o Programming lock available for software security
Features Include
o 2 x 8-bit Timers/Counters each with independent prescaler and
compare modes
o A single 16-bit Timer/Counter with an independent prescaler, compare
and capture modes
o Real time counter with independent oscillator
o 10 bit, 6 channel analog to digital Converter
o 6 pulse width modulation channels
o Internal temperature sensor
o Serial USART (Programmable)
o Master/Slave SPI Serial Interface – (Philips I2C compatible)
o Programmable watchdog timer with independent internal oscillator
o Internal analog comparator
o Interrupt and wake up on pin change
Additional Features
o Internal calibrated oscillator
o Power on reset and programmable brown out detection
o External and internal interrupts
o 6 sleep modes including idle, ADC noise reduction, power save,
power down, standby, and extended standby
APPLICATIONS:
31
4.2 ULTRASONIC SENSOR :
THEORY OF OPERATION :
The PING))) sensor detects objects by emitting a short ultrasonic burst and
then "listening" for the echo. Under control of a host microcontroller (trigger
pulse), the sensor emits a short 40 kHz (ultrasonic) burst. This burst travels
through the air at about 1130 feet per second, hits an object and then bounces
back to the sensor. The PING))) sensor provides an output pulse to the host that
will terminate when the echo is detected, hence the width of this pulse
corresponds to the distance to the target.
32
HC-SR04 Ultrasonic (US) sensor is a 4 pin module, whose pin names are
Vcc, Trigger, Echo and Ground respectively. This sensor is a very popular sensor
used in many applications where measuring distance or sensing objects are
required. The module has two eyes like projects in the front which forms the
Ultrasonic transmitter and Receiver. The sensor works with the simple high
school formula that
Now, to calculate the distance using the above formulae, we should know
the Speed and time. Since we are using the Ultrasonic wave we know the
universal speed of US wave at room conditions which is 330m/s. The circuitry
inbuilt on the module will calculate the time taken for the US wave to come back
and turns on the echo pin high for that same particular amount of time, this way
we can also know the time taken. Now simply calculate the distance using a
microcontroller or microprocessor.
33
FEATURES :
• Supply Voltage – 5 VDC
• Supply Current – 30 mA typ; 35 mA max
• Range – 2 cm to 3 m (0.8 in to 3.3 yrds)
• Input Trigger – positive TTL pulse, 2 uS min, 5 µs typ.
• Echo Pulse – positive TTL pulse, 115 uS to 18.5 ms
• Echo Hold-off – 750 µs from fall of Trigger pulse
• Burst Frequency – 40 kHz for 200 µs
• Burst Indicator LED shows sensor activity
34
• Delay before next measurement – 200 µs
APPLICATIONS :
• Car Alarm systems
• Residential and commercial security systems
• Automatic doors opening systems
CIRCUIT DIAGRAM :
35
DRIVER :
Driver is used for drive the relay. ULN2003A IC is used as driver. This IC
has some special features
Seven Darlington’s per package
output current 500ma per driver (600ma peak)
output voltage 50v
integrated suppression diodes for inductive loads
outputs can be paralleled for higher current
ttl/cmos/pmos/dtl compatible inputs
DESCRIPTION :
The ULN2001A, ULN2002A, ULN2003 and ULN2004Aare high voltage,
high current Darlington arrays each containing seven open collector dar-lington
pairs with common emitters. Each channel rated at 500mAand can withstand
peak currents of 600mA. Suppression diodes are included for inductive load
driving and the inputs are pinned opposite the outputs to simplify board layout.
The four versions interface to all common logic families
36
ULN2001A General Purpose, DTL, TTL, PMOS, CMOS
ULN2002A 14-25V PMOS
ULN2003A 5V TTL, CMOS
ULN2004A 6-15V CMOS, PMOS
These versatile devices are useful for driving a wide range of loads
including solenoids, relays DC motors; LED displays filament lamps, thermal
print-head sand high power buffers ULN2001A/2002A/2003Aand 2004A is sup-
plied in 16 pin plastic DIP packages with a copper lead frame to reduce thermal
resistance. They are available also in small outline package (SO-16) as
ULN2001D/2002D/2003D/2004D.
PIN DIAGRAM – ULN 2003
37
The ULN2003A is a high voltage, high current, Darlington Arrays each
containing seven open collection Darlington pairs with common emitters. Each
channel rated at 500mA and can withstand peak currents of 600mA. Suppression
diodes are included for inductive load driving and the inputs are pinned opposite
to outputs to simplify layout. It is a 5V TTL, CMOS. This versatile device is
useful for driving a wide range of loads including solenoids, relays, DC motors,
LED displays, and high power buffers. Outputs can be paralleled for higher
current.
The output of MC is applied to the input of relay driver transistor at its
phase terminals. When the input base voltage is reduced so that the relay is de-
energized, the collector current falls to zero abruptly. This sudden switching off
the relay current induces a very high back emf in the relay coils, which may be
high enough to puncture the collector-emitter junction at the transistor and damage
it. A large capacitor connected in parallel with the relay coil absorbs this transient
and protects the transistor. However large capacitor connected in parallel with the
38
relay coil absorbs this transient, protects the transistor and sluggish the relay
operations.
In an alternative method, a diode is connected in parallel with relay coil
instead of the capacitor. During normal operation, the diode is reversed biased and
has no effects on circuit performance, but, when the high back emf is induced, it
has the proper polarity for the diode to conduct. The diode there after conducts
heavily and absorbs all the transient voltage. The use of a diode is parallel with the
relay coil is highly recommended.
The ULN2003 IC consists of eight NPN Darlington pair which provides the
proper current amplification required by the loads. We all know that the
transistors are used to amplify the current but here Darlington transistor pairs are
used inside the IC to make the required amplification.
FEATURES:
Output Voltage: 50 V
Input Voltage (for ULN2002A/D - 2003A/D - 2004A/D): 30 V
Continuous Collector Current: 500 mA
Continuous Base Current: 25 mA
Operating Ambient Temperature Range: – 20 to 85 °C
Storage Temperature Range: – 55 to 150 °C
Junction Temperature: 150 °C
4.4 RELAY :
40
Relays are switching devices. Switching devices are the heart of
industrial electronic systems. When a relay is energized or activated, contacts are
made or broken. They are used to control ac or dc power. They are used to
control the sequence of events in the operation of a system such as an electronic
heater, counter, welding circuits, and X-ray equipment, measuring systems, alarm
systems and telephony. Electromagnetic relays are forms of electromagnets in
which the coil current produces a magnetic effect. It pulls or pushes flat soft iron
armatures or strips carrying relay contacts. Several relay contact can be operated
to get several possible ON/OFF combinations.
Electromagnetic Relay
41
The heart of the relay is the ‘junction’ of the contact points. The relay
contact points may be flat, spherical, pointed and combination of all these. Flat
contacts require more pressure for perfect contact closing. Half round contacts
are better because the surface contamination will be minimum. The twin contacts
give reliable operation.
Relay contacts are made of silver and silver alloys in small power
applications. For large relays, contacts are made up of copper. Certain relays use
silver – palladium of platinum – ruthenium alloys for contacts. The special types
mentioned above give long life, carry moderate currents and keep shape for long
time.
To identify relay contacts, some important contact arrangements must be
remembered.
SPST - Single Pole Single Throw
SPDT - Single Pole Double Throw
NO - Normally Opened
NC - Normally Closed
Break - Relay action opens or breaks contacts
Make - Relay action makes or closes contacts
42
difference is that simple switch is manual switch where as relay is an automatic
switch to some extent. It has a coil in it.
When this coil gets enough supply then it becomes electromagnet and
attracts the strip of pole towards itself and changes the position of switch. When
supply cuts off then coil demagnetizes and thus switch comes in its normal
position. In telephony, the relays are used widely. The relay that we used in this
circuit has two states.
Normally closed state (NC)
Normally opened state (NO)
The control circuit of the relay transistor is shown in figure. When the input
to transistor is logic 0, the transistor will be open. So the relay will be holding
+12 and which will be in normally closed state.
Relays are electro mechanical switches and are electrically operated power
switches. A relay consists of an electromagnet which when energized pulls the
armature. The armature carries heavy electrical contacts that make or break an
electric circuit. General purpose relays can handle current of five or ten amperes.
Relays that have contact ratings of about 25A or more are known as contactors. A
single relay can make or break a number of contacts simultaneously.
The amount of electrical power required to drive a relay is very small. Most
Voltage stabilizers use relay coils of 720mw.It means that 12v relay coil will have
resistance of 200 ohms and operated up to 60mA.The same relay with 450 ohms
coil will operate on 18v with 40mA.Transistor circuits can easily supply this
much of power and this much of power and thus control large amount of power
through relay contacts.
When the relay is not activated (ie.) in the reenergized state, NC contacts
are closed and NO connections are opened. When the relay is activated (ie.)in the
energized state, NC contacts broken and NO contacts are made. When the relay is
de energized the original states of the contacts are returned.
The Above relays are single contact relays. This means that the relays have
one common point, one NO contact and one NC contact.
43
Double contact relays are also present. These relays have a set of common
points, a set of NO contacts and set of NC contacts. In single contact relay, only
one relay independent load or a series of different loads can be connected.
In double contact relay, two independent loads can be connected at two
different contacts and these two different and these two loads can be operated as
desired.
The chip first came to the attention of western makers in August 2014 with
the ESP-01 module, made by a third-party manufacturer, Ai-Thinker. This small
module allows microcontrollers to connect to a Wi-Fi network and make simple
TCP/IP connections using Hayes-style commands. However, at the time there
was almost no English-language documentation on the chip and the commands it
accepted. The very low price and the fact that there were very few external
components on the module which suggested that it could eventually be very
inexpensive in volume, attracted many hackers to explore the module, chip, and
the software on it, as well as to translate the Chinese documentation.
WI-FI PROTOCOLS :
SPECIFICATIONS :
46
4.6 INTERNET OF THINGS (IOT) :
47
The Internet of Things (IoT) is the network of physical objects or "things"
embedded with electronics, software, sensors, and network connectivity, which
enables these objects to collect and exchange data.
IoT allows objects to be sensed and controlled remotely across existing
network infrastructure, creating opportunities for more direct integration between
the physical world and computer-based systems, and resulting in improved
efficiency, accuracy and economic benefit.
"Things," in the IoT sense, can refer to a wide variety of devices such as
heart monitoring implants, biochip transponders on farm animals, electric clams
in coastal waters, automobiles with built-in sensors, DNA analysis devices for
environmental/food/pathogen monitoring or field operation devices that assist
fire-fighters in search and rescue operations.
These devices collect useful data with the help of various existing
technologies and then autonomously flow the data between other devices.
48
THE STRUCTURE OF IOT :
The IoT can be viewed as a gigantic network consisting of networks of
devices and computers connected through a series of intermediate technologies
where numerous technologies like RFIDs, wireless connections may act as
enablers of this connectivity.
Tagging Things: Real-time item traceability and addressability by RFIDs.
Feeling Things: Sensors act as primary devices to collect data from the
environment.
Shrinking Things: Miniaturization and Nanotechnology has provoked the
ability of smaller things to interact and connect within the “things” or
“smart devices.”
Thinking Thing: Embedded intelligence in devices through sensors has
formed the network connection to the Internet. It can make the “things”
realizing the intelligent control.
50
transportation systems. Other applications that the Internet of Things can provide
is enabling extended home security features and home automation.
ENABLING TECHNOLOGIES
RFID :
To identify and track the data of things.
Sensor :
To collect and process the data to detect the changes in the physical status
of things.
Smart Tech :
To enhance the power of the network by devolving processing capabilities
to different part of the network.
Nano Tech :
To make the smaller and smaller things have the ability to connect and interact .
IOT – ADVANTAGES :
51
Reduced Waste : IoT makes areas of improvement clear. Current analytics
give us superficial insight, but IoT provides real-world information leading
to more effective management of resources.
IOT – DISADVANTAGES :
52
IOT SOFTWARE :
IoT software addresses its key areas of networking and action through
platforms, embedded systems, partner systems, and middleware. These individual
and master applications are responsible for data collection, device integration,
real-time analytics, and application and process extension within the IoT
network. They exploit integration with critical business systems (e.g., ordering
systems, robotics, scheduling, and more) in the execution of related tasks.
Data Collection :
This software manages sensing, measurements, light data filtering, light
data security, and aggregation of data. It uses certain protocols to aid sensors in
connecting with real-time, machine-to-machine networks. Then it collects data
from multiple devices and distributes it in accordance with settings. It also works
in reverse by distributing data over devices. The system eventually transmits all
collected data to a central server.
Device Integration :
Software supporting integration binds (dependent relationships) all system
devices to create the body of the IoT system. It ensures the necessary cooperation
and stable networking between devices. These applications are the defining
software technology of the IoT network because without them, it is not an IoT
system. They manage the various applications, protocols, and limitations of each
device to allow communication.
Real-Time Analytics :
These applications take data or input from various devices and convert it
into viable actions or clear patterns for human analysis. They analyze information
based on various settings and designs in order to perform automation-related
tasks or provide the data required by industry.
Application and Process Extension :
53
These applications extend the reach of existing systems and software to
allow a wider, more effective system. They integrate predefined devices for
specific purposes such as allowing certain mobile devices or engineering
instruments access. It supports improved productivity and more accurate data
collection.
4.7 LCD DISPLAY :
Liquid Crystal Displays (LCDs) have materials, which combine the
properties of both liquid and crystals. Rather than having a melting point, they
have a temperature range within which the molecules are almost as mobile as
they would be in a liquid, but are grouped together in an ordered form similar to
a crystal. An LCD consists of two glass panels, with the liquid crystal material
sand witched in between them. The inner surface of the glass plates are coated
with transparent electrodes which define the character, symbols or patterns to be
displayed polymeric layers are present in between the electrodes and the liquid
crystal, which makes the liquid crystal molecules to maintain a defined
orientation angle. One each polarizer are pasted outside the two glass panels.
This polarizer would rotate the light rays passing through them to a definite
angle, in a particular direction. When the LCD is in the off state, light rays are
rotated by the two polarizer and the liquid crystal, such that the light rays come
out of the LCD without any orientation, and hence the LCD appears transparent.
When sufficient voltage is applied to the electrodes, the liquid crystal molecules
would be aligned in a specific direction.
The LCDs are lightweight with only a few millimeters thickness. Since the
LCD’s consume power, they are compatible with low power electronic circuits,
54
and can be powered for long durations. The LCD does don’t generate light and so
light is needed to read the display. By using backlighting, reading is possible in
the dark. The LCD’s have long life and a wide operating temperature range.
Changing the display size of the layout size is relatively simple which makes the
LCD’s more customers friendly.
The LCD’s used exclusively in watches, calculators and measuring
instruments are the simple seven-segment displays, having a limited amount of
numeric data. The recent advances in technology have resulted in better legibility,
more information displaying capability and a wider temperature range. These
have resulted in the LCDs being extensively used in telecommunications and
entertainment electronics. The LCDs have even started replacing the cathode ray
tubes (CRTs) used for the display of text and graphics, and also in small TV
applications.
It has 16 pins and can be operated in 4-bit mode or 8-bit mode. Here we are
using the LCD module in 4-bit mode. Before going in to the details of the
project, let’s have a look at the JHD162A LCD module.
APPLICATIONS:
56
1. Manufacturing Systems: Solenoid valves are used to control machines,
dose, mix, or restrict the flow of liquids or gases. For example, in beverage
factories, they measure the exact amount of drink to be poured into bottles.
2. Agriculture: Solenoid valves are found in irrigation devices such as
automatic sprinklers and motorized farm machines to dose substances.
They control the flow of water and can operate sprinklers autonomously.
3. Automotive Applications: Solenoid valves regulate the flow of automotive
fluids such as oil, brake fluid, or fuel. They are used in functions like
limiting fuel flow to reduce vehicle speed or shutting off fuel flow to stop a
vehicle.
4. Vacuum Systems: Solenoid valves are used in vacuum applications,
including electronics manufacturing, vacuum pumps, and automation
systems.
5. Home Heating Units: They control the flow of heating fluids in home
heating systems.
6. Refrigeration Appliances: Solenoid valves are used to control the flow of
refrigerants in refrigeration systems.
7. Car Washing Machines: They control the flow of water and cleaning
agents in car washing systems.
8. Air Compressor Units: Solenoid valves regulate the flow of air in air
compressor systems.
TECHNICAL SPECIFICATIONS:
58
POWER SUPPLY:
59
Block diagram of AC to DC power Supply consists,
1. Transformer: Steps the household line voltage up or down as required.
2. Rectifier: Converts ac voltage into dc voltage.
3. Filter: Smooth the pulsating DC voltage to a varying DC voltage.
4. Regulator: Fix the output voltage to constant value.
60
The magnetism changing back and forth makes a current in the wire.
Having fewer coils means less voltage. When it is used to “decrease” the voltage
on the secondary winding with respect to the primary it is called a Step-down
Transformer. When a Transformer is used to “increase” the voltage on its
secondary winding with respect to the primary, it is called a Step-up
Transformer.
However, a third condition exists in which a transformer produces the same
voltage on its secondary as is applied to its primary winding. In other words, its
output is identical with respect to input. This type of Transformer is called an
“Impedance Transformer” and is mainly used for impedance matching or the
isolation of adjoining electrical circuits.
4.10 RECTIFIERS:
A rectifier circuit converts an AC voltage into a pulsating DC voltage. This
is accomplished by using one or more diodes because diodes conduct current in
only one direction.
4.11 FILTERS:
The 121% ripple in the output of the half-wave rectifier and 48% in the full-
wave rectifier is more than can be normally tolerated. In the full wave filtering,
wherein the frequency of the ripple is 100Hz for a 50Hz ac line voltage. This is
an advantage where either an inductor is used to prevent the passage of the ripple
current(due to its high inductive reactance to ac but quite low resistance to dc), or
61
a capacitor is used to ‘short’ the ripple to ground but leave the dc to appear at the
output. Various combinations of L and C are also used.
4.13 REGULATORS:
The simplest regulator is a large capacitor in parallel with the load. The
capacitor stores DC voltage while the load voltage increases to its peak value.
The capacitor converts the pulsating DC voltage of a rectifier into a smooth Dc
load voltage.
Two important parameters of a capacitor regulator are its working voltage
and its capacitance. The working voltage must be at least equal to no-load output
voltage of power supply. The capacitance determines the amount of ripple that
appears on the Dc output when current is drawn from the circuit. The amount of
ripple decreases with increase in capacitance.
L-REGULATOR CIRCUIT :
This circuit consists of a series inductor and a capacitance in parallel with
load. The L-regulator is often used in high-power DC supplies.
MC 7800 and 7900 Regulators standard application circuit:
The Mc 7800 is a 3 terminal, positive, fixed voltage integrated circuit
regulator. These regulators employ internal current limiting, thermal shutdown
and safe area compensation. The Mc 7900 is a 3 terminal, negative, fixed voltage
integrated circuit regulator. Mc 7800 and Mc 7900 series requires no external
components.
The input voltage must be at least two volts higher than the output voltage
capacitor c1 is required if the regulator is located far from the power supply.
Capacitor c2 improve the transient response. Both series available in To-220
plastic package and T01-3 metal package.
PIN DETAILS:
IC 7805:
62
FEATURES:
Suitable for TTL, DTL, HTL, C-MOS Power supply.
Internal short-circuit current limiting.
Internal Thermal Overload Protection.
Maximum Output Current of 150mA.
Packaged in TO-92.
ELECTRICAL CHARACTERISTICS:
Input voltage :5V~15V.
Power dissipation :600 mW.
Operating Junction Temperature :-30~150 °C.
Operating Temperature :-30~75 °C.
4.15.1 CAPACITORS:
63
FEATURES:
Enabled high ripple current by a reduction of impedance at high frequency
range.
Load Life : 105°C 2000~5000hours.
Operating Temperature Range :-40~+105°C
Rated Voltage Range :6.3~100V.DC
Capacitance Tolerance :±20%(20°C, 120Hz).
4.15.2 RESISTORS:
FEATURES:
Choice of various viewing angles
Available on tape and reel.
Reliable and robust
Consumes very power.
ELECTRICAL CHARACTERISTICS:
Forward Current (IF) : 15 mA
Operating Temperature (Topr) : -40 to +85 ℃
Storage Temperature (Tstg) : -40 to +100 ℃
Soldering Temperature( Tsol) : 260 ± 5 ℃
Power Dissipation (Pd) : 45 mW
Peak Forward Current (IF Peak) :50 mA
Reverse Voltage (VR) :5 V
65
4.16 MOTOR DRIVER L298D:
PIN DETAILS:
66
TECHNICAL SPECIFICATIONS :
APPLICATIONS:
LIMITATIONS:
4.17 DC PUMP :
A pump is a mechanical device used to move fluids (in this case, water)
from one place to another by increasing the fluid's pressure. In your water tap
system, the pump plays a central role by transferring water from the storage
tank to the tap when the system is activated through the foot lever mechanism.
68
CONSTRUCTION & DESIGN :
Material: Typically made from durable materials like stainless steel, plastic, or a
combination to withstand prolonged submersion and exposure to water.
Size: Compact and lightweight, making it easy to install and handle.
Impeller: Equipped with an impeller that helps in drawing water and pushing it
out through the outlet.
WORKING PRINCIPLE :
Submersion: The pump is designed to be submerged in the fluid it is meant to
pump.
Motor: Driven by a DC motor that operates on a 12V power supply.
Impeller Action: The motor drives the impeller, creating a centrifugal force that
draws water into the pump and then pushes it out through the discharge outlet.
69
Cooling: Water surrounding the pump also acts as a cooling agent for the motor,
preventing overheating.
FEATURES:
Low Voltage Operation: Operates on a 12V DC supply, making it energy
efficient and safe to use in various applications.
High Efficiency: Capable of delivering a consistent and powerful water flow.
Durability: Resistant to corrosion and wear, ensuring long-lasting performance.
Quiet Operation: Produces minimal noise during operation.
APPLICATIONS:
Aquariums: Used to circulate and filter water in fish tanks.
Fountains: Ideal for water features and garden fountains.
Irrigation: Suitable for small-scale irrigation systems in gardens and
greenhouses.
Water Transfer: Efficient for transferring water from one location to another,
such as draining water from basements or containers.
RVs and Boats: Commonly used in recreational vehicles and boats for pumping
water.
MAINTENANCE :
Regular Cleaning: Periodic cleaning of the impeller and inlet to prevent
clogging and ensure smooth operation.
Lubrication: Ensuring the motor and moving parts are properly lubricated to
reduce wear and tear.
70
Inspection: Regular inspection for any signs of damage or corrosion to prolong
the pump's lifespan.
ADVANTAGES :
Energy Efficient: Consumes low power while delivering high performance.
Compact and Portable: Easy to install and transport.
Versatile: Suitable for a wide range of applications.
Reliable: Offers consistent performance and is designed for long-term use.
71
CHAPTER 5
SOFTWARE DETAILS
INSTALLATION :
Now one after another the Arduino software and the USB driver for the
board have to be installed.
72
Two set ups on the program are important and should be considered.
a) The board that you want to connect, has to be selected on the arduino software.
The “Funduino Uno” is here known as “Arduino / Genuino Uno”.
b) You have to choose the right “Serial-Port”, to let the Computer know to which
port the board has been connected. That is only possible if the USB driver has
been installed correctly.
It can be checked this way:
At the moment the Arduino isn't connected to the PC. If you now choose “Port”,
under the field “Tool”, you will already see one or more ports here (COM1/
COM2/ COM3…).
The quantity of the shown ports doesn't depend on the quantity of the USB ports
on the computer. When the board gets connected to the computer, YOU WILL
FIND ONE MOREPORT.
73
ATTENTION: Wait a second! Most of the time the computer can't find the
driver automatically to install it. You might choose the driver by your own to
install it. It can be found in the Arduino file under “Drivers”.
CONTROL: At the control panel of the Computer you can find the “Device
manager”. If the board has been installed successfully, it should appear here.
When the installation has failed, there is either nothing special to find or you will
find an unknown USB device with a yellow exclamation mark.
In this case: Click on the unknown device and choose “update USB driver”.
Now you can start over with the manual installation.
5.2 PROGRAMMING :
Now we can start properly. Without to much theoretical information we
start directly with programming. Learning by doing. On the left side you can find
the “sketches”, on the right the accompanying explanation for the commands in
grey. If you work through the tutorials with this system, you will soon understand
the code and be able to use it by yourself. Later on you can familiarize yourself
with other features. These tutorials are only meant as first steps to the Arduino
world. All possible program features and codes are referred onwww.arduino.cc
under „reference“.
First of all a short explanation for possible error reports that can appear while
working with the Arduino software. The two most common ones are:
1.) The board is not installed right or the wrong board is selected. After uploading
the sketch, there will appear an error report underneath the sketch. It looks like
the one in the picture on the right. The note “not in sync” shows up in the error
report.
74
2.) There is a mistake in the sketch.
For example, a word is misspelled or a bracket is missing. In the example on the
left the last semicolon in the sketch is missing. In this Case the error report often
starts with “excepted..”. This means that the program is still expecting something
that is missing.
6.1 ADVANTAGES:
Reliable
Efficient
Durable
Automated
Accurate
6.2 APPLICATIONS:
Irrigation
Manufacturing
Automotive
Refrigeration
Heating
76
77
CHAPTER 7
CONCLUSION
78
APPENDICES
PROGRAM CODE:
#include<LiquidCrystal.h>
LiquidCrystal lcd(8,9,4,5,6,7);
#include <SoftwareSerial.h>
SoftwareSerial ESP11 = SoftwareSerial(2,3); // RX, TX
#define ONE_WIRE_BUS A2 // DS18B20 Data pin
OneWire oneWire(ONE_WIRE_BUS);
DallasTemperature sensors(&oneWire);
int tempC=0;
#define DEBUG true
// WIFI SHIELD DECLARATION
String ssid = "\"wifi005\"";
String pass = "\"12345678\"";
String tcp = "\"TCP\"";
String remoteip = "\"iot-projects.eweb.org.in\"";
String portnum = "80";
int gs=0;
int lvl=0;
float distance=0;
float duration=0;
int TRIG_PIN=A0;
int ECHO_PIN=A1;
int v=0;
79
int v1=0;
int v2=0;
int p=0;
int level= 0;
void setup() {
Serial.begin(115200);
ESP11.begin(115200);
lcd.begin(16,2);
sensors.begin();
pinMode(10,OUTPUT);
digitalWrite(10,LOW);
pinMode(11,OUTPUT);
digitalWrite(11,LOW);
pinMode(13,OUTPUT);
digitalWrite(13,LOW);
pinMode(12,OUTPUT);
digitalWrite(12,LOW);
pinMode(TRIG_PIN,OUTPUT);
digitalWrite(TRIG_PIN,LOW);
pinMode(ECHO_PIN,INPUT);
lcd.clear();
lcd.setCursor(0,0);
lcd.print(" Loading!....");
sendData("AT+CWMODE=3\r\n",2000,DEBUG); // configure as access point
and Client
80
lcd.setCursor(0,1);
lcd.print(" 20% ");
sendData("AT+RST\r\n",2000,DEBUG); // reset module
lcd.setCursor(0,1);
lcd.print(" 40% ");
sendData("AT+CWLAP\r\n",3000,DEBUG); // List all available AP's*/
lcd.setCursor(0,1);
lcd.print(" 60% ");
sendData("AT+GMR\r\n",2000,DEBUG); // View version Info
lcd.setCursor(0,1);
lcd.print(" 90% ");
sent();
delay(1000);
lcd.clear();
lcd.setCursor(0,0);
lcd.print(" Water");
lcd.setCursor(0,1);
lcd.print("Distribution");
void loop() {
sensors.requestTemperatures();
tempC = sensors.getTempCByIndex(0);
level = measureWaterLevel();
81
lcd.clear();
lcd.setCursor(0,0);
lcd.print("Water Lvl:");
lcd.setCursor(11,0);
lcd.print(level);
lcd.setCursor(0, 1);
lcd.print("Temp: ");
lcd.print(tempC);
sent();
if (level>=90)
{p=0; digitalWrite(10,LOW);}
else if((level>=20)&&(level<=95))
{
digitalWrite(A5,HIGH);
digitalWrite(11,HIGH);
v=1;sent();
delay(5000);
digitalWrite(11,LOW);
digitalWrite(12,HIGH);
v=0;v1=1;
delay(5000);
digitalWrite(12,LOW);
digitalWrite(13,HIGH);
v=0;v1=0;v2=1;
82
delay(5000);
digitalWrite(12,LOW);
digitalWrite(13,LOW);
digitalWrite(A5,LOW);
v=0;v1=0;v2=0;
delay(10000);
}
else if(level<=19)
{
digitalWrite(12,LOW); digitalWrite(11,LOW);
digitalWrite(13,LOW);digitalWrite(A5,LOW);
digitalWrite(10,HIGH);
p=1;v=0;v1=0;v2=0;
}
sent();
delay(1000);
}
int measureWaterLevel() {
digitalWrite(TRIG_PIN, LOW);
delayMicroseconds(2);
digitalWrite(TRIG_PIN, HIGH);
delayMicroseconds(10);
digitalWrite(TRIG_PIN, LOW);
long duration = pulseIn(ECHO_PIN, HIGH);
int distance = duration * 0.034 / 2;
83
int level = map(distance, 0, 30, 100, 0); // Adjust "30" for tank depth
return constrain(level, 0, 100);
}
void sent()
{
85
REFERENCE
86
Water Networks," ACM Transactions on Sensor Networks (TOSN), Mar.
2017.
[8] G. Hajgató, G. Paál, & B. Gyires-Tóth, "Deep Reinforcement
Learning for Real-Time Optimization of Pumps in Water Distribution
Systems," Journal of Water Resources Planning and Management, Oct.
2020.
[9] F. R. Ishengoma, "A Novel Design of IEEE 802.15.4 and Solar
Based Autonomous Water Quality Monitoring Prototype using ECHERP,"
International journal of Computer Science & Network Solutions, Oct. 2014.
[10] S. Valai Ganesh, V. Suresh, S. G. Barnabas, & S.
Rajakarunakaran, "Innovative Solid Waste Management Strategies for
Smart Cities in Tamil Nadu: Challenges, Technological Solutions, and
Sustainable Prospects," Discover Applied Sciences, vol. 6, no. 660, Dec.
2024.
87