Transformer Half Part
Transformer Half Part
Transformer Half Part
REPORT
ON
WIRELESS TRANSFORMER MONITORING & CONTROL USING
MICROCONTROLLER
SUBMITTED IN PARTIAL FULFILLMENT OF REQUIREMENT FOR
THE DEGREE OF
BACHELOR Of TECHNNOLOGY
IN
ELECTRICAL ENGINEERING
SUBMITTED BY
ROHIT KUMAR SRIVASTAV(1401020061)
PRASOON RAI (1401020048)
SHASHI SAURABH(1401020070)
PRAVEEN KUMAR RAWAT
(1401020050)
2
DECLARATION
We the students of B.TECH ELECTRICAL ENGINEERING hereby declare that the work
detail in the project entitled “WIRELESS TRANSFORMER MONITORING & CONTROL
USING MICROCONTROLLER” submitted to Department of Electrical Engineering, “United
College of Engineering and Research Naini Allahabad”, under the “DR. APJ ABDUL KALAM
TECHNICAL UNIVERSITY” for the award bachelor of technology degree is our original work,
we have neither plagiarized nor submitted of any other degree .in case this undertaking is found
incorrect, we accept that our degree may be unconditionally withdrawn.
DATE:
VENUE:
ALLAHABAD Rohit kumar srivastava(1401020061)
Prasoon Rai (1401020048)
Shashi Saurabh (1401020070)
Praveen kumar
Rawat(1401020050)
3
CERTIFICATE
Certified that work presented in this report entitled “Wireless Transformer Monitoring
And Control Using Microcontroller”for the award bachelor of technology from “DR.
APJ ABDUL KALAM TECHNICAL UNIVERSITY, LUCKNOW”, embodies results of
original work, and the studies are carried out by us and the content of the thesis do not
from the basis for award of any other degree to the candidate or to anybody else from
this or any other university/institutions.
Rohit kumar
srivastava(1401020061)
Prasoon Rai (1401020048)
Shashi Saurabh (1401020070)
Praveen
kumarRawat(1401020050)
4
ACKNOWLEDGMENT
We have taken efforts in this project. However, it would not have been possible without the
kind support and help of many individuals and organizations. I would like to extend my
sincere thanks to all of them.
We also take the opportunity to acknowledge the contribution of Mr. Swapnil Srivastava,
HEAD OF Department of mechanical engineering, United College of Engineering and
Research Naini Allahabad”.
I would like to express my gratitude towards my parents & classmates for their kind co-
operation and encouragement which help me in completion of this project.
My thanks and appreciations also go to those people who have willingly helped me out with
their abilities for developing the project.
Rohit Kumar
Srivastava Praveen
Kumar Rawat
Prasoon Rai
Shashi
Saurabh
(Department of Electrical
Engineering)
5
ABSTRACT
Distribution transformers are one of the most important equipment in power network. Because
of, the large number of transformers distributed over a wide area in power electric systems, the
data acquisition and condition monitoring is an important issue. The main aim of this system is
distribution transformer monitoring and controlling through IOT. Here transformers r damaged
due to the oil damage. Oil damage is depends on different parameters and environmental
conditions. Now in this system we are concentrating on temperature of transformer and viscosity
of oil .In this system temperature and viscosity monitoring.
Control action is performed based on the AVR microcontroller. After interfacing the required
components user has to develop one application program in embedded-c. Here we will control
the oil fill in the transformer, will able to on/off output load of transformer also it will display
frequency, voltage and temperature reading on the smart phone using IOT link to control the
whole system.
6
7
CHAPTER 1
INTRODUCTION
Protection against fault in power systems (PS) is very essential and vital for reliable
performance. A power system is said to be faulty when an undesirable condition occurs in that
power system, where the undesirable condition might be short circuits, overcurrent,
overvoltage etc.
The power transformer is one of the most significant equipment in the electric
power system, and transformer protection is an essential part of the general system
protection approach. Transformers are used in a wide variety of applications, from small
distribution transformers serving one or more users to very large units that are an integral
part of the bulk power system (Anderson, 1998, P.673).
8
remote protection of the transformer.
9
The purpose of power system protection is to detect faults or abnormal operating
conditions and to initiate corrective action. Relays must be able to evaluate a wide variety of
parameters to establish that corrective action is required. Obviously, a relay cannot prevent
the fault. Its primary purpose is to detect the fault and take the necessary action to minimize
the damage to the equipment or to the system. The most common parameters which reflect
the presence of a fault are the voltages and currents at the terminals of the protected apparatus
or at the appropriate zone boundaries (Grigsby, 2007).
Furthermore, for the past several years fuse, circuit breakers and electromechanical
relays were used for the protection of power systems. The traditional protective fuses and
electrometrical relays present several draw backs.
10
1.2 Problem statement
Whenever the winding temperature raises and exceeds transformer thermal limits,
the insulation will deteriorate and may fail prematurely. Continuous thermal overload (over
temperature) might weaken the insulation of a transformer and resulting in rapid transformer loss
of life.
Over excitation (an increase in system voltage), internal faults can lead to
deterioration, acceleration aging and fault trips in transformer protection function (Reza, 2003).
However engineers and scientist have worked out various ways in which the
transformer can be protected; one of such ways is by using a relay. Therefore in order to
11
protect the transformer using relay, a control system idea is developed through the use of
microcontroller, hence the name of the project.
Aim:
Objectives:
1. To design the temperature and voltage sensing circuits that will be interfaced to
the microcontroller for monitoring.
2. To develop an algorithm and codes to the microcontroller which will work for under over
current, over voltage, under voltage conditions and transmit the parameters to a personal
computer.
3. To analyze and validate the performance of this system using appropriate simulation
software.
12
Furthermore, the limitation of the entire project is divided into two. First part of
the project is to design and build the hardware of the entire system. Where a voltage
transformer of 230:160 VAC, current sensor, electromechanical relay, microcontroller,
LCD display, and finally a power supply that can generate 5VDC in order to activate the
relay circuit, the microcontroller and LCD. The second part is the development of a C
language program that will satisfy the protection of the transformer algorithm.
Finally, the highest priority is given to the software design and implementation
in order to develop a suitable algorithm that will promptly interact with the, microcontroller
and the personal computer.
Chapter 1- Gives the general information about the project. The project aims and objectives
as well the problem statement.
Chapter 2-This chapter comprises of the reviews on previous works done in the field of power
transformer protection techniques and how the knowledge gained from such reviews is
deployed to meet the goals of this project.
Chapter 3-This chapter focuses in the description of the system block diagram as well as the
explanations of such block diagram with some design calculation
Chapter 4- This chapter comprises of detailed information on circuit schematic, PCB design
13
and microcontroller source codes.
14
Chapter 5- This deals with all the hardware and software testing results with a detailed analysis
on each of them.
Chapter 6- This chapter concludes the entire work performed during the project and points
out some few recommendations on improving the performance, efficiency and reliability for
systems to be designed in the future.
15
CHAPTER 2
Enormous work has been done on protection of power transformers such as:
overload voltages, overcurrent and external short-circuit etc. Some of those researches
which had been conducted, their setbacks, ambiguities and merits are as discussed in the
subsequent paragraphs.
In 2003 Ali Reza Fereidunian proposed a design which was based on a digital
differential relays for transformer protection using Walsh series and least square
Estimators. The Two estimators were been developed using the Walsh series and least
square algorithms. The transformer internal fault (short circuit) protection function was the
functionality of the differential relay. The performance of the proposed relay was tested
for internal, external faults and inrush current of the transformer. In their project the digital
differential relaying scheme comprised of filter, pre-process, data acquisition system and
a decision maker. The protective relay performs the duty of making decision about the
faulted or non-faulted situations.
The transformer internal faults and the external faults situations were tested on the
designed differential relay, and the results of these test illustrates the efficiency of the system.
Also, it was seen that both estimation algorithms perform their job correctly, but the Walsh
series acts better than least squares algorithm estimation (Ali Reza et al., 2003).
Furthermore in 2007 S.M. Bashi et al, designed and built a microcontroller based
system for power transformer protection. The system includes facilities for
16
discrimination between internal fault current and magnetizing inrush current, differential
protection, over current protection has been included.
The performances of the proposed system have been examined and from the
experimental readings and observation, it was understood that the proposed system monitors
and controls the transformer when there is any fault ( Bashi et al 2007)
The performance of the proposed system had been examined with three various
types of loading which had been added to the transformer. From the experimental observations
it was understood that, the proposed system monitors and controls the transformer in an
efficient manner. Whenever an over current was sensed by the system while monitoring the
transformer, it directs the main station to shut down the transformer and thus it guards the unit
from any serious damages (Thiyagarajan et al 2010).
It was found that the proposed method gave a satisfactory accuracy and can be
useful in a development of a modern differential relay for transformer protection scheme
(Ngaopitakkul et al, 2006).
17
Larner et al presented a paper that attempts to review the concept of a fuse
application on high voltage Power transformers. The practical connecting of a power
transformer directly to a transmission line through fuse was discussed and was found that the
fuse presents several problems in the protection. One of the stated problem that a fuse is that
it cannot detect a fault current resulting from turn-to turn faults within the protected
transformer which can be well below the load current rating of the transformer (Larner et al
1959).
It was concluded that the PLCs gave the protection circuits more flexibility
and makes their integration with other protection and control circuits easier. And also
found that the differential protection using PLCs provided high sensitivity for internal
faults and high stability for external faults and magnetizing inrush currents (Mazouz et al
2010).
The radial basis function network (RBFN) based algorithm was designed and
trained, in order to estimate the winding hot-spot transformer temperature from
18
knowledge of the experimental top oil temperature, weather conditions and load current data
obtained from a laboratory prototype mineral-oil-immersed transformer.
Finally, the RBFN-based algorithm for the identification of the dynamic thermal
overload in power transformers have been developed and was found that the accuracy was
improved compared with the results obtained from the IEEE power system relay committee
(Vaccaro et al 2000).
From the above review, it is finally concluded that researches done on the
transformer protection have some weaknesses; therefore by using the proposed method, which
is by using microcontroller based approach, the protection will be enhanced to a better
protection because the application of microcontroller in protecting transformer against
overcurrent and over voltage is speedily growing.
From the reviewed journals, based on S.M. Bashi work, this project plan to design,
analyse and implement the hardware of the system. Correspondingly, it is understood that the
topic of research is an advanced area of power systems protection engineering which is
normally being explored by power engineers. The purpose of the system design is to solve
complex and eradicate the problems encountered using the local protection techniques such as
fuse, circuit breakers etc.
19
connected to electric bulbs which will serve as loads. The load current will be monitored by
connecting a current sensor in series between the load and the secondary side of the
transformer. The transformer voltage will be monitored through rectifying a step down 230-
12VAC transformer to a pure 5VDC and then feed to the microcontroller ADC pin for voltage
monitoring. The input of the step down transformer will be connected to autotransformer
and the output will be perfectly rectified to a pure 5VAC.
Whenever the input voltage is varied, the microcontroller shows the value of the
voltage on an LCD and also on the PC. As input voltage is varied above 230VAC, the
microcontroller detects an over voltage fault and it sends a trip signal to the voltage
protective relay for protecting the transformer and the load connected.
20
CHAPTER 3
SYSTEM
DESIGN
3.1 Overview
21
At the primary side of the 230:160VAC transformer, a step down 230-12VAC
transformer is rectified to a pure 5VDC and feed into the ADC pin of the microcontroller for
monitoring the voltage of the transformer.
The LCD is used to display the transformer voltage, current and temperature,
similarly the personal computer is used to display the transformer parameters for monitoring
purpose.
While monitoring the transformer parameters, whenever the load current exceeds
the transformer rated current, the microcontroller detects an overcurrent faults and it sends a
trip signal to the overcurrent relay, thereby protecting the transformer from blowing off.
22
3.2.1 Microcontroller
The ATmega32 microcontroller I/O pins are 40 in number, and most of them can be
used as I/O pins. The input/output pins serves the purpose of connecting the ADC chip,
LED, LCD display, alarm buzzer and in this case the port A, pin one, two and three were
used to take care of ADC input since we are using three different analogue signals one for
the voltage transformer other for the current transformer and finally for the temperature
sensor.
23
3.2.2 Current sensor
The protection of the transformer against over current is concerned with the
detection and measurement of fault, where the measurement can be dangerous and indeed
impossible to measure if the actual load and fault currents are very large. A professional
way of avoiding these difficulties is to use the current sensor. Therefore in the block
diagram, current transformer is used to measure the load current.
The current sensor ACS756 was used because the current sensor ICs provides
economical and precise solution for AC or DC current sensing in industrial, automotive,
commercial, and communication systems. The device package allows for implementation by
the customer. Typical applications include motor control, load detection and management,
power supplies and overcurrent fault protection. The current sensor is capable of
measuring up to 50A.The monitored current values are displayed on the LCD display and
as soon the voltage transformer is overloaded the current transformer sends the information
through the ADC and the microcontroller energizes the relay, thereby protecting the
transformer.
The output of the current sensor is fed to Micro-controller ADC unit for
taking the necessary action. The current flowing through the CT primary can be
24
measured, for this purpose, digital display is provided at the output of the Micro-
controller Chip. Figure 3.2 shows the circuit diagram of the current sensing circuit.
The transformer used has 120 turns of coil in the primary; therefore secondary
winding turn is calculated as shown below:
25
26
The above calculation shows that the transformer has a turn ratio of 120:80 =12:8
The over voltage and under voltage protection circuit is capable of measuring
and monitoring voltage from 200 to 250VAC. In this project the voltage can be increased or
decreased by using the autotransformer and the output of the voltage monitoring circuit
is fed to ADC converter, whenever the voltage is varied to 200VAC, the microcontroller
will detect under voltage fault and whenever the voltage is varied to 250VAC, the
microcontroller detects over voltage fault, consequently the microcontroller sends a trip
signal to the relay, and the relays cuts the primary of the transformer from the AC mains,
thereby protecting the transformer.
27
Figure 3.3 over voltage sensing circuit.
In Figure 3.3, a step down transformer of 230-12VAC was used and was
rectified to a pure dc using the capacitor and then adjusted to voltage within 5VAC using the
potentiometer in order to be fed the analogue signal into the ADC without burning the ADC
converter.
From equation 3, the VAC is the RMS transformer voltage and the 0.7V is the voltage drop
across the rectifier. As there are two diodes conducting for each half cycle, therefore there will
28
be two rectifier voltage drops.
29
3.2.5 Relay
The relay serves as the protective device of the entire system. The relay
receives trip signal from the microcontroller and thereby cutting the transformer primary
from the input ac source hence protecting the transformer
Microcontroller pins lack sufficient current to drive a relay. While the 6volts
relay’s coil needs around 12mA to be energized, the current is obtained by the V/R
expression. For example, if the coil is 6VDC and the coil resistance is 500Ω, a minimum of
12mA (6V/500Ω = 12mA) is need to energize the relay while the microcontroller’s pin can
provide a maximum of 1-2mA current, therefore a transistor was used as relay driver which
is placed between the microcontroller and the relay as shown in figure 3.4
30
Figure 3.4. 230VAC lamp switched ON using microcontroller based relay
The clock circuit is an important element that is required in the system board.
This is because the microcontroller works digitally based on generated clock. The rate of the
clock is determined by a crystal oscillator that is connected to the clock logic pins.
A high speed crystal of 16 MHz is used in this project in order to avoid any
delay in terms of relay tripping ON and OFF, and monitoring of the transformer parameters
through the ADC of the microcontroller. Because the monitoring of transformer
parameters and tripping off the relay has to be very fast to avoid failure of the entire protection
system. Figure 3.6 show the crystal inscribed into the microcontroller, with two 33 pF
capacitors used to filter out external noise from interfering with the crystal frequency
31
Figure 3.6 Crystal oscillator circuit inscribed in the controller
The power supply circuit design is one of the important parts of this project,
without a power supply the electronic devices such as microcontroller, relay, alarm, LCD
etc. display will not function. Similarly a wrong power supply design will lead to the
damaging of the electronic devices used in this project.
The main power supplies needed for this project is 5VDC in order to power on
the relay and other electronic devices such as microcontroller etc. The design is done
using a transformer, bridge rectifiers, filter capacitor and a voltage regulator. Figure 3.7
shows the sequential process of designing a constant DC power supply.
32
230 V, 50 Hz Transformer Bridge Filter Regulator
Ac 20:1 Rectifier LM78**
In Figure 3.7 the input voltage is obtained the main 230VAC outlet and then
connected to the transformer. A step down transformer is used in stepping the 230VAC to a
12VAC.The 12VAC serves as an input voltage to the bridge rectifier which is basically for
diodes connected where two diodes are in forward biased and the other two are in reversed
biased for each half cycles. The bridge rectifier is used in converting the 12VAC into a dc
voltage.
The filter capacitor serves as a smoother to smooth the dc voltage from the
bridge rectifier and the LM7805 is the voltage regulators which purposely stabilizes the
output voltages to 6VDC and 5VDC.
33
3.2.8 Temperature sensing unit
The LM35 was chosen to be the temperature sensing device in this project.
The LM35 series are precision integrated-circuit temperature sensors, whose output voltage
is linearly proportional to the Celsius (Centigrade) temperature. The LM35 thus has an
advantage over linear temperature sensors calibrated in degree Kelvin, as the user is not
required to subtract a large constant voltage from its output to obtain convenient Centigrade
scaling with a rated operating temperature range of over -55° to +150°C
34
resistors). Instead, they use the fact as temperature increases, the voltage across a diode
increases at a known rate.
The output voltage of the LM35 varies linearly with temperature. Therefore to
calculate the temperature, a general equation is shown below which is used to convert the
output voltage to temperature
35
3.2.9 Transmitter description
The transmitter section consists of the MAX232 IC and the Atmega32 TX pin.
The microcontroller is interfaced to the computer using MAX232 through RS232 serial
communication. RS232 (recommended standard 232) supports both synchronous and
asynchronous transmissions and its user data is send as a time of bits. MAX232 is an
integrated chip that converts convert Transistor–transistor logic (TTL) to RS232 and
RS232 to TTL voltage levels compatible with digital logic circuit such as the
microcontroller. The serial data sends from the microcontroller is then fed to the PC
through RS232 for monitoring purpose.
36
Rs232 line type and logic Rs232 voltage TTL voltage to/from MAX
level 232
Data transmission (Rx/Tx) 3V to +15V 0V
logic 0
Data transmission (Rx/Tx) -3V to 15V 5V
logic 1
Control-signal -3V to 15V 5V
(RTS/CTS/DTR) logic 0
Control-signal +3V to +15V 0V
(RTS/CTS/DTR) logic 1
Currently, most PC’s have a 9 pin connector on either the side or back of the
computer. From Table 3.3 it is seen that the PC can send data (bytes) to the transmit pin
(i.e. pin 2) and receive data (bytes) from the receive pin (i.e. pin 3. The Serial port (DB9)
rs232 (recommended Standard 232) is much more than just a connector to PC because it
37
converts data from parallel to serial and changes the electrical representation of the data.
38
If the connector on the PC has female pins, therefore the mating cable needs to have a male
pin connector to terminate in a DB9 connector and conversely. Data bits flow in parallel
from the PC because it uses many wires at the same time to transmit whereas serial flow in
a stream of bits from the serial connector because it transmit or receive over a single wire. The
serial port create such a flow by converting the parallel data to serial on the transmit pin (i.e.
pin 2) and conversely. The serial port has a built-in computer chip called USART used in
translating data between parallel and serial forms.
The software design plays a very important role in the working of the entire system;
the system will not operate without the software. An algorithm needs to be developed to
enable the AVR controllers read the input and respond accordingly. The programming
language selected for this project is the C program. The C program will enable communication
between the transformer, microcontroller and PC with other different interfaces in the system.
With the software programed into it, microcontrollers acts as brain of the whole transformer
protection and transmit its parameters for monitoring its conditions. It will send the
transformer information through PC via the RS232 serial port.
39
The flow chart diagram developed will give an initial description of the
system software. The programs are divided into two parts which are main program and
interrupt program. The microcontroller will always loop the main program until an
interrupt occurred. When the controller receives an interrupt flag, then it will jump to
interrupt the process.
40
The flowchart above shows the initial description of the system program code.
The first thing the program will do is to initialize and read the ADC and the USART pins,
then sends the transformer parameters which are fed to the ADC to the personal computer
system using the UART1_Write command, then to the LCD display. The microcontroller
ADC will continuously capturing the transformer parameters, as soon as the transformer
secondary current is greater than 1A, it sends a trip signal to the overcurrent relay, and it
cuts off the load that leads to the overcurrent, thereby protecting the transformer from
burning. Same process goes to the over voltage protection, it will check whether the
transformer input voltage is greater than 230Vac, if so, it sends a trip signal to overvoltage
relay, thereby protecting the transformer.
41
CHAPTER 4
The step down transformer used is a 230VAC to 12VAC transformer and is used for
the purpose of sensing the input voltage to the main transformer with a voltage rating of
230VAC to 160VAC. The step down transformer is been rectified and filtered to a pure
dc which goes directly to the microcontroller ADC for monitoring the input voltage. For the
purpose of current sensing, a current transformer was used for that purpose. It went
through rectification and filtering process then directly connected to the microcontroller
ADC for monitoring the load current.
The microcontrollers send the monitored parameters to LCD display and also
transmit them to a personal computer. The transmission to personal computer was made
possible by interfacing the microcontroller with the computer using MAX232 through
RS232 serial communication. RS232 (recommended standard 232) supports both
synchronous and asynchronous transmission and its user data is send as a time series of
bits.
While monitoring the parameters, whenever a fault occurs which might be high
voltage or over current, the microcontroller sends a trip signal to the relay and thereby
protecting the transformer from burning.
42
Figure 4.1 Complete schematic
43
4.2 PCB design
Earlier, testing on broad board was done and the working process of the circuit
was properly tested, problems were troubleshot and rectified. After the bread board
testing here comes the Printed Circuited Board design (PCB). Dip trace software was
used to place the components, which are joined together with multiple of tracks that gives out
the physical and electrical connections. This software was used due its neat layout and
accurate PCB layout is always the main priority section of the design
The PCB layout schematics were printed on a transparent paper, where the layouts
were printed with a laser printer. Pressing iron was used to iron the transparent paper on
the PCB board systematically for about 10 minutes. The copper clads were allowed to
cool off and the transparent paper was removed from the PCB board to expose the transferred
image. A permanent marker was used to replace the missing tracks before
44
etching. Etching chemical (HCL acid) was poured into a squared shaped container and the
PCB board was placed inside. After that the board was cleaned with Tina chemical in order to
remove the unwanted copper and makes the board ready for drilling.
4.2.2 Soldering
After the drilling process, there comes the soldering process. Soldering attentions need
to be taken into consideration when laying out the board. Hand soldering is the traditional
method basically used for prototypes and small production stuffs. Major impacts when laying
out the board include suitable access for the iron, and thermal relief for pads.
After soldering, finished PCB has to go through comprehensive checks for electrical
continuity test and shorts that might occur at time of soldering. This is achieved by using the
multimeter continuity check mode. It checks that the continuity of the tracks if matches each
other; if not a troubleshooting session has to take place in order to trace and rectify the problem.
Microcontroller acts as the brain of the entire system. It monitors the voltage, current
and temperature of the transformer, display the parameters on LCD and PC through RS232
serial port. Whenever a fault occurs, it automatically sends a trip signal to the relay and thereby
protecting the transformer from burning. An algorithm has been developed which makes the
microcontroller reads the input analogue signals and responds consequently. The algorithms
have been represented by the flowchart shown in chapter three, and now the flowcharts are been
interpreted into C language and complied using the MikroC PRO for AVR. Refer to appendix
for complete C program.
45
4.3.1.1 Brief description of the system main program
The main program is divided into multiple of parts, and the parts are the definition of
ports and pins, initialization of ADC, configuration of the serial communication protocol
ports and finally configuration of LCD display.
General purpose input/ output pins of the microcontroller can be said to be the
basic and commonly used peripherals in microcontrollers. They permit the Atmega16
microcontroller pins to be used as input or outputs based on the task at hand for monitoring
and controlling devices. To use a port or pin of a microcontroller as input, a data direction
register called DDR register is used to configure the port as input. To setup PORTB as input,
DDR register is set as DDRB=0X00. And to use the PORTB as output, DDR register setup
as DDRB=0XFF.
In this project PORT A is used for Analogue digital conversion, PORT C is used for
LCD interfacing, PORT D is used for relay control, LCD control pins and serial port.
#include <built_in.h>
#define LCD PORTC
sbit RS at PORTD4_bit;
sbit EN at PORTD6_bit;
sbit RW at PORTD5_bit;
sbit relay at PORTD2_bit;
sbit relay2 at PORTD3_bit;
unsigned int voltage,current,temp,current2,current1;
int decimal,integer;float analog;
46
The program begins by defining PORTC for LCD, PORTD.2 for voltage relay,
PORTD.3 for current relay, PORTD.4, PORTD.5 and PORTD.6 as RS, RW and EN pins for
LCD respectively. Defining the ports gives a clear understanding of the program flow.
The main program begins by configuring the LCD, ADC and the serial
communication port of the microcontroller.
void main() {
DDRB = 0xFF; // Set PORTB as output
DDRC = 0xFF; // Set PORTC as output
DDRD = 0xFF; // Set PORTC as output
lcd();
UART1_Init(9600);
com(0x01);
dat(0x80);
lcd_string("Transformer protect");
dat(0xc0);
lcd_string(" system by buga ");
delay_ms(1000);
com(0x01);
dat(0x80);
lcd_string("Aminu bugaje");
voltage=temp=current;
The main program is started by defining the flow of each port is the port used as an
output port or as an input port. When the port is loaded with 0xff, it signifies that the port
is used as an output port, similarly if the port is loaded with 0x00, this means the port is used
as input. As seen in figure 4.4, portd, portc and portb are defined as output because
the microcontroller gives out signals to the LCD, relays and the serial port. The program
continues with the initialization of the serial communication and setting the speed of the
47
communication (baud rate) as 9600bps.
48
Baud rate is the number of times a signal in a communication channel changes state
or varies. This project is designed to use 9600 baud rate which means that the channel can
change states up to 9600bps times per second.
49
50
while (1) {
delay_ms(1000);
temp=ADC_Read(0x00)/4;
voltage=ADC_Read(0x01)/4;
current = ADC_Read(0x02)/4; // get ADC value from 2nd channel
com(0xc0);
lcd_string("temp:");
ascii(temp*2);
com(0x94);
lcd_string("volts:");
ascii(voltage*2);
com(0xd4);
lcd_string("current:");
asciiii((current*0.392)*2);
if(temp>20)
{ com(0xcb);
lcd_string("over");
}
if(temp<20)
{com(0xcb);
lcd_string("norm");}
if(current>130)
{com(0xe2);
lcd_string("over--");
relay=0;}
if(current<130)
{com(0xe2);
lcd_string("norm--");
relay=1;
}
51
if(voltage>120)
{ com(0xa1);
lcd_string("over--");
relay2=0;
}
if((voltage<120)&&(voltage>=110))
{com(0xa1);
lcd_string("norm--");
relay2=1;
}
if(voltage<110)
{com(0xa1);
lcd_string("under--");
relay2=1;
}
The program also checks for the current and whenever it’s more than 1.1A, it displays
on the LCD and sends a trip signal to the relay and thereby protecting the transformer
from burning.
52
UART1_Write(temp);
UART1_Write(voltage);
UART1_Write(current);
After setting the baud rate as 9600bps, this means the speed at which the microcontroller
transmits each bit per second to the personal computer. The UART1_Write command is used
to transmit the temperature, voltage and current values to the personal computer as seen in figure
4.6
As seen in figure 4.11, the system prototype has been developed with all
the features of a microcontroller based transformer protection as named to be the project
title. The loads are connected to the transformer secondary, and a current sensor is
connected in series with load for real time current monitoring. Based on the real time
current monitored values, the microcontroller takes decision over the relay whether to cut
off or not. The step transformer connected to the input voltage is used for high voltage
monitoring, based on the monitored voltage values; the microcontroller takes decision
over the relay. The AVR microcontroller board contains all the sub circuits on-board
including the high voltage sensing circuit, the liquid crystal display (LCD) for monitored
values display, LED’s for indication, temperature sensor, relays for protection purposes
and finally the MAX 232 and RS232 for transmitting the transformer parameters to PC.
53
Figure 4.11 Project prototype
It can be seen from the prototype developed that all the features of a
microcontroller based transformer protection were provided and well defined. The input
AC voltage was given through the autotransformer, the loads were connected at the
output of the transformer and the transformer parameters are monitored in personal
computer. The AVR microcontroller has on it all the sub-circuits for the transformer
protection including the liquid crystal display (LCD) for voltage, current and temperature
display of the transformer, relay driving circuits, high voltage sensing circuits, current
sensor and the transmitter circuit for real time transmission of transformer information to
personal computer
Finally, the Proteus simulation software made it easy to test, and troubleshoot the
hardware and the program which saved much of the time and reduced cost of the project.
Therefore, it can be concluded that the hardware and software implementation were
positively achieved
54
CHAPTER 5
0 20 40 60
Time(mS)
55
proportional to the secondary current. If the load connected does not exceed the rated
56
current of the transformer which 1.2A, the relay continues to be on. But as soon as the load
current exceeds the transformer rated current, the microcontroller sends a trip signal to the
overcurrent relay and the relay goes off., thereby protecting the transformer from burning due
to overloading. When the overcurrent is rectified, the relay goes on and continues to allow
the flow of electric current through the load.
200
Normal voltage 230VAC Voltage rises to normal 230VAC
150
Voltage (AC)
Series1
50
relays is off,Voltage goes to zero
0
0 10 20 30 40 50
Time (mS)
57
detects normal voltage, it sends back a switch on signal to relay thereby allowing the flow of
electric current and voltage through the through transformer primary
58
CHAPTER 6
6.1 Conclusion
Moreover, through the transformer voltage analysis in figure 5.2, we can see that the
voltage of the transformer rises as the input voltage of the transformer is increased through
varying an autotransformer. Whenever the input voltage goes above the transformer rated
voltage (230VAC), the microcontroller detects an overvoltage and it sends a trip signal to
over voltage relay thereby protecting the transformer from burning.
The results indicate that the microcontroller based transformer protection achieves
numerous advantages over the existing systems in use: 1) fast response, 2) better isolation,
3) accurate detection of the fault.
Finally, the practical results matched with the simulation perfectly, therefore the
aim and objectives of the project were all achieved successfully and project is said to be
industrious and fully automated with no manual interface required.
59
6.2 Future Recommendations
Based on the work done in this project which protecting transformer using
microcontroller, some improvements need to be made in the future work. It was noticed
that use of current sensor prevent the protection from high performance application
because the current sensor needs some amount of time to sense the load current and
transfer the signal to the microcontroller ADC. Correspondingly, a current transformer can
be used instead of current sensor, switching semiconductor device such as thyristor can be
used instead of relay, highly advanced microcontroller such as 16bit PIC microcontroller
or a digital signal processor can be used for high speed analogue to digital (ADC)
conversion of the transformer voltage and current.
Reference Books
Badri ram and D N Vishwakarma (1995) power system protection and switch gear New
delhi: Tata Mc Graw hill.
Frank D. Petruzella (2010) Electric motors and control systems 1st ed. New york:
McGraw-Hill
60
J. Lewis Blackburn , Thomas J. Domin (2006). Protective Relaying Principles and
Applications . 3rd ed. United States of America: CRC press
Leonard L. Grigsby (2007). The Electric Power Engineering Handbook. 2nd ed. United
States of America: CRC press.
P. M. Anderson (1998). Power system protection. New York: John Wiley & Sons, Inc.
P.673.
Smarajit Ghosh, (2007). Electrric Machines 1st Edn. India: Dorling Kindersley
Journals
Pankaj Bhambri, Chandni Jindal, Sagar Bathla (2007), ‘Future Wireless Technology-
ZIGBEE’ Proceedings of national conference on challenges, pp. 154-156.
61
S.M Bashi, N. Mariun and A.rafa (2007). ‘Power Transformer protection using
microcontroller based relay’, Journal of applied science, 7(12), pp.1602-1607.
V.Galdi, L.lppolito, A.piccolo and A.Vaccaro (2000) ‘Neural diagnostic system for
transformer thermal overload protection’ Electric Power Applications, IEE Proceedings,
147 (5), pp. 415 - 421 .
V.Thiyagarajan & T.G. Palanivel, (J2010) ‘An efficient monitoring of substations using
microcontroller based monitoring system’ International Journal of Research and Reviews
in Applied Sciences, 4 (1), pp.63-68.
62