You are on page 1of 59

PROJECT REPORT

ON
PREPAID ENERGY METER
IN PARTIAL FULFILLMENT OF REQUIREMENT OF
DIPLOMA OF ELECTRICAL ENGINEERING
PREPARED BY:
PARMAR VAIBHAV M.

126500309537

PATEL SAVAN S.

126500309544

JADAV BHAVESH A.

126500309545

MODI DARSHAN M.

126500309552

PARMAR KISHAN B.

126500309558
GUIDED BY:

JIGNESH V. PATEL

Page | 1

YEAR-2014
SUBMITTED TO:
DEPARTMENT OF ELECTRICAL ENGINEERING
SWAMI SACHCHIDANAND POLYTECHNIC COLLEGE (SSPC-2nd Shift),
Visnagar-384351

CERTIFICATE
This is to certify that the following students of Swami Sachchidanand
Polytechnic College pursuing Diploma in Electrical Engineering in the semester
6th have satisfactorily completed their project work on INFRARED
SECURITY ALARM WITH TWO DIGIT ENTRY COUNTER within the
college premises in academic year 2014.

Project Entitled To

Enrolment No

PARMAR VAIBHAV M.

126500309537

PATEL SAVAN S.

126500309544

JADAV BHAVESH A.

126500309545

MODI DARSHAN M.

126500309552

PARMAR KISHAN B.

126500309558
Page | 2

Internal Project Guide :

Head of Department:

________________

__________________

ACKNOWLEDGEMENT

The completion of any project brings with it a sense of satisfaction, but it is never Complete
without thanking those people who made it possible and whose constant support has crowned
our efforts with success.
One cannot even imagine the power of the force that guides us all and neither can we succeed
without acknowledging it. Our deepest gratitude to almighty God for holding our hands and
guiding us thSsroughout our lives.
We would also like to express our gratitude to our staff of Electrical Engineering Department of
SSPC, Visnagar for encouraging and inspiring us to carry out the project during the lab hours.
We would also like to thank our guide, Mr. JIGNESH V. PATEL for his expert guidance,
encouragement and valuable suggestions at every step.
We would like to express our deeply thanks to the head of the department Mr. PRAKASH G.
PATEL (H.O.D.), Electrical Engineering Department, SSPC, Visnagar for their kind support
all the way.
We express our profound gratitude to Prof. M.R.PATEL, Principal for his outstanding
Cooperation to provide all the required facilities.
We are extremely happy to acknowledge and express our sincere gratitude to our parents for
their constant support and encouragement and last but not the least, friends and well-wishers
for their help and cooperation and solutions to problems during the Course of the project.

Page | 3

ABSTRACT

Every month we can see a person standing in front of our house from Electricity
board or water Board whose duty is to read the energy meter/water meter and handover
the bills (electric or water) to the owner of that house . This is nothing but meter reading.
According to that reading we have to pay the bills. The main drawback of this system is
that person has to go area by area and he has to read the meter of every house and
handover the bills. The Electricity board and Water authority has to give privileges for
these people to do their duty monthly. The thing is, Government will not appoint any
particular persons for this duty. The people working in these boards will go on a
particular day and do their duty leaving all their pending works. Due to this, their work
will be delayed and this is great loss for government. To overcome this drawback we
have come up with an idea and this idea will help the government and it will save the
time of the employees working in these boards.
The aim of the project is to automate the prepaid billing of energy meter and water
meter. In this project the front end is User friendly and the employees can work on this
software with minimum knowledge of Computers. Employees can read the meter by
sitting in the Office. For front end designing Java is used.

Page | 4

Prepaid
Energy Meter

Page | 5

CHAPTER
1.Introduction

INDEX
CONTENT

PAGE NO.

1.1
1.2
1.3
1.4
1.5

Introduction
List of Features
Proposed Existing System
Advantages
Scope of Project
1.5.1 Aims
1.5.2 Objective
1.6 Limitation of Project

2.

3.

System Design
2.1 System Analysis
2.2 Basic Block Diagram
2.3 Circuit Diagram

List of Components
3.1
List of Components
3.2
3.2.1
3.2.2
3.2.3
3.2.4
3.2.5
3.2.5.1
3.2.5.2
3.2.5.3
3.2.5.4
3.2.5.5
3.2.5.6
3.2.5.7
3.2.5.8

3.2.5

Details of Components
Resistor
Capacitor
Transistor
Diode
H/w Requirement
Microcontroller ATMEL89S52
Real Clock Time
EEPROM Memory
LCD
GSM Module
ULN2003
Relay
Keypad
S/w Requirement
Page | 6

4. Project Management
4.1
Include Project Plan
4.2 Project Scheduling
4.3 Milestone & Deliverables
5. Conclusion
6. Future Plans
7. Reffrences

Page | 7

LIST OF FIGURES

Page | 8

No.

Description

Page No.

Figure.1

Pin Diagram of EEPROM memory

23

Figure.2

Pin Diagram of LCD

24

Figure.3

LCD Module

26

Figure.4

Power Supply

27

Figure.5

Architecture of GSM network

27

Figure.6

Pin connection of ULN

31

Figure.7

Relay block Diagram

33

Figure.8

Case Diagram

38

Figure 9

Dataflow Diagram

39

Figure 10

Circuit Diagram

40

Page | 9

LIST OF SYMBOLS

No.

Description

Page No.

Symbol.1

Microcontroller 89s52

19

Symbol.2

LCD

25

Symbol.3

GSM Modem

30

Symbol 4

Relay

32

Page | 10

CHAPTER -1
INTRODUCTION

Page | 11

CHAPTER: 1 INTRODUCTION

1.1

Introduction:
The GSM technology is used so that the consumer would receive messages

about the consumption of power (in watts) and if it reaches the minimum amount,
it would automatically alert the consumer to recharge. This technology holds
good for all electricity distribution companies, private communities, IT parks and
self-containing housing projects. The implementation of this project will help in
better

energy management, conservation of energy and also in doing away with the

unnecessary hassles over incorrect billing. The automated billing system will keep
track of the real time consumption and will leave little scope for disagreement on
consumption and billing. Every month we can see a person standing in front of our house
from electricity board or water board duty is to read the energy meter/water meter and
handover the bills to the owner of that house. This is nothing but meter reading.
According to that reading we have to pay the bills. The main drawback of this system
is that person has to go area by area and he has to read the meter of every house and
handover the bills. So its very time consuming as well as we have to recruit employee for
this process.
In this old system is very time consuming and there is possibility for human
error in meter reading. So by kind of this innovation billing process will ways and less
time consuming as well as no human error reading possibility in meter reading. The
present invention relates to a card base electric energy meter. In this innovation reader
associate with software in embedded in to microcontroller for making system compact
and cost effective. The main object to provide a prepaid electrical energy meter with
smart card reading technology .Here consumer have to buy advance energy unit from
vendor or service provider The no of credit purchased is programmed on a card vending
machine locate at utility. So using this innovation user can use electricity through its
Page | 12

prepaid credit
This project is useful for billing purpose in Electricity board and in water
authority. Instead of going to every house & taking the readings, in this project by just
sending an SMS we can receive the readings of the house and we can recharge the
electric bill. This system uses Java Basics software, which is designed as the application
platform to send or receive SMS using the Modem, then process and stores the data. Java
software has two main functions 1) to interact with Modem and read the COM port
2) maintain the database.
In this project the micro controller & the GSM unit is interfaced with the Energy
meter/water meter of each house. Every house has a separate number, which is given by
the corresponding authority. The GSM unit is fixed in the energy meter/water meter. The
amount of consumption is stored in memory authority as SMS. Using this software we
can send the SMS through Modem to that particular number which is assigned by
these authorities and wait for the response. On other end the modem will receive the data
in the form of a command and informs the controller to do the readings. After the
readings the controller will send data to the modem. Modem, in turn sends data to the
other end. In the office the GSM unit will receive the data and the Java software will
calculate the total consumption. The number assigned by the authorities is Unique. Using
GSM we can get the response very fast due to which time is saved. After completion of
the pulse the power will cut again consumer wants to send an SMS for recharge. This is
due to reduce illegal power using without paying the money.

Page | 13

1.2 List Of Features


It can be used in Home and Industries.
Facilitate in improved cash flow management in energy utilities and can reduces
problem.
Automatic Meter Reading (AMR)
More easily enable new functionalities
Power factor detection
High accuracy over a wide current dynamic range

1.3 Proposed Existing System


In order to overcome the problems of the existing traditional meter reading
system, efforts are underway around the world to automate the meter reading systems
and to provide comprehensive information to the consumer for efficient use of utilities.
The other technique is secure and scalable automated reading system which uses the
existing local ISPs instead of requiring its own proprietary set communication
infrastructure. The gateway node basically consists of an embedded microprocessor
system, based on embedded Linux, and a modem.
The remote real time automatic reading system employs distributed structure based
on wireless sensor networks which consists of measure units, sensor nodes, data
collectors, server and wireless communication network.

1.4 Advantage:
It is highly accurate as the whole idea of reading the units and then billing manually or
any other means is eliminated.
Consumer cannot escape from paying the electricity bill and the state electricity board
gets free from debts.
On the consumer front, the tedious task of paying the bill and waiting anxiously for the
bill is eliminated.
Wastage of energy is diminished as now only the required energy will be consumed as
allotted.
The power grid can monitor the overall energy consumption and any tampering
attempts are actually of no use and can be detected if still prevalent.
Page | 14

1.5 Scope Of Projects


1.5.1. Aims
We choose this topic because we like the concept of the Project. It is easy and simple
to implement. It has very low cost. The Problem started easily solved by this project. The
aim of the project is to automate the prepaid billing of energy meter and water meter. In
this project the front end is User friendly and the employees can work on this software
with minimum knowledge of Computers. Employees can read the meter by sitting in the
Office.

1.5.2. Objectives
Programming of a remote modem with AT
commands.
Interfacing programming chip with energy
meter.
Sending message from the MODEM to remote phone
device.

1.6 Limitation Of Project


After consuming the whole account the electricity is directly cut off.

At a time there can be only one recharge. So applicable for Home and Industries
but not in LAN.
Need specialized person to Handle.

Page | 15

CHAPTER-2
SYSTEM DESIGN

Page | 16

CHAPTER:2 SYSTEM DESIGN


2.1 System Analysis
An Electric Heater of 1.2 kW rating was used as a load that draw currents of up to 5.5 A.
The supply voltage was between 210 V and 230 V. Energy measurement process is
described step by step. A wattmeter was used to measure the power consumed by the
load. Then energy consumption was measured after every 25 seconds using the obtained
power information from the load. The computed energy consumption is read from the
Liquid Crystal Display.
The results shown that expected energy output in kW-sec obtained from the load power,
1.2 kW and time and energy output from measurement that is displayed by LCD after
every 20 sec.
A certain amount of power is supplied to the load, this power is maintained over a certain
period of time and the energy consumption is calculated and finally displayed. The tests
were done over a 3 minute period, measurements were taken every 20 sec and a very high
accuracy level is observed particularly after longer periods of time.

Page | 17

2.2 Basic Block Diagram:

Page | 18

2.3 Circuit Diagram:

Page | 19

CHAPTER-3
LIST OF COMPONANTES

Page | 20

CHAPTER:3 LIST OF COMPONANTS


3.1 List of Components:
3.2 DETAILS OF COMPONENTS:3.2.1 Resistor
3.2.2 Capacitor
3.2.3 Transistor
3.2.4 Diode
3.2.6

H/w Requirement

Microcontroller ATMEL89S52
Real Clock Time
EEPROM Memory
LCD
GSM Module
ULN2003
Relay
Keypad
3.2.7 S/w Requirement

Page | 21

3.2 DETAILS OF COMPONENTS:3.2.1 RESISTOR

A resistor is an electrical component designed to have a specific resistance (or


opposition) to the flow of electrons, measured in ohms().
1 Ohm of resistance is defined as ... the resistance of a circuit in which a 1-amp
current flows when 1 volt is applied.

CONSTRUCTION
Almost all types of power resistors (1W) have a cylindrical high purity ceramic core, either
rod or tube. The core has a high thermal conductivity, is impervious to moisture penetration, is
chemically inert, and is capable of withstanding thermal shock. The resistive element is either a
carbon film, a homogeneous metal based film or a wound wire element around the ceramic
body.
The terminations are usually nickel-plated steel, or occasionally brass, force fitted to each
end of the cylindrical former in order to provide excellent electrical contact between the
resistive layer and the end-cap. Tinned connecting wires of electrolytic copper or copper-clad
iron are welded to the end-caps, thereby completing the terminations.
All fixed resistance resistor bodies are coated with a protective moisture-resistant,
Page | 22

high dielectric field strength, and some times conformal coating, such that the wire
terminations remain clear and clean.

A simple analogy with a hydraulic system. Notice that the flow of electricity resembles the
flow of water from a point of high potential energy (high voltage) to a point of low potential
energy (low voltage). In this simple analogy water is compared to electrical current, the voltage
Difference is compared to the head difference between two water reservoirs, and finally the
valve resisting the flow of water is compared to the resistor
Limiting the flow of current.
Ohm's law states that the current through a conductor between two points is directly
proportional to the potential difference or voltage across the two points, and inversely
proportional to the resistance between them.
The mathematical equation that describes this relationship is: I=V/R
Where,
I is the current through the conductor in unit of ampere,
V is the potential difference measured across the conductor in unit of volt, R is the resistance
of the conductor in unit of ohm.
In some cases, youll need a resistor of a value other than what you have available. Different
resistance values can be obtained by combining.

Page | 23

3.2.2 CAPACITOR

A capacitor (originally known as condenser) is a passive two-terminal electrical component


used to store energy in an electric field. The forms of practical capacitors vary widely, but all
contain at least two electrical conductors separated by a dielectric (insulator); for example, one
common construction consists of metal foils separated by a thin layer of insulating film.
Capacitors are widely used as parts of electrical circuits in many common electrical devices.
When there is a potential difference (voltage) across the conductors, a static electric
Field develops across the dielectric, causing positive charge to collect on one plate and
negative charge on the other plate.
Energy is stored in the electrostatic field. An ideal capacitor is characterized by a
single constant value, capacitance, measured in farads. This is the ratio of the electric
charge on each conductor to the potential difference between them.

TYPES OF CAPACITOR

Ceramic capacitor
Electrolytic capacitor
Tantalum capacitor
Silver Mica Capacitor
Polystyrene Film Capacitor
Polyester Film Capacitor
Metalized Polyester Film Capacitor
Polycarbonate capacitor
Polypropylene Capacitor
Page | 24

Glass capacitors

APPLICATION
Energy storage
A capacitor can store electric energy when disconnected from its charging circuit, so it can be
used like a temporary battery. Capacitors are commonly used in electronic devices to maintain
power supply while batteries are being changed. (This prevents loss of information in volatile
memory.)

Power and weapons


Groups of large, specially constructed, low-inductance high-voltage capacitors are used to
supply huge pulses of current for manypulsed power applications. These include electromagnetic
forming, Marx generators pulsed lasers. Large capacitor banks (reservoir) are used as energy
sources for the exploding bridgewire detonators or slapper detonators in nuclear weapons and other
specialty weapons. Experimentalwork is under way using banks of capacitors as power sources for
electromagnetic armour and electromagnetic railgun and coilguns.

CHARACTERISTIC OF CAPACITOR

Page | 25

3.2.3 TRANSISTOR

A transistor is a semiconductor device used to amplify and switch electronic signalsand


electrical power. It is composed of semiconductor material with at least three terminals for
connection to an external circuit.
A voltage or current applied to one pair of the transistor's terminals changes the current
flowing through another pair of terminals. Because the controlled (output) power can be higher
than the controlling (input) power, a transistor can amplify a signal. Today, some transistors are
packaged individually, but many more are found embedded in integrated circuits.
The essential usefulness of a transistor comes from its ability to use a small signal applied
between one pair of its terminals to control a much larger signal at another pair of terminals.
This property is called gain.
A transistor can control its output in proportion to the input signal; that is, it can act as an
amplifier. Alternatively, the transistor can be used to turn current on or off in a circuit as an
electrically controlled switch, where the amount of current is determined by other circuit
elements.
A small current at the base terminal (that is, flowing from the base to the emitter) can
control or switch a much larger current between the collector and emitter terminals. For a fieldeffect transistor, the terminals are labeled gate, source, and drain, and a voltage at the gate can
control a current between source and drain.

Page | 26

The image to the right represents a typical bipolar transistor in a circuit. Charge will flow
between emitter and collector terminals depending on the current in the base. Since internally
the base and emitter connections behave like a semiconductor diode, a voltage drop develops
between base and emitter while the base current exists.

NPN TRANSISTOR

The diagram shows a schematic representation of an NPN transistor connected to two


voltage sources. To make the transistor conduct appreciable current (on the order of 1mA) from
C to E, VBE must be above a minimum value sometimes referred to as the cutin voltage.
The cut-in voltage is usually about 650 mV for silicon BJTs at room temperature but can be
different depending on the type of transistor and its biasing. This applied voltage causes the
lower P-N junction to 'turn-on' allowing a flow of electrons from the emitter into the base. In
active mode, the electric field existing between base and collector (caused by VCE) will cause
the majority of these electrons to cross the upper P-N junction into the collector to form the
collector current IC.
The remainder of the electrons recombine with holes, the majority carriers in the base,
making a current through the base connection to form the base current, IB. As shown in the
diagram, the emitter current, IE, is the total transistor current, which is the sum of the other
terminal currents, (i.e., IE = IB + IC).
It should also be noted that the emitter current is related to exponentially. At room
temperature, an increase in by approximately 60 mV increases the emitter current by a factor of
10. Because the base current is approximately proportional to the collector and emitter currents,
they vary in the same way.
ADVANTAGES
Page | 27

No power consumption by a cathode heater.


Small size and minimal weight, allowing the development of miniaturized electronic
Devices.
Low operating voltages compatible with batteries of only a few cells.
Lower power dissipation and generally greater energy efficiency.
Higher reliability and greater physical ruggedness.
Extremely long life.

DISADVANTAGES

Silicon transistors can age and fail.


High-power, high-frequency operation, such as that used in over-the-air television
broadcasting, is better achieved in vacuum.
Solid-state devices are more vulnerable to Electrostatic discharge in handling and
operation.
solid-state devices have less mass to absorb the heat due to overloads, in proportion to
their rating.
Sensitivity to radiation and cosmic rays.

APLICATION
The BJT remains a device that excels in some applications, such as discrete circuit design,
due to the very wide selection of BJT types available, and because of its high trans conductance
and output resistance compared to MOSFETs.
The BJT is also the choice for demanding analog circuits, especially for very-high
frequency applications, such as radio-frequency circuits for wireless systems.
Bipolar transistors can be combined with MOSFETs in an integrated circuit by using a
BiCMOS process of wafer fabrication to create circuits that take advantage of the application
strengths of both types of transistor.

Page | 28

3.2.4

DIODE

In electronics, a diode is a two-terminal electronic component with an asymmetric transfer


characteristic, with low (ideally zero) resistance to current flow in one direction, and high
(ideally infinite) resistance in the other.
A semiconductor diode, the most common type today, is a crystalline piece of
semiconductor material with a pn junction connected to two electrical terminals. A vacuum
tube diode is a vacuum tube with two electrodes, a plate(anode) and heated cathode.
The most common function of a diode is to allow an electric current to pass in one direction
(called the diode's forward direction),while blocking current in the opposite direction (the
reverse direction).
Semiconductor diodes begin conducting electricity only if a certain threshold voltage or cutin voltage is present in the forward direction. The voltage drop across a forward biased diode
varies only a little with the current, and is a function of temperature; this effect can be used as a
temperature sensor or voltage reference.
These are exploited in special-purpose diodes that perform many different functions. For
example, diodes are used to regulate voltage (Zener diodes), to protect circuits from high
voltage surges (avalanche diodes), to electronically tune radio and TV receivers (varactor
diodes), to generate radio frequency oscillations (tunnel diodes, Gunn diodes, IMPATT diodes),
Page | 29

and to produce light (light emitting diodes). Tunnel diodes exhibit negative resistance, which
makes them useful in some types of circuits.

How Diodes work?


The diode operates when a voltage signal is applied across its terminals. The application of
a DC voltage to make the diode operate in a circuit is called as Biasing. As already mentioned
above the diode resembles to that of a one way switch so it can either be in a state of
conduction or in a state of non conduction. The ON state of a diode is achieved by Forward
biasing which means that positive or higher potential is applied to the anode and negative or
lower potential is applied at the cathode of the diode. In other words, the ON state of diode
has the applied current in the same direction of the arrow head. The OFF state of a diode is
achieved by Reverse biasing which means that positive or higher potential is applied to the
cathode and negative or lower potential is applied at the anode of the diode. In other words, the
OFF state of diode has the applied current in the opposite direction of the arrow head.
During ON state, the practical diode offers a resistance called as the Forward resistance.
The diode requires a forward bias voltage to switch to the ON condition which is called Cutin-voltage. The diode starts conducting in reverse biased mode when the reverse bias voltage
exceeds its limit which is called as the Breakdown voltage. The diode remains in OFF state
when no voltage is applied across it.
A simple p-n junction diode is fabricated by doping p and n type layers on a silicon or
germanium wafer. The germanium and silicon materials are preferred for diode fabrication
because:
They are available in high purity.
Slight doping like one atom per ten million atoms of a desired impurity can change the
conductivity to a considerable level.

CHARACTERISTIC OF DIODE

Page | 30

The characteristics of a diode closely match to that of a switch. An ideal switch when open
does not conduct current in either directions and in closed state conducts in both directions. The
characteristic of a diode is as shown in the figure below.
Ideally, in one direction that is indicated by the arrow head diode must behave short
circuited and in other one that opposite to that of the direction of arrow head must be open
circuited. By ideal characteristics, the diodes is designed to meet these features theoretically
but are not achieved practically. So the practical diode characteristics are only close to that of
the desired.

TYPE OF DIODES

`
PN Junction diode
Avalanche diode
Crystal Diode
Tunnel Diode
Gunn Diode
Light-Emitting Diode
Laser Diode
Thermal Diode
Photodiode
Pin Diode
Super Barrier Diode
Zener Diode

APLICATION

Rectification
Page | 31

Power supply filter


Signal rectifier
Diode gate
Diode clamps
Limiter
Other electronic circuit

Page | 32

Product Perspective
3.2.5 H/w Requirement

3.2.5.1 Microcontroller AT89S52


The AT89S52 is a low-power, high-performance CMOS 8-bit microcontroller with
8K bytes of in-system programmable Flash memory. The device is manufactured using
Atmels high-density nonvolatile memory technology and is compatible with the Industry-standard 80C51 instruction set and pin out. The on-chip Flash allows the program
memory to be reprogrammed in-system or by a conventional nonvolatile memory programmar. By combining a versatile 8-bit CPU with in-system programmable Flash on a
monolithic chip, the Atmel AT89S52 is a powerful microcontroller which provides a
highly-flexible and cost-effective solution to many embedded control applications.

AT89S52 provides the following standard features:

8K bytes of Flash,

256 bytes of RAM,


32 I/O lines,
Watchdog timer,
two data pointers,
three 16-bit timer/counters,
a six-vector two-level interrupt architecture,
a full duplex se real port,
on-chip oscillator, and
clock circuitry.
In addition, the AT89S52 is designed with static logic for operation down to zero
frequency and supports two software selectable power saving modes. The Idle Mode stops the
CPU while allowing the RAM, timer/counters, serial port, and interrupt system to continue
functioning. The Power-down mode saves the RAM con-tents but freezes the oscillator,
disabling all other chip functions until the next interrupt or hardware reset.
Page | 33

Symbol:1 Microcontroller 89s52

AT89S52 FEATURES:-

Compatible with MCS-51 Products


8K Bytes of In-System Programmable (ISP) Flash Memory
Endurance: 1,00,000 Write/Erase Cycles
4.0V to 5.5V Operating Range
Fully Static Operation: 0 Hz to 33 MHz
Three-level Program Memory Lock
256 x 8-bit Internal RAM
32 Programmable I/O Lines
Three 16-bit Timer/Counters
Eight Interrupt Sources
Full Duplex UART Serial Channel
Low-power Idle and Power-down Modes
Page | 34

3.2.5.2 Real Clock Time


It uses I2C protocol. This is used to maintain the current time in off line
processing. The DS1307 Serial Real-Time Clock is a low power; full binary-coded
decimal (BCD) clock/calendar plus 56 bytes of NV SRAM. Address and data are
transferred serially via a 2-wire, bi-directional bus. The clock/calendar provides seconds,
minutes, hours, day, date, month, and year information. The end of the month date is
automatically adjusted for months with fewer than 31 days, including corrections for leap
year. The clock operates in either the 24-hour or 12-hour format with AM/PM indicator.
The DS1307 has a built-in power sense circuit that detects power failures and
automatically switches to the battery supply.
Real-time clock (RTC) counts seconds, minutes, hours, date of the month, month,
and day of the week, and year with leap-year compensation valid up to 2100. Two-wire
serial interface Consumes less than 500nA in battery backup mode with oscillator
running.
Role of real clock time is used to get the real time and date.

Page | 35

3.2.5.3 EEPROM Memory


The 4K is internally organized with of 2 bytes each. Random word
Addressing Chip Number requires a 9-bit data word address.
Features: Low-Voltage and Standard-Voltage Operation

5.0 (VCC = 4.5V to 5.5V)


2.7 (VCC = 2.7V to 5.5V)
2.5 (VCC = 2.5V to 5.5V)
1.8 (VCC = 1.8V to 5.5V)

Internally Organized 128 x 8 (1K), 256 x 8 (2K), 512 x 8 (4K),

1024 x 8 (8K) or 2048 x 8 (16K)

2-Wire Serial Interface

Schmitt Trigger, Filtered Inputs for Noise Suppression

Bidirectional Data Transfer Protocol

100 kHz (1.8V, 2.5V, 2.7V) and 400 kHz (5V) Compatibility

Write Protect Pin for Hardware Data Protection

8-Byte Page (1K, 2K), 16-Byte Page (4K, 8K, 16K) Write Modes

Partial Page Writes Are Allowed

Self-Timed Write Cycle (10 ms max)

High Reliability

Endurance: 1 Million Write Cycles

Data Retention: 100 Years

ESD Protection: >3000V

Description:
The

AT24C04

provides

4096

bits

of

serial

electrically

erasable

and

programmable read only memory (EEPROM) organized as 512 words of 8 bits each. The
device is optimized for use in many industrial and commercial applications where low
power and low voltage operation are essential. The AT24C04 is available in space saving
Page | 36

8-pin PDIP, AT24C04 packages and is accessed via a 2-wire serial interface. In addition,
the family is available in 2.5V (2.5V to 5.5V) version.

Device Operation:CLOCK and DATA TRANSITIONS:


The SDA pin is normally pulled high with an external device. Data on the SDA pin may
change only during SCL low time periods. Data changes during SCL high periods will
indicate a start or stop condition as defined below.
START CONDITION:
A high-to-low transition of SDA with SCL high is a start condition which must precede
any other command.
STOP CONDITION:
A low-to-high transition of SDA with SCL high is a stop condition. After a read sequence,
the stop command will place the EEPROM in a standby power mode.
ACKNOWLEDGE:
All addresses and data words are serially transmitted to and from the EEPROM in 8-bit
words. The EEPROM sends a zero to acknowledge that it has received each word. This
happens during the ninth clock cycle.
STANDBY MODE:
The AT24C01A/02/04/08/16 features a low power standby mode which is enabled: (a)
upon power up and (b) after the receipt of the STOP bit and the completion of any internal
operations.
MEMORY RESET:
After an interruption in protocol, power loss or system reset, any 2-wire part can be reset
by following these steps:
1. Clock up to 9 cycles.
Page | 37

2. Look for SDA high in each cycle while SCL is high.


3. Create a start condition as SDA is high.

Page | 38

3.2.5.4 LCD
DESCRIPTION:
-

A 8051 (or derivate) is used to control the LCD. - Needs decoded LCD-READ en LCD-

WRITE signals, derived from controller signals AD00..AD07, A08..A15, /RD and /WR, to
map the LCD into the external DATA area.
-

Address line A00 is connected to the DEMULTIPLEXED controller signal AD00 and

controls which LCD register is accessed. - Data lines AD00..AD07 are directly connected to
controller signals AD00..AD07. - Control line 'BACKLIGHT' is used to switch the LEDbacklight on (logic 1) or off (logic 0) or could be controlled from a PWM output.

Pin Diagram of LCD

Page | 39

LCD

Page | 40

LCD Module

Power Supply
The microcontroller and other devices get power supply from AC to Dc
adapterthrough voltage regulator. The adapter output voltage will be 12V DC nonregulated. The 7805 voltage regulators are used to convert 12 V to 5VDC.

Power Supply

The adapter output voltage will be 12V DC non-regulated. The 7805/7812


voltage regulators are used to convert 12 V to 5V/12V DC.

Page | 41

3.2.5.5 GSM Module


Why cellular system is used?
The number of customers wants the phone at every place like in
car, in garden, during walk and everywhere.
At first the cellular service is very expensive and time consuming and
have very less numbers of channels, so the various development on cellular phones
done.
The development done three generation.

Architecture of GSM Network

Page | 42

GSM Network consists of three main parts:

Mobile Station (MS) - carried by the subscriber.


Base Station Subsystem (BSS) - controls radio link with mobile station.
Network & Switching Subsystem (NSS) - mobility management and switching of
calls between mobile users, and between mobile and fixed network users.

Mobile Station Consists of:

Mobile Equipment (ME) such as hand portable and vehicle mounted unit

Subscriber Identity Module (SIM), which contains the entire customer related
information (identification, secret key for authentication, etc.)

Base Station Subsystem Consists of:

Base Transceiver Station (BTS) defines a cell and is responsible for radio link
protocols with the Mobile Station

Base Station Controller (BSC) controls multiple BTSs and manages radio channel
setup, and handovers. The BSC is the connection between the Mobile Station and
Mobile Switching Center.

Network and Switching Subsystems Consists of: Mobile Switching Center (MSC) is the central component of the NSS.

Operates all

switching functions for the mobiles within its jurisdiction. Interface between mobile and other
(including fixed) network. Its functions:

Manages the location of mobiles


Switches calls
Manages Security features
Controls handover between BSCs
Resource management
Interworks with and manages network databases
Collects call billing data and sends to billing system
Collects traffic statistics for performance monitoring
Page | 43

Network Databases Home Location Register and Visitor Location Register


together with MSC provides the call routing and roaming capabilities of GSM.
Home Location Register (HLR) contains all the subscriber information for the
purposes of call control, and location determination. There is logically one HLR per
GSM network, although it may be implemented as a distributed database.

GSM Modem

Visitors Location Register (VLR) is only temporary storage while the particular
subscriber is located in the geographical area controlled by the MSC/VLR. Contains
only the necessary information provision of subscribed services.

Authentication Center (AuC) is a protected database that stores the security


information for each subscriber (a copy of the secret key stored in each SIM).

Equipment Identity Register (EIR) is a list of all valid mobile equipment on the
network.

Page | 44

3.2.5.6 ULN2003
DESCRIPTION:
The ULN2001A, ULN2002A, ULN2003 and ULN2004Aare high voltage, high current
Darlington arrays each containing seven open collector Darlington pairs with common
emitters. Each channel rated at 500mAand can withstand peak currents of 600mA.
Suppressiondiodesare included for inductive load driving and the inputs are pinned
opposite the outputs to simplify board layout.

Pin connection of ULN

Page | 45

3.2.5.7 Relay
What is a relay?
A relay is usually an electromechanical device that is actuated by an electrical current.
The current flowing in one circuit causes the opening or closing of another circuit. Relays are
like remote control switches and are used in many applications because of their relative
simplicity, long life, and proven high reliability. Relays are used in a wide variety of
applications throughout industry, such as in telephone exchanges, digital computers and
automation systems. Highly sophisticated relays are utilized to protect electric power systems
against trouble and power blackouts as well as to regulate and control the generation
and distribution of power.

Relay
How relays work?
All relays contain a sensing unit, the electric coil, which is powered by AC or DC
current. When the applied current or voltage exceeds a threshold value, the coil activates
the armature, which operates either to close the open contacts or to open the closed contacts.
When a power is supplied to the coil, it generates a magnetic force that actuates the switch
mechanism. The magnetic force is, in effect, relaying the action from one circuit to another.
The first circuit is called the control circuit; the second is called the load circuit.

Page | 46

Figure 7: Relay Block Diagram

There are three basic functions of a relay:


1) On/Off Control,
2) Limit Control and
3) Logic Operation.

Page | 47

3.2.5.8 Keypad
It is used to interact with micro controller through user.
Based on the application on embedded system has to provide with keypad to input data

and or command.
The all commands are given using the keypad like recharge amount and future

application.
At the lowest level, keyboards are organized in a matrix of a row and columns The
CPU accesses both rows and columns through ports; therefore, with two bit ports, an 4 X
4 matrix of keys can be connected to a microprocessor. When a key is pressed, a row
and a column make contact; otherwise, there is no connection between rows and
columns.
4X4 matrix connected to two ports. The rows are connected to an output port and
the columns are connected to an input port. If no key has been pressed, reading the input
port will yield 1S for all columns since they are all connected to high (Vcc). If all the
rows are grounded and a key is pressed, one of the columns will have 0 since the key
pressed provides the path to ground. It is the function of the microcontroller to scan the
keyboard continuously to detect and identify the key pressed.

Page | 48

3.2.6 S/w Requirement


All the software is written in c language using the instruction set of 8051.the sequential
flow of commands is as follows:
Initialize the mobile by sending the required AT commands trough the HyperTerminal
software.
Continuously loop in the program to check whether any new SMS is received.
Read in the SMS, store it in the memory and give command to delete the SMS
from the SMS memory in the mobile to keep index 1 for the next new SMS.
Check for the mobile number and the incoming SMS. if both are correct, display
the SMS and time of arrival on the LCD.
According to the SMS, the respective LEDs glow. If any error occurs in the
above procedure, display the error on the LCD and loop back.

In this s/w, we have written small subroutines, which make programming easy. Using
the look-up table, we have stored all the responses for AT commands. All the interrupts,
except those for serial communication, are masked.
AT COMMAND SET:Similar to the modems, GSM cell phones accept the at command set only. The European
telecommunications standard institute (ETSI) specifies this command set. According to the
guidelines, commands should being with the character string AT and end with<CR>.
The input of a command is acknowledged by the display OK or ERROR. A
command currently in process is interrupted by each additional character entered. This
means the next command should not be entered until we receive the acknowledgment.
Otherwise the current command will be interrupted.

Page | 49

The commands supported are listed below:


Mobile initialization commands
ATE0: deactivate command echo
ATE1: active command echo
ATQ: display acknowledgements
ATQ1: suppress acknowledgements

ATV0.: output acknowledgement as numbers


ATV1.: output acknowledgement as text
AT+CGMM: issue manufacturers ID code
AT+CGMM: issue model ID code
SMS related commands
AT+CMGF: SMS format
AT+CMGL: List SMS
AT+CMGR: read in an SMS
AT+CMGD: delete an SMS in the SMS memory

Page | 50

CHAPTER-4
PROJECT MANAGEMENT

Page | 51

CHAPTER: 4 PROJECT MANAGEMENT

4.1 Include Project plan


Since the project belonged to new application development category, I selected the
following tasks.
Domain understanding
Analysis of required system
Defining scope and objectives
Finding out the efforts and the time estimation
Preparing the schedule
Finding our resources requirement
Implementation
Testing
From the selection of above tasks, I can elaborate them into pictorial representation
so that I can understand the activities in more understandable manner along with their
respected time interval.

4.2 Project Existing System


Project scheduling is an activity that distributes estimated efforts across the plan duration by
allocating the effort of specific software engineering task
Proper scheduling required.
All tasks appear in work.
Efforts and timing are intelligently allocated to each task.
Interdependencies between tasks are properly indicated.

Page | 52

Resources are allocated for the work to be done.


Though there are many reasons for completion of project, following are the
prominent ones that are the roots of late completion.
Unrealistic deadline estimation under excitation of getting a project or under some
other pressure.
Changing user requirements that are not reflected in schedule changes.
Underestimate of the amount of efforts and the number of resources that will be
required to perform the task.
Conceptual change requirement during the course of the project.
An appropriate distribution of time.
Human and natural problems that were not predicted.
Failure in recognizing that project is lagging behind schedule.
To schedule our project, we followed basic principles of project scheduling.

4.3 Milestone & Deliverables

Page | 53

CHAPTER- 5
CONCLUSIONS

5
4

CHAPTER: 5 CONCLUSIONS

This proposed distribution system for theft detection using GSM based smart energy
meter presented in this paper fascinate many advance studies in computer technology and
communication technology. The meter reading job can be completed at the management
department of residence area by using this system. Meantime, the energy resources
Management divisions can monitor the utilization of power in order to advance the utility
of power. Once this proposed distribution system is applied in the real life, the
distribution losses in Pakistan can be decreased efficiently, and all possibilities of
electricity theft will be eliminated. So tampering for electricity theft is impossible. Due to
this distribution system, the congestion of the transformer is identified, eliminated, and
load management is done easily. By using different tariff rates for peak hours, we can
discourage the demand at peak hour

5
5

CHAPTER: 6
FUTURE PLANS

5
6

CHAPTER: 6 FUTURE PLANS

In this innovation we can add GPS system with this innovation so if any
problem from GPS we can see the location of the affected area for more accuracy. In this
system we have to go at service provider for refill energy amount but it can be possible.
For example, the GSM network is in place, and the region has already witnessed massive
adoption of mobile banking due to the lack of banks and ATMs. Such established
infrastructure could also be used for the prepaid metering payment. As a result, SMS
prepayment (and later NFC) via a Smartphone should be relevant for this region. Here we
can also thing about different payment options like Mobile phone: With the deployment
of mobility, mobile devices could also be used as a prepaid payment solution. Indeed,
solutions such as SMS for payment or even online mobile payment will allow the
consumer to receive a credit token to recharge the meter. And also smartcard, memory
card and token .Also we can use Barcodes: With the deployment of Pay point payment
solutions, barcodes could be used.

5
7

CHAPTER: 7
REFERENCES

5
8

CHAPTER: 7 REFERENCES
The 8051 micro controller and Embedded system
Mazadi
Embedded System
by Raj Kamal.
www.Projectguide.com

WWW.ENGINEERSGARAGE.COM

5
9

You might also like