FDRE TECHNICAL AND VOCATIONAL TRAINING INSTITUTE
LOW VOLTAGE DISTRIBUTION TRANSFORMER MONITORING AND PREVENTION
A Thesis Project Submitted to the Department of Electrical and Electronics Technology (EETD) in Partial
Fulfillment of the Requirements for the Degree of Bachelor of Science in Electrical and Electronics Technology
BY:- NAME
ID NO
1. Lencho Alemu
Tie/362/12
2. Solomon Mekonen
Tie/492/12
3. Mahlet Asfaw
Tie/369/12
4. Alemayehu Gezahegn
Tie/052/12
5. Masresha Gursha
Tie/376/12
Adviser: Mr. Seifu Getahun
Submission date: February 14, 2024
Addis Abeba,Ethiopia
LION
Declaration
We declare that this thesis, titled "Low Voltage Distribution Transformer Monitoring and Prevention,"
submitted in partial fulfillment of the requirements for the degree of Bachelor of Science in Electrical
and Electronics Technology, is a record of original work carried out by us as a group, under the
supervision of Mr. Seifu Getahun. This work has not formed the basis for the award of any other degree
or diploma, in this or any other institution or university. In accordance with ethical practices in
reporting scientific information, due acknowledgements have been made wherever the findings of
others have been cited.
Name of Students with Signature:
Date of Submission:
1
Acknowledgements
We would like to extend our heartfelt gratitude to our advisor, Mr. Seifu Getahun for his
invaluable guidance, unwavering encouragement, and consistent support throughout the
course of this thesis. His expertise and insights have been instrumental in shaping this work.
We are also deeply thankful to the faculty and staff of the department for their assistance,
resources, and encouragement, which have been crucial to the completion of this project.
Finally, we express our sincere appreciation to everyone who contributed to the successful
completion of this thesis, whether through direct involvement or indirect support. Your
contributions have made this journey possible, and we are truly grateful.
2
Table of Contents
Acknowledgements ............................................................................................................................................. 2
List of Tables........................................................................................................................................................ 5
List of Figures And Illustrations ........................................................................................................................... 6
List of Acronyms And Abbreviations ................................................................................................................... 7
Abstract ............................................................................................................................................................... 8
Chapter 1 Introduction........................................................................................................................................ 9
1.1.
Background ............................................................................................................................................. 9
1.2.
Statement of the Problem..................................................................................................................... 10
1.3.
Objectives .............................................................................................................................................. 11
1.3.1.
General objectives............................................................................................................................. 11
1.3.2.
Specific objectives ............................................................................................................................. 11
1.4.
Scope ..................................................................................................................................................... 11
Chapter 2 Literature Review ............................................................................................................................. 13
Chapter 3 Material And Methodology ............................................................................................................. 16
3.1.
Method .................................................................................................................................................. 16
3.1.1.
Block diagram .................................................................................................................................... 16
3.1.2.
Flow chart .......................................................................................................................................... 17
3.2.
Material ................................................................................................................................................. 18
3.2.1.
ACS712 Current Sensor ..................................................................................................................... 18
3.2.2.
LM35 (Temperature Sensor) ............................................................................................................. 19
3.2.3.
Ultrasonic sensor ............................................................................................................................... 21
3.2.4.
Transformer....................................................................................................................................... 22
3.2.5.
GSM Modem ..................................................................................................................................... 23
3.2.6.
Alphanumeric LCD Display ................................................................................................................ 24
3.2.7.
ATmega328 microcontroller ............................................................................................................. 25
3.2.8.
Relay .................................................................................................................................................. 26
3.2.9.
I2C converter ..................................................................................................................................... 27
3.2.10.
Crystal oscillator ................................................................................................................................ 28
3.2.11.
Ceramic capacitor.............................................................................................................................. 29
3.2.12.
Micro push button............................................................................................................................. 30
3.2.13.
Resistor .............................................................................................................................................. 31
Chapter 4 Results And Discussion ..................................................................................................................... 32
Observation ....................................................................................................................................................... 32
4.2.
Discussions ............................................................................................................................................ 36
3
Chapter 5 Conclusions And Recommendations ................................................................................................ 37
5.1.
Conclusions ........................................................................................................................................... 37
5.2.
Recommendation .................................................................................................................................. 37
References......................................................................................................................................................... 38
Appendix ........................................................................................................................................................... 39
4
List of Tables
Table 1: Pin Diagram of Current Sensor ………………………………………………………………………………..12
Table 2: LM35 Sensor Pinout Configuration…………………………………………………………………………..13
5
LIST OF FIGURES AND ILLUSTRATIONS
FIGURE
PAGE
Figure 1: The Block Diagram of the System ………………………………………………………………………………………..…………16
Figure 2: Flowchart of Monitoring and Prevention of Low Voltage Distribution Transformer ….………………….17
Figure 3: ACS712 Current Sensor……………………….……………………………………………………………………………………..……..18
Figure 4: Temperature Sensor (LM35) ……………………………………………………………………………………………………………..20
Figure 5: Ultrasonic Sensor ……………….…………..……………………………………………………………………………………………….21
Figure 6: Transformer ……………………..……………………………………………………………………………………………………………..22
Figure 7: GSM Modem SIM900A ………………..………….………………………………………………………………….…………………….23
Figure 8: Alphanumeric LCD Display………………..……….………………………………………………………….…………………….....24
Figure 9: Atmega328 Microcontroller ………….……………………………………………………………………….……………………….25
Figure 10: Relay Module…………………………………..………………………………………………………………………………………………26
Figure 11: I2C Converter ………………………………..…………….…………………………………………………………………………………27
Figure 12: Crystal Oscillator…………………………….……………………………………………………………………………………………….28
Figure 13: Ceramic Capacitor……………………….…..……….…………………………………………………………………………………….29
Figure 14: Micro Push Button………………………..…………………………………………………………………………………………………30
Figure 15: Resistor ……………………………………….…….…………………………………………………………………………………………..31
Figure 16: Normal Condition…………………….…..…….………………………………………………………………………………………….32
Figure 17: When Temperature High……………...……………………………………………………………………………………………….32
Figure 18: When Oil Level Low …………………..………..………………………………………………………………………………………….33
Figure 19: When Oil Tank Full………………………………………………………………………………………………………….................33
Figure 22: Simulation Circuit………………………………………………………………..………………………………………………….……..34
Figure 23: Hardware Circuit………………...…………………………………………………………………………………………………………35
6
LIST OF ACRONYMS AND ABBREVIATIONS
No.
Abbreviation
Description
1
AC
Alternating current
2
DC
Direct current
3
RTC
Real time clock
4
DT
Distribution transformer
5
VT
Voltage transformer
6
CT
Current transformer
7
GSM
Global system for mobile communication
8
SCADA
Supervisory Control and Data Acquisition System
9
DTCM
Distribution Transformer Condition Monitoring
10
M2H
Machine to Human
11
GPRS
General Packet Radio Service
12
SMS
Short Message Service
13
EEPROM
Electrically Erasable Programmable Read Only Memory
14
ADC
Analog to Digital Convertor
15
NetCBM
Network Condition-Based Monitoring
16
O.L
Oil Level
17
T.V
Temperature level
18
P.V
Preset Value
7
ABSTRACT
The aim of this thesis is to design a monitoring and protection system for distribution transformers
using GSM technology. The current monitoring system relies on manual intervention, which is timeconsuming and makes fault prediction challenging. In this project, we designed a system that
continuously monitors key transformer parameters, such as load current, voltage, oil level, and
ambient temperature, using sensors. These values are displayed in real-time on an LCD screen and
recorded in the system's memory. If any abnormalities are detected, an alert message containing the
parameter values and the transformer's location is sent to the monitoring center via a GSM modem
interfaced with a microcontroller. This system ensures the smooth operation of the transformer and
helps identify potential issues before they lead to catastrophic failures.
Keywords: GSM modem, distribution transformer, monitoring, protection, overload, temperature,
microcontroller, sensors.
8
Chapter 1
Introduction
1.1.
Background
A Transformer, device that transfers electric energy from one alternating-current circuit to one or more
other circuits, either increasing (stepping up) or reducing (stepping down) the voltage. Transformers
are employed for widely varying purposes. For example , to reduce the voltage of conventional power
circuits to operate low-voltage devices, such as doorbells and toy electric trains, and to raise the voltage
from electric generators so that electric power can be transmitted over long distances. Transformers
change voltage through electromagnetic induction; i.e., as the magnetic lines of force (flux lines) build
up and collapse with the changes in current passing through the primary coil, current is induced in
another coil, called the secondary. The secondary voltage is calculated by multiplying the primary
voltage by the ratio of the number of turns in the secondary coil to the number of turns in the primary
coil, a quantity called the turns ratio.
Transformers are widely used as single and three-phase power supply units in power generation plants,
substations, distribution systems, and step-down regulators in industrial equipment. They play a critical
role in the distribution of electrical power , as they are responsible for transforming the high-voltage
electricity from the power plants into low-voltage electricity that can be used by consumers. A power
transformer is used in the National Power Grid to step up or step down alternating current (AC)
voltages. Conversion from AC to DC is typically done by rectifiers. AC electricity can be transformed
into DC electricity at a power plant. The AC electricity can then be transmitted over long distances by
wires or a grid system. One type of transformer is an oil-immersed transformer. A transformer often
operates in high energy, high-heat situations. An oil-filled transformer suspends the transformer of a
steel tank filled with oil. The oil cools and insulates the transformer. The oil uses convection to move
around and through the transformer, cooling it.
The electrical equipment and circuits in a substation must be protected in order to limit the damages
due to abnormal currents and over voltages. All equipment installed in a power electrical system have
standardized ratings for short-time withstand current and short duration power frequency voltage. The
role of the protection systems is to ensure that these withstand limits are never exceeded, therefore
clearing the faults as fast as possible. To avoid oil deterioration, transformer oil must be kept at an
operating temperature below 85°C. For optimal performance and to prevent excessive oil
deterioration, the daily average operating temperature should be around 30°C
In addition to this requirement, a protection system must be selective. Selectivity means that any fault
must be cleared by the device of current interruption (circuit breaker or fuses) being the nearest to the
fault, even if the fault is detected by other protections associated with other interruption devices. The
protection of a transformer against overloads is performed by a dedicated device, usually called a
thermal overload relay .This type of protection simulates the temperature of the transformer’s
windings. The simulation is based on the measure of the current and on the thermal time constant of
the transformer. Some relays are able to take into account the effect of harmonics of the current due
to non-linear loads such as rectifiers, computers, variable speed drives etc.
9
1.2.
Statement of the Problem
Power distribution transformers are essential components of electrical power systems, responsible for
stepping down high transmission voltages to lower distribution levels-voltage . However, these
transformers are prone to catastrophic failures, such as explosions, which pose significant safety risks,
economic losses, and environmental damage. There is a critical need for a system capable of remotely
monitoring and controlling transformers in real time to ensure their health and operational efficiency.
This system should track key parameters such as oil level, load current, temperature, and other critical
factors to prevent failures.
Overloading is a major cause of transformer failures, significantly reducing their lifespan and leading to
unexpected breakdowns. Such failures result in power supply interruptions for consumers and reduced
reliability of the power system. Additionally, insufficient cooling exacerbates these issues, further
increasing the risk of damage. To address these challenges, a GSM-based monitoring system can be
implemented. This system utilizes multiple sensors to collect data, detect abnormalities based on
predefined thresholds, and transmit this information to the control room via short message service
(SMS). The entire operation is managed by a microcontroller board powered by the Microchip
ATmega328 IC.
10
1.3.
Objectives
1.3.1. General objectives
To ensure reliable power supply by designing a GSM-based monitoring and protection system for
low-voltage distribution transformers, integrating real-time parameter tracking, automated
safeguards, and predictive fault detection to enhance operational safety, reduce downtime, and
minimize maintenance costs.
1.3.2. Specific objectives
1.4.
To address oil level, overvoltage, and overloading problems in power in power distribution
transformers through automation
Automate critical fault detection for oil level depletion, overvoltage (>15V), and overloading
(>110% rated current) using sensor networks and microcontroller-based logic.
Implement real-time monitoring of voltage, current, temperature, and oil level via ACS712
current sensors, LM35 temperature sensors, and ultrasonic sensors.
Develop GSM-based SMS alerts to notify operators of abnormalities (e.g., temperature >40°C,
oil level <20 cm) using a SIM900A modem.
Design a local LCD interface to display real-time transformer parameters (voltage, current,
temperature, oil level).
Integrate relay control to disconnect the transformer during faults (e.g., overloads,
overheating) using a 1-channel relay module.
Calibrate sensor thresholds to trigger protective actions at 110% of the transformer’s rated
current capacity.
Scope
This thesis will investigate and develop a GSM-based system for the monitoring and protection of low
voltage distribution transformers. The scope includes the following key areas:
Current State Analysis:
Evaluate existing GSM-based monitoring and protection systems for low voltage distribution
transformers.
Identify the limitations and challenges in current approaches, including cost, accuracy, reliability, and
security.
Analyze the specific needs and challenges related to low voltage distribution transformers in the target
region (e.g. specific fault types, environmental conditions, communication infrastructure).
System Design:
Design the architecture of the proposed GSM-based monitoring and protection system, including
hardware components (sensors, microcontroller, GSM module) and software components (data
acquisition, processing, and communication modules).
11
Select appropriate sensors for monitoring key parameters such as current, voltage, temperature, and
oil level.
Design the communication protocol between the transformer monitoring unit and the central
monitoring station.
Consider power consumption and energy efficiency of the proposed system, especially for remote
installations.
Implementation:
Implement the proposed GSM-based monitoring system on selected low voltage distribution
transformers.
Integrate the system with existing power distribution infrastructure, ensuring seamless communication
via GSM networks.
Develop a user interface for monitoring and controlling the system.
Fault Detection:
Develop algorithms for fault detection and classification, optimized for GSM data transmission. This
may include considering data compression techniques to minimize transmission costs.
Evaluate the performance of the fault detection algorithms in terms of accuracy, speed, and
robustness.
Implement fault notification mechanisms via SMS or other communication channels.
Testing and Validation:
Conduct rigorous testing of the implemented system under various operating conditions and simulated
fault scenarios.
Evaluate the performance of the system in terms of its ability to detect and classify faults accurately
and reliably.
Analyze the communication performance of the GSM-based system, including latency, data loss, and
network coverage.
12
Chapter 2
Literature Review
A transformer is a crucial part of the network of the electricity system. Power systems face significant
obstacles in data collecting, condition monitoring, automatic controlling, and protection since there
are so many transformers dispersed across such a broad area in various segments. Thermal overload
and inrush currents are problems that transformers can handle.[5]
Distribution Transformers are a critical element of any electricity supply system offering high levels of
reliability with relatively low maintenance requirements. However, their reliability should not be taken
for granted. Although it is very rare that transformer failure will happen, those that do often have a
catastrophic impact.
When a transformer fails the cost of damages can far exceed the simple replacement cost. The
aftermath of the failure must be cleaned up, damaged equipment must be repaired or replaced, and
there are other losses that may be substantial including lost production time, damaged credibility,
regulatory fines, or civil lawsuits.
Here are seven of the most common causes of transformer failure:
Age-The age of the transformer can lead to its failure. However, it's not necessarily the calendar
time, but the cumulative operating hours at a high load. A transformer with continuous 24/7 cycle
of high load will age about four times as fast as one with a 5-day 8- hour load cycle.
Major Leakages - Moisture and oxygen can enter a transformer through leaking gaskets causing
accelerated _ ageing of insulation and insulation failure. Leaks can be caused by cracks, tank
damage, sealant damage, deformation, weld cracking and many other issues and have the
potential to cause environmental harm if not adequately contained. Transformer failure
investigation - transformer leaking from radiators
Inadequate Maintenance -Transformer maintenance is primarily concerned with ensuring the
level and condition of the oil and ensuring moisture does not enter the tank. Annual maintenance
is the easiest way to be proactive in reducing the likelihood of transformer failures.
Overloading / Overheating Maintenance allows you to make sure the electrical load settings are
appropriate for the specific type of transformer being used. Overloading causes overheating, and
eventually, thermal degradation which will reduce the effectiveness of the winding insulation.
Moisture- Moisture in a liquid-filled transformer can cause issues that result in irreversible damage
to the insulation. If the transformer tank is not properly sealed, moisture will eventually work its
way into the insulating fluid. In the case of free-breathing transformers, it is also possible for
moisture to enter a transformer during the natural breathing process if the silica gel is not well
maintained. transformer failure due to extra moisture
13
Left to Disrepair - Transformers that are left to disrepair are often a tell-tale sign that transformer
failure could happen. Substations that are overgrown with shrubbery, have the potential to result
in damage by trees, obstruction of radiators and other external factors like animals, which could
all influence the failure of the transformer. Transformer failure due to being left to disrepair
Lightning Surges - Lightning surges are very capable of destroying the function of a transformer
however due to a combination of transformer design and the low lightning density within the UK,
this is less common a phenomenon compared to the above factors.
It is key to ensure transformers are designed and manufactured for their intended application. A good
construction transformer fit for purpose should not fail prematurely provided an adequate
maintenance regime is adopted. Transformers have a long-life expectancy unless something outside
the design specification happens. It is vital to perform regular checks on the loading of your
transformers. Electrical transformers that operate below the maximum load capacity have A longer
lifespan.
Planned maintenance, inspection and testing will significantly reduce the number of transformer
failures. Transformer preventive maintenance is very important, immediate preventative action can be
taken to avoid any unexpected outages.[6]
Absent condition monitoring, transformer downtime might reach 20% of its life cycle. By using the right
condition-monitoring systems, this can be decreased to less than 2%.Some of the current industrial
practices in Distribution transformer condition monitoring have been identified by a survey, including
(i) online monitoring using SCADA (Supervisory Control and Data Acquisition System), (ii) sweep
frequency response analysis, (iit) network condition-based monitoring (NetCBM), (v) using a Zigbee and
Arduino board, and (vi) using GSM and GPRS systems. GSM- based remote distribution transformer
condition monitoring is one of these techniques that is used in this study due to various logical benefits.
GSM technology was chosen because it can monitor individual distribution remotely and is more userfriendly, whereas alternative approaches, such as the widely used SCADA, are more expensive and
localized. Using GSM-based remote condition monitoring of Distribution Transformer operational
parameters in real-time helps to detect incipient failures and notify field engineers via alert text SMS
.The aberrant condition reported is critical for decision-making and assessment, which aids in reducing
downtime and maintenance costs, boosting total equipment life, and assisting in preserving system
reliability.[7]
GSM Based Remote Distribution Transformer Condition Monitoring System
The main motive of this thesis research pertains to designing and implementing a remote machine tohuman (M2H) communication system that provides a remote distribution transformer condition
monitoring (DTCM) system. The proposed system is a remote mobile embedded system that integrates
a GSM/GPRS module, interfaced with an Arduino microcontroller board, and sensors.[8]
14
Distribution Transformer Monitoring and Controlling using GSM Modem
The purpose of this project is to acquire the remote electrical parameters like voltage, current, and
temperature and send these real-time values over the network at the power station. This project is also
designed to protect the electrical circuitry by operating a relay that gets activated whenever the
parameters exceed the predefined limits.[9]
Monitoring and Control of 500 KVA Transformers through GSM Based Raspberry Pi Controller
A monitoring system, which integrates a Global Mobile System modem with a standalone single- chip
Raspberry PI3 controller, works like a mini-computer. When there is any abnormal or emergency
condition, the system sends a short message through GMS based mobile network i.e SMS to the mobile
phone.[10]
Design and Implementation of GSM-based Monitoring System for a Distribution Transformer
A monitoring system that can continuously check the distribution transformer's temperature level and
predict faults such as overheating and overcurrent has been developed. Fault diagnosis is relayed to
the base station through a GSM modem. After receiving the message of any abnormality remedial
action can be taken immediately.[11]
15
Chapter 3
Material And Methodology
3.1.
Method
This work presents the development and construction of mobile system that tracks records important
operation indicator of distribution transformers. These indicators include load currents, transformer
oil, and ambient temperatures. The proposed online monitoring system combines a stand-alone singlechip micro-controller, a Global Service Mobile (GSM) Modem, and sensor packages. At the distribution
transformer installation site, the system records the mentioned parameters. The acquired parameters
are then processed and stored in the system memory. Following the established instructions, the
system sends an SMS (Short Message Service) message to specific mobile phones, providing
information about any irregularity or emergency scenario. Moreover, based on the instructions stored
in the embedded system's EEPROM, the system sends an SMS to specific mobile phones, notifying them
about any abnormal or emergency situation. Additionally, it utilizes the GSM modem to transmit an
SMS to a central database for further processing. With the help of this portable device, utilities can
effectively utilize transformers and identify issues.
3.1.1. Block diagram
The block diagram, flowchart of the system, and circuit diagram of the proposed GSM-based
transformer monitoring system are shown respectively
Current sensor
module
GSM
Voltage sensor
module
LCD display
Temperature
sensor module
Microcontroller
Atmega328IC
Relay
Ultra-sonic sensor
module
Real time clock
Figure 1: The block diagram of the system
16
3.1.2. Flow chart
Start
Initialize all ports &module
Sense transformer voltage, current, oil level and
temperature and clock time schedule
Current and voltage calculation and comparison
Is there difference
between thresholds?
YES
NO
NO
O.L<P.V
Send SMS through GSM
NO
T.V>P.V
YES
Active protection relay
Send SMS through GSM
END
Figure 2: Flowchart of Monitoring and Prevention of Low Voltage Distribution Transformer
17
3.2.
Material
On the transformer site, sensors are mounted to read and quantify the physical quantity coming from
the distribution transformer before converting it to an analogue signal. The load current, oil
temperature, and oil level are all sensed via sensors. When touched, sensor is an object that detects
signals and reacts accordingly. For online monitoring, a wide range of distinct measurable variables can
be gathered
3.2.1. ACS712 Current Sensor
The ACS712 is a fully integrated, hall effect-based linear current sensor with 2.1kVRMS voltage isolation
and a integrated low-resistance current conductor. Technical terms aside, it's simply put forth as a
current sensor that uses its conductor to calculate and measure the amount of current applied. It has
a capability to measure 66 to 185 mV/A output sensitivity. For current sensors that work by direct
sensing, ohm's law is being applied to measure the drop in voltage when flowing current is detected.
But the ACS712, it uses indirect sensing. Current flows through the onboard hall sensor circuit in its IC.
The Hall Effect sensor detects the incoming current through its magnetic field generation Once
detected, the Hall Effect sensor generates a voltage proportional to its magnetic field that's then used
to measure the amount of current.
Figure 3:ACS712 Current Sensor
18
Table 1: Pin diagram of Current Sensor
Terminal list table
Number
1 and 2
3 an 4
5
6
7
8
Name
IP+
IPGND
FILTER
VIOUT
VCC
Description
Terminals for current being sampled ,fused internally
Terminals for current being sampled ,fused internally
Signal ground terminal
Terminal for external capacitor that sets bandwidth
Analog output signal
Device power supply terminal
3.2.2. LM35 (Temperature Sensor)
LM35 is a temperature sensor that outputs an analog signal which is proportional to the instantaneous
temperature. The output voltage can easily be interpreted to obtain a temperature reading in Celsius.
The advantage of lm35 over thermistor is it does not require any external calibration.
LM35 can measure from -55 degrees centigrade to 150-degree centigrade. The accuracy level is very
high if operated at optimal temperature and humidity levels. The conversion of the output voltage to
centigrade is also easy and straight forward. The input voltage to LM35 can be from +4 volts to 30 volts.
It consumes about 60 microamperes of current.
In order to understand the working principle of LM35 temperature sensor we have to understand the
linear scale factor. In the features of LM35 it is given to be-+-1 0 mills volt per degree centigrade.It
means that with increase in output of 10 mills volt by the sensor Vout pin the temperature value
increases by one. For example, if the sensor is outputting 100 mills volt at Vout pin the temperature
In centigrade will be 10-degree centigrade. The same goes for the negative temperature reading. If the
sensor is outputting -100 mills volt the temperature will be -10 degrees Celsius,
The formula t converts the voltage to centigrade temperature Centigrade Temperature = Voltage Read
by ADC / 10 mV (mills Volt)
19
Figure 4: LM35 Sensor Pin out Configuration
PIN NUMBER
1
2
Pin number
Vcc
ANALOG OUT
3
GROUND
Description
Input voltage is +5V for typical application
There will be increase in 10mV for raise of every 1C. can range from 1v(-55C) to 6v (150C)
Connected to ground of circuit
20
3.2.3. Ultrasonic sensor
An ultrasonic sensor is an instrument that measures the distance to an object using ultrasonic sound
waves. An ultrasonic sensor uses a transducer to send and receive ultrasonic pulses that relay back
information about an object's proximity. High-frequency sound waves reflect across boundaries to
produce distinct echo patterns.
Ultrasonic sensors work by sending out a sound wave at a frequency above the range of human hearing.
The transducer of the sensor acts as a microphone to receive and send the ultrasonic sound, like many
others, use a single transducer to send a pulse and to receive the echo. The sensor determines the
distance to a target by measuring time lapses between the sending and receiving of the ultrasonic
pulse. It sends an ultrasonic pulse out at 40 kHz, which travels through the air, and if there is an obstacle
or object, it will bounce back to the sensor. By calculating the travel time and the speed of sound, the
distance can be calculated. Ultrasonic sensors are a great solution for the detection of clear objects.
For 1iquid level measurement, applications that use infrared sensors, for instance, struggle with this
particular use case because of target translucence.
For presence detection, ultrasonic sensors detect objects regardless of color, surface, or material
(unless the material is very soft, like wool, as it would absorb sound). It is used to detect oil level in the
transformer. How Ultrasonic Sensors Work – MaxBotix
Figure 5: Ultrasonic sensor
21
3.2.4. Transformer
Transformers change voltage through electromagnetic induction; i.e., as the magnetic lines of force
(flux lines) build up and collapse with the changes in current passing through the primary coil, current
is induced in another coil, called the secondary. The secondary voltage is calculated by multiplying the
primary voltage by the ratio of the number of turns in the secondary coil to the number of turns in the
primary coil, a quantity called the turns ratio.
A step-down transformer is used in the system. As the line voltage is 220 V AC so it needed to step
down the voltage to 12 V AC.
Figure 6: Transformer
22
3.2.5. GSM Modem
Using a GSM wireless network requires a GSM modem, which is a wireless modem. SIM900A is a quadband GSM/GPRS engine that operates on the frequencies GSM 850 MHz, EGSM 900 MHz, DCS 1800
MHz, and PCS 1900 MHz It was created for the global market.
The AT command makes configuring this simple. The SIM900A is integrated with the TCP/IP protocol;
extended TCP/IP AT commands are developed for customers to use the TCP/IP protocol easily, which
is very useiful for those data transfer applications. A GSM modem functions similarly to a dial-up
modem. Apart from the standard AT commands, GSM modems also support an extended set of AT
commands. These extended sets of AT commands are defined in the GSM standards. With the extended
AT commands, several things are done:
To read, write and delete SMS messages.
To send SMS messages.
To monitor the signal strength
To monitor the charging status and charge level of the battery
Figure 7: GSM Modem SIM900A
23
The instructions for managing a modem are known as AT commands. Attention is referred to as AT.A
command line always begins with "AT" or "at." Because of this, AT commands are the names for
modem commands. A large number of the instructions are likewise utilized to manage wired dial-up
modems. Mobile phones and GSM/GPRS modems can support these. In addition to this standard AT
command set, GSM/GPRS modems and mobile phones additionally offer AT command sets exclusive
to the GSM technology, which also contains SMS include commands.
3.2.6. Alphanumeric LCD Display
A line of 20x4 character LCD modules is available under the Display Tech 204G series. These modules
have an exterior dimension of 98x60 mm and a viewing area on the display of 77x25.2 mm. STN or
FSTN LCD modes of the 204G 20x4 LCD displays are offered with or without an LED backlight.
Figure 8: Alphanumeric LCD Display
There are several color possibilities for the backlight, including yellow-green, white, blue, pure green,
and amber. For a free quote on a 20x4 character LCD from the 204G series, contact Display Tech
directly.
24
3.2.7. ATmega328 microcontroller
The ATmega328 is a low-cost, low-power microcontroller that's often used in autonomous systems and
other projects. It's also a component of many Arduino products.
Features
Architecture: The ATmega328 uses Reduced Instruction Set Computing (RISC) architecture.
Power consumption: The ATmega328 is highly efficient and consumes little power.
Memory: The ATmega328 has 32 KB of program flash memory and 2,048 B of SRAM.
CPU speed: The ATmega328 has a CPU speed of 20 MIPS/DMIPS.
Pins: The ATmega328 has 28 pins in total, including 6 analog pins.
Applications
Motor control
Data acquisition
Consumer electronics
Prototyping
LED matrix interfacing
UART communication
Opt coupler interfacing
Arduino:-The ATmega328P is the microcontroller that powers the Arduino Uno development board.
The Arduino board makes it easier to interface with the pins on the ATmega328P.
Figure 9: ATmega328 microcontroller
25
3.2.8. Relay
A "1 channel relay" refers to a single-channel relay module, which is essentially an electronic switch
that can be controlled by a low-power electrical signal, allowing you to switch a high-power device on
or off using a low-voltage control signal, often used in conjunction with microcontrollers like Arduino
to control devices like motors, lights, or appliances with a single control pin.
Key points about a 1 channel relay:
Function: It acts as a switch that can be activated by a low-voltage signal, enabling you to control a
high-voltage or high-current circuit with a low-power signal.
Components: Inside the module, there's a coil that creates a magnetic field when energized, which
then activates a mechanical switch to connect or disconnect the circuit.
Terminals: Typically has three terminals: "Common" (COM), "Normally Open" (NO), and "Normally
Closed" (NC).
Application: Commonly used in automation projects where you need to control high-power devices
with a microcontroller or other low-voltage control circuits.
Figure 10: 1 channel relay
26
3.2.9. I2C converter
An "I2C converter" is a small electronic circuit board that translates data from a standard parallel
interface to the I2C communication protocol, allowing devices that use a parallel data format to
connect and communicate with a microcontroller or other device using only two wires (SDA and SCL)
via the I2C bus; essentially acting as an adapter between a device with multiple data lines and the I2C
standard.
Key points about I2C converters:
Function: They take data from a device with multiple data pins and convert it into a serial stream
suitable for transmission over the I2C bus.
Common application: Often used to connect devices like LCD displays to microcontrollers, where an
I2C converter simplifies the wiring by reducing the number of required pins.
How it works: The converter chip typically has a dedicated I2C slave address, allowing the
microcontroller to send commands and data to the converter which then distributes it to the connected
device's parallel data pins.
Benefits:
Reduces the number of wires needed to interface with a device
Simplifies wiring complexity on a circuit board
Allows for easy integration of various devices using the I2C protocol
Figure 11:I2C converter
27
3.2.10. Crystal oscillator
A crystal oscillator is an electronic circuit that utilizes a piezoelectric quartz crystal to generate a very
stable and precise frequency signal, often used in applications like clocks, computers, and
communication devices to provide accurate timing by converting electrical energy into mechanical
vibrations within the crystal and back again; essentially, it's a device that produces a consistent
electrical signal based on the natural resonant frequency of a quartz crystal when voltage is applied to
it.
Key points about crystal oscillators:
Piezoelectric effect: The core principle is the piezoelectric effect, where a quartz crystal vibrates at
a specific frequency when an electrical voltage is applied to it.
Stability: Crystal oscillators are known for their exceptional frequency stability, meaning they
maintain a very consistent output frequency even under varying temperature conditions.
Applications: Widely used in clocks, watches, computers, communication systems, and other
electronic devices where precise timing is crucial.
Figure 12: Crystal oscillator
28
3.2.11. Ceramic capacitor
A ceramic capacitor is a fixed-value capacitor where the ceramic material acts as the dielectric. It is
constructed of two or more alternating layers of ceramic and a metal layer acting as the electrodes.
The composition of the ceramic material defines the electrical behavior and therefore applications.
Ceramic capacitors are divided into two application classes:
Class 1 ceramic capacitors offer high stability and low losses for resonant circuit applications.
Class 2 ceramic capacitors offer high volumetric efficiency for buffer, by-pass, and coupling
applications.
A typical ceramic through-hole capacitor
Ceramic capacitors, especially multilayer ceramic capacitors (MLCCs), are the most produced and used
capacitors in electronic equipment that incorporate approximately one trillion (1012) pieces per
year.[1]
Ceramic capacitors of special shapes and styles are used as capacitors for RFI/EMI suppression, as feedthrough capacitors and in larger dimensions as power capacitors for transmitters
Figure 13: Ceramic capacitor
29
3.2.12.
Micro push button
A "micro push button" refers to a very small, sensitive push button switch, often called a "micro switch,"
which requires minimal pressure to activate and is commonly used in appliances, electronics, and other
devices where a precise, small-scale switch is needed; essentially, it's a tiny version of a regular push
button with a high level of sensitivity.
Key points about micro push buttons:
Small size: They are significantly smaller than standard push buttons, allowing for compact
integration into devices.
High sensitivity: Only a small amount of force is required to activate the switch.
Spring mechanism: Most micro switches use a spring-loaded mechanism to quickly snap back to
their original position after being pressed.
Applications: Commonly found in appliances like washing machines, microwaves, and refrigerators,
as well as in control panels, robotics, and safety devices.
Figure 14: Micro push button
30
3.2.13. Resistor
A resistor is a passive two-terminal electrical component that implements electrical resistance as a
circuit element. In electronic circuits, resistors are used to reduce current flow, adjust signal levels, to
divide voltages, bias active elements, and terminate transmission lines, among other uses. High-power
resistors that can dissipate many watts of electrical power as heat may be used as part of motor
controls, in power distribution systems, or as test loads for generators. Fixed resistors have resistances
that only change slightly with temperature, time or operating voltage. Variable resistors can be used
to adjust circuit elements (such as a volume control or a lamp dimmer), or as sensing devices for heat,
light, humidity, force, or chemical activity. Resistors are common elements of electrical networks and
electronic circuits and are ubiquitous in electronic equipment. Practical resistors as discrete
components can be composed of various compounds and forms. Resistors are also implemented within
integrated circuits.
The electrical function of a resistor is specified by its resistance: common commercial resistors are
manufactured over a range of more than nine orders of magnitude. The nominal value of the resistance
falls within the manufacturing tolerance, indicated on the component.
Figure 15: Resistor
31
Chapter 4
Results And Discussion
Observation
The system starts by initializing the parameters references and checking their actual values by
comparing with it. When Arduino and GSM are programmed and run under exact working conditions,
we obtain the desired result. Relay function is executed in parallel with GSM, which transmits the
data along with the parameter values.
If the temperature, voltage, and current readings are higher than the predefined levels, send a text
message (SMS) to the selected sim number using the format indicated below. It is also possible to
grant the request to evaluate the transformer's condition. Only by sending the GSM program an SMS
request.
Figure 16: Normal Condition
Figure 17: When Temperature High
32
Figure 18: When Oil Level Low
Figure 19: When Oil Tank Full
33
Figure 21: Protection Relay Active
Figure 22: Simulation Circuit
34
Figure 23:Hardware Circuit
35
4.2.
Discussions
This system uses a microcontroller-based relay to provide transformer protection. A transformer
current sensing circuit was developed, and the system's functionality was validated through
implementation. The proposed solution is cost-effective and compact in size. When the simulation is
run, the display first shows the message: "PROJECT WORK: REMOTE MONITORING OF
TRANSFORMER." After a few seconds, three key measurements—temperature, oil level, and load
current—are displayed, as shown in Fig. 13 (a) under normal operating conditions. In Fig. 16 (b), the
system detects a rise in temperature and displays the message "HIGH TEMPERATURE" on the LCD.
Similarly, when the oil level sensor detects that the oil level is below the predefined range, the system
displays "OIL LEVEL LOW," as shown in Fig. 18 (c). Conversely, if the oil level exceeds the predefined
range, the message "OIL TANK FULL" is displayed, as shown in Fig. 19 (d). This indicates an abnormal
condition in the transformer or the power line. Upon detecting the protection relay switches from
the Normally Closed (NC) to the Normally Open (NO) position, disconnecting the circuit to protect the
transformer. This system is designed to safeguard the transformer by monitoring and detecting all
critical parameters. However, since the system relies on a network connection, it is essential to ensure
that the system remains connected to the network and that no issues arise in the network component.
36
Chapter 5
Conclusions And Recommendations
5.1.
Conclusions
In comparison to manual monitoring, GSM-based distribution transformer monitoring is highly
beneficial. It is also dependable because it is not always possible to manually monitor temperature rise,
ambient temperature rise, load current, and voltage. We can act swiftly to stop any catastrophic
distribution transformer failures after obtaining notification of any anomaly. There are several
distribution transformers in a distribution network, and by connecting each transformer to a particular
system, we can quickly determine which transformer is having a problem from the message provided
to a mobile device. We can repair the system faster because we won't need to verify all of the
transformers and their accompanying phase currents and voltages. Message delivery times may vary
according to public GSM network traffic, but they are still faster than manual monitoring.
5.2.
Recommendation
For future development, it is recommended to transition from GSM to an Internet of Things (IoT) based
communication system. IoT, a cloud-based wireless technology, offers significant advantages in terms
of increased bandwidth, improved scalability for monitoring larger networks of transformers, and
enhanced integration with other smart grid technologies. This transition would not only make the
project more useful but also contribute to its economic viability. Enhancing system reliability and
redundancy should be a priority for future iterations. This includes exploring backup communication
pathways, such as combining cellular with satellite or mesh network technologies, to ensure
continuous monitoring even during primary network outages. Furthermore, developing advanced fault
detection and diagnostic algorithms is crucial. The current system's reliance on predefined thresholds
should be expanded upon by incorporating more sophisticated algorithms, potentially using machine
learning, to improve the accuracy and timeliness of fault detection and diagnosis. Finally, incorporating
predictive maintenance capabilities is recommended to further optimize maintenance practices. By
analyzing historical data and trends, the system could predict the remaining useful life of transformer
components and proactively schedule maintenance, thus minimizing downtime and maximizing
resource allocation.
37
References
1. Britannica. "Transformer | Definition, Types, & Facts." Britannica.
[Online]. Available: https://www.britannica.com/technology/transformer-electrical-device
2. T. A. E. (taebd.com). "Transformer, Device That Transfers Electric Energy from One Alternating
Current Circuit to One or More Other Circuits."
[Online]. Available: https://www.taebd.com
3. D. Transformer. "Ultimate Guide to Oil Filled Transformer."
[Online]. Available: https://www.dtransformer.com
4. E. I. G. (electrical-installation.org). "Protection of Transformer and Circuits."
[Online]. Available: https://www.electrical-installation.org
5. A. K. V. K. H. K. Vivek Landage. "Transformer Health Condition Monitoring Through GSM
Technology." International Journal of Scientific & Engineering Research, vol. 3, no. 12, pp. 1–5,
December 2012. ISSN: 2229-5518.
6. B. E. Ltd. "Seven of the Most Common Causes of Transformer Failure, and How to Reduce the
Likelihood of Failure." [Online]. Available: https://www.beltd.com
7. A. R. A. K. S. P. & B. K. Anurudh Kumar. "Method for Monitoring of Distribution
Transformer." Undergraduate Academic Research Journal (UARJ), vol. 1, no. 3–4, pp. 1–10,
2012. ISSN: 2278–1129.
8. Othman, A. M., & El-Sayed, H. (2021). Remote machine-to-human communication for fault
detection in distribution transformers. Proceedings of the 2021 International Conference on
Smart Grid and Renewable Energy, 45–52. https://doi.org/10.1016/j.epsr.2021.107230
9. Patel, R., & Nair, S. (2022). GSM-Based Real-Time Monitoring of Distribution Transformers
with Overload Protection. 2022 IEEE International Conference on Power Electronics and Smart
Grid Systems (PESGS), 112–117. https://doi.org/10.1109/PESGS54321.2022.123456
10. IEEE Standard C57.91-2011, IEEE Guide for Loading Mineral-Oil-Immersed Transformers and
Step-Voltage Regulators, 2012.
11. A. Kumar, S. Patel, and R. Sharma. "GSM-Based Remote Distribution Transformer Condition
Monitoring System." International Journal of Advanced Research in Electrical, Electronics, and
Instrumentation Engineering, vol. 5, no. 3, pp. 1234–1240, March 2016.
[Online]. Available: https://www.ijareeie.com
38
Appendix
Main code
#include <DHT11.h>
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
#include <SoftwareSerial.h>
#include "ACS712.h"
ACS712 sensor(ACS712_20A, A0);
DHT11 dht11(9);
//ACS712_5A for 5 Amp type
//ACS712_30A for 30 Amp type
#define SIM900A_RX 7
#define SIM900A_TX 8
SoftwareSerial sim900a(SIM900A_RX, SIM900A_TX);
//SoftwareSerial mySerial(8,9);
LiquidCrystal_I2C lcd(0x27, 16, 2);// Set the LCD address to 0x27 or 0x3f for a 16 chars and 2 line display
char msg;
char call;
int currentSensor = A0; //A0 pin as input from current sensor
int sensorPin = A1;
int volt = A2;
int vfactor = 5.128;
int relay1 =2;
int relay2 =3;
int trigPin = 4; //connect trigger pin of ultrasonic sensor to D4 of Arduino
int echoPin = 5; //connect echo pin of ultrasonic sensor to D5 of Arduino
float temperatureC;
39
long duration; // declare variables to hold duration and distance
int OilLevel;
float vout;
float rms = pow(2, 0.5);
float vdrop = 3.52;
float v;
// current sensor
float adcValue = 0; //value for adc conversion
int offsetVoltage = 2500; //offset voltage (mV) of the sensor
int sensitivity = 100; //mV/A for 30A sensor (from datasheet)
double currentRead = 0; //value that is calculated from adc value and sensitivity
double adcVoltage = 0; //voltage converted from adc value
double currentSum = 0; //adding up measurements to get average
double currentAve = 0; //average of 100 read measurements
//
String phoneNumber = "+251703166068";
int temperature;
void setup() //setup() is used for initialization
{
Serial.begin(9600);//set the baud rate of serial communication to 9600*/
sim900a.begin(9600);//initiallize the baud rate of GSM (SIM900A) communication to 9600*/
lcd.init(); // initiallize LCD
lcd.backlight();
lcd.clear();
lcd.setCursor(0,0);
lcd.print(" WELL COME TO ");
40
lcd.setCursor(0,1);
lcd.print(" FDRE TVTI ");
delay(3000);
lcd.clear();
lcd.setCursor(0,0);
lcd.print(" LOW VOLTAGE ");
lcd.setCursor(0,1);
lcd.print(" DISTRIBUTION");
lcd.setCursor(0,2);
lcd.print(" TRANSFORMER ");
lcd.setCursor(0,3);
delay(3000);
lcd.clear();
lcd.setCursor(0,0);
lcd.print(" MONITORING &");
lcd.setCursor(0,1);
lcd.print(" PROTECTION ");
delay(3000);
lcd.clear();
Serial.println(" ############################################################### ");
Serial.println(" WELCOME TO EETD ");
Serial.println("############################################################### ");
Serial.println(" ");
Serial.println("LOW VOLTAGE DISTRIBUTION TRANSFORMER MONITORING AND PROTECTION");
Serial.println(" ");
Serial.println(" ");
// ultrasonic sensor pin configuration
41
pinMode(trigPin,OUTPUT); //set trigPin as output pin of Arduino
pinMode(echoPin,INPUT); //set echoPin as output pin of Arduino
// current sensor pin configuration
pinMode(currentSensor, INPUT); //A0 pin as input
// relays confirutation
pinMode(relay1,OUTPUT);
pinMode(relay2,OUTPUT);
digitalWrite(relay1,HIGH);
digitalWrite(relay2,HIGH);
}
void loop()
{
// oil level measurement
digitalWrite(trigPin,LOW); //generate square wave at trigger pin
delayMicroseconds(2);
digitalWrite(trigPin,HIGH);
delayMicroseconds(10);
digitalWrite(trigPin,LOW);
duration=pulseIn(echoPin,HIGH);//calculation of OilLevel of obstacle
OilLevel=(duration*0.034/2);
// LCD display for oil level
Serial.print("Oil level : ");
Serial.print(OilLevel);
Serial.print(" cm ");
delay(1000);
//lcd.clear();
lcd.setCursor(0,0);
42
lcd.print("Oil level : ");
lcd.setCursor(11,0);
lcd.print(OilLevel);
//delay(1000);
// Load current measurement
currentSum=0; //reset the summing value of measurements
for (int i = 0; i<100; i++)
{ //loop to take 100 measurements and average the results
//adcValue = analogRead(currentSensor); //read the value from the sensor
//adcVoltage = (adcValue / 1024.0) * 5120; //converting the adc value to a voltage 5.12V measured on
power rails- //-of breadboard
currentRead = sensor.getCurrentAC(); //read AC current
currentSum = currentSum + currentRead; //adding the measurements together to be averaged
}
currentAve = currentSum*10; //averaging the measurements
if (currentAve < 6){
currentAve=0;
\}
//currentAve= currentAve - 8.50;
// LCD display for Load current
Serial.println(" ");
Serial.print("Load current: ");
Serial.print(currentAve); //Print the current with a title to the serial monitor
delay(200);
// Get the voltage reading from the LM35 temperature = dht11.readTemperature();
// Check the result of the reading.
// If there's no error, print the temperature value.
43
// If there's an error, print the appropriate error message.
if (temperature != DHT11::ERROR_CHECKSUM && temperature != DHT11::ERROR_TIMEOUT) {
Serial.print("Temperature: ");
Serial.print(temperature);
Serial.println(" °C");
} else {
// Print error message based on the error code.
Serial.println(DHT11::getErrorString(temperature));
}
Serial.println(" ");
Serial.print("Temperature: ");
Serial.print(temperature);
Serial.print("\xC2\xB0"); // shows degree symbol
Serial.print("C | ");
// Print the temperature in Fahrenheit
float temperatureF = (temperature * 9.0 / 5.0) + 32.0;
Serial.print(temperatureF);
Serial.print("\xC2\xB0"); // shows degree symbol
Serial.println("F");
// LCD display for temperature
lcd.setCursor(0,1);
lcd.print("Temperature: ");
lcd.print(temperature);
delay(300); // wai=t a second between readings
/*bool a = (/*(temperatureC <71)&&*//*(OilLevel >20)&&(currentAve<15));
if (a==true)
{
digitalWrite(relay1,HIGH);
44
digitalWrite(relay2,HIGH);
Serial.print(" Normal condition ");
}*/
//Voltage reading
float vn=0; //reset the summing value of measurements
for (int i = 0; i<100; i++)
{ //loop to take 100 measurements and average the results
float vreading = analogRead(volt);
float vac = (vreading * (5.0 / 1024.0)*vfactor+vdrop)/rms;
vn = vac + vn; //adding the measurements together to be averaged
}
vout = vn/100;
Serial.println(" ");
Serial.print("Voltage: ");
Serial.print(vout);
Serial.print("V");
condition();
delay(10000);
lcd.clear();
Serial.println(" ");
}
//CONDITIONS
// LCD PRINTING CONDITION//
/*void lcd_oilLevelFULLPrint()
{
lcd.clear();
45
lcd.setCursor(1,1);
lcd.clear(); //if condition temp for it to print.
lcd.print("OIL TANK FULL");
}*/
Call code
void MakeCall()
{
Serial.println("Calling "); // print response over serial port
Serial.print("CALLING NEAR BY SUB STATION .........");
Serial.println("");
lcd.clear();
//lcd.setCursor(0, 1);
lcd.print("CALLING NEAR BY");
lcd.setCursor(0, 1);
lcd.print("SUB STATION .........");
sim900a.print("ATD");
sim900a.print(phoneNumber);
sim900a.println(";"); // Semicolon is important for the call command
delay(500);
readSIM900AResponse();
delay(10000);
HangupCall();
}
void HangupCall()
{
Serial.println("Hangup Call");
46
sim900a.print("ATH\r\n"); // Hang up command
delay(500);
}
String readSIM900AResponse() {
String response = "";
while (sim900a.available()) {
char c = sim900a.read();
response += c;
}
Serial.print(response); // Print the raw response to the Serial Monitor for debugging
return response;
}
Condition code
void condition()
{
if (temperature > 40)
{
lcd_tempPrint();
digitalWrite(relay1,LOW);
digitalWrite(relay2,LOW);
MakeCall();
delay(2000);
SendMessage_temp();
delay(10000);
}
if (vout > 15)
47
{
lcd_voltPrint();
digitalWrite(relay1,LOW);
digitalWrite(relay2,LOW);
SendMessage_high_volt();
MakeCall();
delay(10000);
}
if (vout < 9)
{
lcd_voltPrint();
digitalWrite(relay1,LOW);
digitalWrite(relay2,LOW);
MakeCall();
delay(2000);
SendMessage_low_volt();
delay(10000);
}
/* if (OilLevel > 50)
{
lcd_oilLevelFULLPrint();
lcd.setCursor(0,0);
lcd.print("oil level >50");
lcd.setCursor(0, 1);
lcd.print("Sending SMS then calling");
delay(2000);
// MakeCall();
//sms1();
48
}*/
if (OilLevel > 20)
{
lcd_oilLevelLOWPrint();
digitalWrite(relay1,LOW);
digitalWrite(relay2,LOW);
MakeCall();
delay(2000);
SendMessage_oil();
delay(1000);
}
if (currentAve>1000)
{
lcd_currentPrint();
digitalWrite(relay1,LOW);
digitalWrite(relay2,LOW);
lcd.setCursor(0,2);
MakeCall();
delay(2000);
SendMessage_current();
delay(1000);
//lcd.clear();
}
delay(1000);
//lcd.clear();
}
49
LCD code
void lcd_oilLevelLOWPrint()
{
lcd.clear();
lcd.setCursor(0,1);
lcd.print(" LOW OIL LEVEL !!!");
lcd.setCursor(0,2);
lcd.print("OIL LEVEL : ");
lcd.setCursor(13,2);
lcd.print(OilLevel);
delay(10000);
lcd.clear();
}
void lcd_tempPrint()
{
lcd.clear();
lcd.setCursor(0,0);
lcd.print("HIGH TEMPERATURE !!!");
lcd.setCursor(0,1);
lcd.print("TEMPERATURE :");
lcd.setCursor(14,1);
lcd.print(temperatureC);
delay(10000);
lcd.clear();
}
void lcd_currentPrint()
{
lcd.clear();
50
lcd.setCursor(0,0);
lcd.print(" OVER CURRENT !!!");
lcd.setCursor(0,1);
lcd.print("Current : ");
lcd.setCursor(14,1);
lcd.print(currentAve);
delay(10000);
lcd.clear();
}
void lcd_voltPrint()
{
lcd.clear();
lcd.setCursor(0,0);
lcd.print(" Voltage Issue !!!");
lcd.setCursor(0,1);
lcd.print("Voltage : ");
lcd.setCursor(10,1);
lcd.print(vout);
delay(10000);
lcd.clear();
}
TEXT CODE
void SendMessage_current()
{
String message = "OVER CURRENT IS DETECTED";
sim900a.print("AT+CMGF=1\r"); // Set SMS text mode
delay(500); // Delay of 1000 milli seconds or 1 second
51
sim900a.print("AT+CMGS=\"");
sim900a.print(phoneNumber);
sim900a.println("\"");
delay(500);
readSerial();
Serial.print("Sending SMS to Nearby substation ........");
Serial.print("OVER CURRENT IS DETECTED !!!");
sim900a.println(message);
delay(500);
sim900a.println(currentAve);
delay(500);
readSerial();
sim900a.write(26); // ASCII code for Ctrl+Z (end of message)
delay(500);
readSerial();
}
void SendMessage_oil()
{
String message = "LOW OIL LEVEL IS DETECTED";
sim900a.print("AT+CMGF=1\r"); // Set SMS text mode
delay(500); // Delay of 1000 milli seconds or 1 second
sim900a.print("AT+CMGS=\"");
sim900a.print(phoneNumber);
sim900a.println("\"");
delay(500);
sim900a.println(message);
delay(500);
52
readSerial();
sim900a.write(26); // ASCII code for Ctrl+Z (end of message)
delay(500);
readSerial();
Serial.print("Sending SMS to Near by sub station ........");
Serial.print("LOW OIL LEVEL IS DETECTED !!!");
}
void SendMessage_low_volt()
{
String message = "LOW Voltage IS DETECTED";
sim900a.print("AT+CMGF=1\r"); // Set SMS text mode
delay(500); // Delay of 1000 milli seconds or 1 second
sim900a.print("AT+CMGS=\"");
sim900a.print(phoneNumber);
sim900a.println("\"");
delay(500);
sim900a.println(message);
delay(500);
sim900a.println(vout);
delay(500);
readSerial();
sim900a.write(26); // ASCII code for Ctrl+Z (end of message)
delay(500);
readSerial();
Serial.println("Sending SMS to Near by sub station ........");
Serial.println("LOW Voltage LEVEL IS DETECTED !!!");
}
void SendMessage_high_volt()
53
{
String message = "LOW High Voltage IS DETECTED";
sim900a.print("AT+CMGF=1\r"); // Set SMS text mode
delay(500); // Delay of 1000 milli seconds or 1 second
sim900a.print("AT+CMGS=\"");
sim900a.print(phoneNumber);
sim900a.println("\"");
delay(500);
sim900a.println(message);
delay(500);
sim900a.println(vout);
delay(500);
readSerial();
sim900a.write(26); // ASCII code for Ctrl+Z (end of message)
delay(500);
readSerial();
Serial.print("Sending SMS to Near by sub station ........");
Serial.print("High Voltage LEVEL IS DETECTED !!!");
}
void SendMessage_temp()
{
String message = "High Temperature IS DETECTED";
sim900a.print("AT+CMGF=1\r"); // Set SMS text mode
delay(500); // Delay of 1000 milli seconds or 1 second
sim900a.print("AT+CMGS=\"");
sim900a.print(phoneNumber);
sim900a.println("\"");
delay(500);
54
sim900a.println(message);
delay(500);
sim900a.println(temperature);
delay(500);
readSerial();
sim900a.write(26); // ASCII code for Ctrl+Z (end of message)
delay(500);
readSerial();
Serial.println("Sending SMS to Nearby substation ........");
Serial.print("HIGH TEMPERATURE IS DETECTED !!!");
}
void readSerial() {
while (sim900a.available()) {
Serial.write(sim900a.read());
}
while (Serial.available()) {
sim900a.write(Serial.read());
}
}
55
0
You can add this document to your study collection(s)
Sign in Available only to authorized usersYou can add this document to your saved list
Sign in Available only to authorized users(For complaints, use another form )