Radio
frequency identification systems use radio frequency to identify, locate and
track people, assets and animals. The usage of the devices are increasing and
also be used for secured door latches, attendance for time office application,
store stock applications etc. the application range is increasing day by day.
There are three general methods to identify and
track assets: paper and pencil or similar manual record keeping techniques; bar
code techniques using printed paper or plastic labels with laser readers and
computers for record keeping; and radio frequency identification techniques
(RFID) featuring radio transponders and interrogators for reading and computers
for record keeping. Manual methods were the first to be used, and
are still in use today. These labor-intensive operations gave rise to more
automatic methods, including the introduction of laser-read bar code methods.
With its superior accuracy and ease of use compared to manual methods, bar code
soon became the dominant method for asset identification, and is still in use
today. As the use of bar code grew, a significant characteristic began to limit
the applications: the label is read using a light beam.
Light
beams cannot read through dirt, or around corners or through walls, or at
distances significantly greater than six inches. Bar code was thus limited to
clean environments with a direct line of sight from the reader, and the reader
had to be close to the label. The development of radio frequency techniques
promised to overcome these limitations.
There
are two types of RFID technologies. Passive technology that does not require
batteries; and active technology that uses extremely long life batteries.
Passive RFID systems are composed of
three components, a reader also referred as interrogator, passive tag and host
computer. The host computer performs the front end Applications such as
attendance, or identity of the person etc. This is composed of an Antenna coil
and a silicon chip that includes logic modulation circuitry and non-volatile
Memory. The tag is energized or gets its power by a time varying
electromagnetic radio frequency (RF) wave that is transmitted by the reader.
This
RF signal is called a carrier signal. When the RF field passes through the
antenna coil, there is an AC voltage generated across the antenna coil. This
induced voltage is rectified and charges the capacitor, which in turn is used
for tag circuit operation. The tag device functions when the dc voltage reaches
a certain level. The information stored in the device earlier is transmitted
back to the reader. This signal, which is emanated from the tag and is received
by the reader, is normally referred as back-scattered signal. The reader
detects the back-scattered signal and reconstructs the information transmitted
by each tag. The information transmitted by each tag is independent from the
other end is unique, thus use of this code can be used to identify the tag.
Because of its simplicity for use
the passive RFID system has been used for many years in various RF remote
sensing application. In recent years, there have been drastic increase
application demands. In most cases, each application uses unique packing form
factor, communication protocol, frequency etc.
As the
passive RF tag does not contain any power source and as it is remotely powered
by reader’s RF signal, the tag pads range (communication distance between,
reader and tag) is typically within a proximity distance and also depends on
the carrier frequency used.
CHAPTER 2
BASIC BLOCK DIAGRAM OF THE SYSTEM
In
the system,13.56MHz passive tag reader
is used. The basic block diagram of the system is as given below:
The read range varies with design parameters such
as frequency, RF power transmitted (carrier frequency), readers receiving
sensitivity, size of the antenna, antenna radiation patterns, data rate,
communication protocol, power consumption of the tag, orientation with respect
to reader antenna etc.
The frequency ranges of these devices are
standardized by the regulation authorities; they are grouped as
Ø Low frequency bands (125 KHz-400 KHz).
Ø Medium
frequency bands (4-20 MHz)
Ø Microwave
frequencies (2.4GHz) etc.
In this
project, we developed a reader for the exciting 13.56MHz tags.
The
purposes of various blocks were as followed:-
2.1
READER:-
RFID reader is used to activate the
passive tag with RF energy and to extract the information from the tag, which
is previously stored. For this function, the reader includes RF (13.56MHz)
oscillator, receiving and antenna driving circuit, apart from receiving and
data decoding sections, the read data is checked for its integrating (error
checking)and once confirmed the data is transmitted in an RS-232 interface to
either a main micro controller or a host computer. The main micro controller or
the host computer has the main application related software. Depending on the
read range of the reader, the R.R carrier power is generated, and the
sensitivity of the decoder is increased.
The back-scattered received signal
is extracted and the dedicated micro controller circuit and the reader micro
controller algorithm is written in such it performs data decoding.
To transmit the RF signal, decode
the incoming data often suitable filtering, check for the integrity of the
received data and finally if the data is error free, the same data is sent to
the host computer or main micro controller though an RS-232 interface. Their
entire feature is developed around the reader micro controller.
The reader can be of two types:-
Ø Read only
device.
Ø Read /write
device.
2.2 Read/Write device:-
It is normally referred as
interface. For the read /write device to be used, the tag should have the
writing capability. All the tags do not has this facility. In this device the
interrogator also can modify the information stored in the tag.
Read only device:
It is also used as interface. Generally read
only device is not used.
2.3
Transmitting and Receiving Antenna:-
As the power radiated by the reader
antenna is of the order of several watts only, strip antennas are used. There
is normally a tuned circuit tuned to the radiating frequency i.e. 13.56 MHz in
this case. Thus, the antenna consists of an inductor, which is a strip loop
laid on the PCB in the form of a track
and a small tuning capacitor.
The
Back scattered signal is of different frequency and this signal can be tapped
across the capacitors, where the carrier frequency is radiating a constant
amplitude, this errors the capacitors. Wherever the back-scattered signal is
there, the antenna circuit is detuned, so the voltage across the capacitor
reduces. The back-scattered signal is just because of the tag.
2.4
Tag:-
An RFID tag is a microchip combined with an antenna
in a compact package; the packaging is structured to allow the RFID tag to be
attached to an object to be tracked.
The tag's antenna picks up signals from an RFID reader or scanner
and then returns the signal, usually with some additional data (like a unique
serial number or other customized information).
Tag consists of a silicon device and antenna
circuit. The purpose of the antenna circuit is to receive the energizing signal
that is radiated from the reader and to create a less scattered signal. The
read range of the tag largely depends upon the extreme circuit and size. The
extreme circuit of the tag is made of LC resonant circuit and the parameters
mainly depend on the carrier frequency. In the frequency range less than
100MHz, the communication between the reader and tag takes place with magnetic
coupling between the two extremes through the magnetic field. The extreme
utilizing the inductive coupling is often called magnetic dipole extreme. The extreme circuit must be designed such a
way to maximize the magnetic coupling between them.
This can be achieved by:-
Ø LC circuit
must be tuned to the carrier frequency of the reader.
Ø Maximize q of the tuned circuit.
Ø Maximize
extreme size and loops of the extreme with in the restrictions imposed by the
application of the reader.
Detail
description of Micro controller is given in third chapter
2.5 LCD
Module:-
This
module is used to have the manual interaction with the micro controller. This
is to display the name of the tag owner.
CHAPTER-3
READER AND
TAG SPECIFICATIONS
Reader SR90CM is a Mifare based Module with 5v or 12v power supply unit ,
compact and costeffective contactless reader and writer which supports ISO
14443 A and Mifare cards, operates by proximity to the card and causes no
friction, thus prolonging the life of the smart card. It has no moving parts,
thereby considerably reducing maintenance and recurring cost.
The RS232 serial interface can be connected to serial
port of embedded device, The reading and writing procedures and installation of
this card reader is very easy and convenient, accepts various commands from
demo software supplied to execute various MIFARE commands.
Technical
Specification
·
Read / Write Distance : Reading
range upto 50mm +
·
Communication Speed : 9600 & 115,200 kbps ( programmable )
·
Compatible : With ISO 14443 A and Mifare® Cards
·
Operating Frequency : 13.56 MHz
·
Interface : Serial RS232 interface / TCP/IP ( optional )
·
Operating Temperature range : 0ºC - 70ºC
·
Power LED : Red Operation LED
·
Buzzer : Green Activity Buzzer
·
Relay Ouput : Operates Door Locks @ 12 volts DC
·
Power supply : 5V DC 0.5amps
·
Physical Dimensions : Antenna = 89mm x 57mm, CPU = 73mm x 59.5mm
·
Unit Weight : 50 grams ( Without Cable )
TAGS:
INTRODUCTION;
Tag consists
of the silicon device and antenna circuit. The purpose of the antenna circuit
is to receive electrical energy from the reader through carrier frequency and
to send a modulated RF signal. The antenna circuit of the tag is made of LC
resonant circuit, for the frequencies of less than 100MHz.
The communication between the reader
and tag takes place with magnetic coupling between the two antennas through the
magnetic field. Different standard size tags are available. Thus, with each
standard size of the tag , with the same radiating power from the reader
antenna, the small size tags will have less reading range.
The tags
are of different types
- Based on power source
Ø Active tags
Ø Passive
tags
- Based on memory
Ø Read only
tags
Ø Read/write
tags
4.1 ACTIVE
TAGS:
An RFID tag
is an active tag when it is equipped with a battery that can be used as a
partial or complete source of power for the tag's circuitry and antenna. Some
active tags contain replaceable batteries for years of use; others are sealed
units.
The major advantages of an active RFID tag are:
- It can be read at distances of one hundred feet or more, greatly
improving the utility of the device
- It may have other sensors that can use electricity for power.
The
disadvantages of an active tag are:
- The tag cannot function without battery power, which limits the
lifetime of the tag.
- The tag is typically more expensive, often costing $20 or more
each
- The tag is physically larger, which may limit applications
4.2
PASSIVE TAGS:
A passive
tag is an RFID tag that
does not contain a battery; the power is supplied by the reader. When radio
waves from the reader are encountered by a passive RFID tag, the coiled antenna
within the tag forms a magnetic field. The tag draws power from it, energizing
the circuits in the tag. The tag then sends the information encoded in the
tag's memory.
The major disadvantages of a passive RFID tag are:
- The tag can be read only at very short distances, typically a few
feet at most. This greatly limits the device for certain applications.
- It may not be possible to include sensors that can use electricity
for power.
- The tag remains readable for a very long time, even after the
product to which the tag is attached has been sold and is no longer being
tracked.
The
advantages of a passive tag are:
- The tag functions without a battery; these tags have a useful life
of twenty years or more.
- The tag is typically much less expensive to manufacture
- The tag is much smaller (some tags are the size of a grain of
rice). These tags have almost unlimited applications in consumer goods and
other areas.
4.3
READ-ONLY DEVICE:
For the read only device, the
information that is in the memory cannot be changed by RF command once it has
been written.
Read only devices are
programmed as follows:
Ø In the
factory as a part of manufacturing process
Ø Contact
less by programmed one time after the manufacturing, it cannot be altered
afterwards or can be programmed and also reprogrammed in contact mode
4.4
READ/WRITE DEVICE:
A device with memory calls that
can be reprogrammed by RF commands is called read/write device. The information
in the memory can be reprogrammed by interrogatory command. Memory in today’s
RFID device is made of a C-MOS or B, FRAM array. EEPROM is based on C-MOS silicon. FRAM is based on Ferro electric memory.
EEPROM can produce relatively at lower cost than the FRAM device, because of
matured production technology. FRAM used RFID device consumes less power, which
is a desirable feature or the tag.
The C-MOS memory cell needs higher
voltage for writing than reading. In the passive (RF power is used to actuate
the device) read or write device, the programming voltage is generated by
multiplying rectified voltage. The voltage multiplier circuit is often called a
charge pumped. In addition to the programming voltage, the read/write device
needs command decoder and other controller logics. Because of all these, the
read/write device needs more circuit building blocks than that of the read only
device. Therefore, the device size is larger and costs more than a read only
device.
The FRAM device needs the same voltage
for reading and writing. The manufacturing cost is much higher than C-MOS
technology.
Read range of RFID devices:
Read ranges is defined as a
maximum communication distance between the reader and the tag. In general, the
read range of passive RFID a product varies, depending on system configuration
and is affected by the following parameters.
Ø
Operating
frequency and performance of antenna coils.
Ø
Antenna
orientation.
Ø
Excitation
current.
Ø
Sensitivity
of receiver.
Ø
Coding
(modulation) and decoding (demodulation) algorithm.
Ø
Number
of data bits and detection (interpretation) algorithm.
Ø
Condition
of operating environment (electrical noise, reflection characteristics of Background
etc.,)
The read
range of 13.5 MHz. is relatively longer than that of 125 KHz. devices. This is
because the antenna efficiency increases as the frequency increases.
Assuming the device is operating under
a given condition, the read ranges of the device is largely affected by the
performance of the antenna coil. It is always true that a longer read range is
expected with the longer size of the antenna with a proper antenna design.
Thus with different types of
communication protocols, the number of its stored, antenna size frequency of
oscillation etc., are largely varied from one tag to the other from the same
manufacturer also. Thus tags are mainly classified based on frequency and then
readable or read/write and the other specification such as the number of bits
stored etc., It is out of scope of this project to refer the entire range. The
project was done around an IC MCRF355. This IC is kept on the tag. The IC
itself is available in different forms such as PDIP, SOIC, die in waffle peck
etc. The tag selected has saved wafer on frame for its extremely small
thickness.
About
Mifare Card:
The Mifare architecture platform,
developed and successfully established by Philips Semiconductors, has achieved
its worldwide success through its proven reliability. With over a billion card
transactions effected so far and used in an estimated 90% of all contactless
card-operating schemes worldwide, Mifare sets the industrial standard for
contactless smart cards.
Mifare, which complies with the emerging
ISO/IEC 14443 standard for
contactless
integrated circuit cards, speeds up by losing contact. Not only in
transport
applications such as mass transit, electronic toll collection or airline
ticketing,
but also in city cards, ID cards, phone cards, access control and other
applications.
The memory
organization of the Mifare smart card is as:
• 8 KBit
EEPROM memory, no battery.
• Organized
in securely separated 16 sectors supporting multi-application use.
• Each
Sector consists of 4 blocks.
• Each Bblock
is the smallest part to be addressed and consists of 16 bytes.
• Each
Sector has its own secret file for a set keys for systems using key
hierarchies.
• Access to
memory zones is flexible, user definable by a variety of access conditions.
•
Arithmetic capability: increase and decrease.
• Data
retention of 10 years.
• Write
endurance 1,00,000 cycles.
Mifare
Features:
• ISO
operating frequency of 13.56 MHz.
•
Multiapplication memory.
• Fast
transaction speed.
• High
security.
• Operating
distance of from 50 mm to 75 mm.
• High
reliability.
• High data
integrity ensured by 16-bit CRC, parity bit coding and bit counting.
• ISO
credit card size.
• No
battery in the card.
Memory Organization:
The Mifare
card memory is organized as 8192 Bit EEPROM, which is split into 16 sectors
with 4 blocks. One block consists of 16 bytes (1 Byte = 8 Bit)
Manufacturer
Code (Block 00 of Sector 0):
The first
block of the memory is reserved for manufacturer data like 32 bit serial
number.
This is a
read only block. It is named as “Block 0”.
Data
Block (Block 0 to 3 except “Block 0”):
Access
conditions for the Data Blocks are defined in the Sector Trailers.
According
to these conditions data can be read, written, incremented,
decremented,
transferred or restored either with Key A, Key B or never.
The Mifare
card consists of two types of Data Blocks:
·
Read/write
blocks:
These
blocks are used to read and write general 16 bytes of data.
·
Value
blocks:
These
blocks are used for electronic purse functions like read, increment,
decrement,
transfer and restore. The maximum size of a value is 4 byte
including
sign bit, even when a complete 16 byte block has to be reserved.
To provide
error detection and correction capability, any value is stored 3
times into
one value block. The remaining 4 bytes are reserved to some
extent for
check bits.
.
READER
PROTOCOL:
1)
Request:
rX
X: Mode of
Request
0 – Request
All
1 – Request
Idle
This will
issue the Request command to the Mifare Reader. The return
value from
the reader is used to verify the status of the command
execution.
e.g. r0 or
r1
Return
value-command response
‘0’ -
Command successful.
‘1’ - Card
not found error.
‘2’ - Crc
error.
‘3’ -
Parity error.
‘4’ -
Overflow error.
‘5’ -
Framing error.
‘6’ -
Access timeout error.
‘7’ -
Collision error.
‘8’ - Not
yet implemented error.
‘9’ - Bit
count error.
2) Anticollision:
a
This will
issue the Anticollision command to the Mifare Reader. The
return
value from the reader is used to verify the status of the
command
execution. The return value includes the Mifare card ID.
e.g. a
Return
value-command response + Mifare card ID (4 digits)
‘0’ -
Command successful.
‘1’ - Card
not found error.
‘2’ - Crc
error.
‘3’ -
Parity error.
‘4’ -
Overflow error.
‘5’ -
Framing error.
‘6’ -
Access timeout error.
‘7’ -
Collision error.
‘8’ - Not
yet implemented error.
‘9’ - Bit
count error.
3) Select:
s
This will issue the Select command to
the Mifare Reader. The return
value from the reader is used to
verify the status of the command
execution.
e.g. s
Return value-command response
‘0’ - Command successful.
‘1’ - Card not found error.
‘2’ - Crc error.
‘3’ - Parity error.
‘4’ - Overflow error.
‘5’ - Framing error.
‘6’ - Access timeout error.
‘7’ - Collision error.
‘8’ - Not yet implemented error.
‘9’ - Bit count error.
‘a’ - Serial no error.
4) Load Keyset:
L0sskkkkkkkkkkkk
0: ‘0’
ss: Two digits Sector no.
kkkkkkkkkkkk: Key A or Key B (12
characters).
This command will load the specified
key A or key B for the given
sector to the Mifare reader. The
return value from the reader is used to
verify the status of the command
execution. The successful execution
of this command is necessary for
proper authentication of the selected
sector.
e.g. L010A0A1A2A3A4A5
This command will load the Key A –
A0A1A2A3A4A5 for sector
no 10.
Return value-command response
‘0’ - Command successful.
‘1’ - Load keyset failed.
5) Authentication:
A0ssbb
0: ‘0’
ss: Two digits Sector no.
bb: Two digits Block no corresponding
to the sector.
This will issue the Authentication
command to the Mifare Reader. The
return value from the reader is used
to verify the status of the
command execution. Successful
completion of this command will
‘authenticate’ the user to perform
various read/write and value related
commands to that sector of the Mifare
card. Failure to execute this
command will prevent the Mifare
reader to execute any further
read/write and value related Mifare
commands.
e.g. A00105
This command will authenticate the
user to carry any read/write
and value related operations on block
5 of sector 1.
Return value-command response
‘0’ - Command successful.
‘1’ - Card not found error.
‘2’ - Crc error.
‘3’ - Parity error.
‘4’ - Overflow error.
‘5’ - Framing error.
‘6’ - Access timeout error.
‘7’ - Collision error.
‘8’ - Not yet implemented error.
‘9’ - Bit count error.
‘b’ - Key error.
‘c’ - Authentication error.
6) Read:
R00ssbb
0: Mode Selection - ‘0 or 1’
0: ‘0’
ss: Two digits Sector no.
bb: Two digits Block no corresponding
to the sector.
This will issue the Read command to
the Mifare Reader. The return
value from the reader is used to
verify the status of the command
execution. This command will read the
data from the given block of the
given sector. The return value from
the reader contains the requested
block data.
e.g. R000105
This command will read the data from
block 5 of sector 1 of the
Mifare card.
Return value-command response +
Mifare card ID (4 digits) + Block
data (16 characters)
‘0’ - Command successful.
‘1’ - Card not found error.
‘2’ - Crc error.
‘3’ - Parity error.
‘4’ - Overflow error.
‘5’ - Framing error.
‘6’ - Access timeout error.
‘7’ - Collision error.
‘8’ - Not yet implemented error.
‘d’ - Card not authenticated.
‘e’ - Byte count error.
‘f’ - Code error.
7) Write:
W00ssbbdddddddddddddddd
0: Mode Selection - ‘0 or 1’
0: ‘0’
ss: Two digits Sector no.
bb: Two digits Block no corresponding
to the sector.
dddddddddddddddd: Text data (Max. 16
characters).
This will issue the Write command to
the Mifare Reader. The return
value from the reader is used to
verify the status of the command
execution. This command will write
the given text data to the given
block of the given sector.
e.g. W000105PARAMOUNTTECHNOL
This command will write the data – “PARAMOUNT TECHNOLOGIES”, to the
block 5 of sector 1 of the Mifare
card.
Return value-command response +
Mifare card ID (4 digits)
‘0’ - Command successful.
‘1’ - Card not found error.
‘2’ - Crc error.
‘3’ - Parity error.
‘4’ - Overflow error.
‘5’ - Framing error.
‘6’ - Access timeout error.
‘7’ - Collision error.
‘8’ - Not yet implemented error.
‘9’ - Bit count error.
‘d’ - Card not authenticated.
‘g’ - Write error.
‘f’ - Code error.
Note: Special care has to be taken in the case of writing to sector
trailers on the card. Those blocks
hold key data and access permission
data. Cards should be in a secure
state, that means statically in low
distance from the reader when performing
the sector trailer commands.
Thus, when programming the Sector
Trailer and other blocks the card
needs to be fixed within the
operating range of the reader to prevent
interruption of the write operation
because any unsuccessful write
operation may lead to blocking the
whole sector.
8) Halt:
h
This will issue the Halt command to
the Mifare Reader. The return
value from the reader is used to
verify the status of the command
execution. This command will ‘halt’
the Mifare card from processing
further Mifare commands.
e.g. h
This command will halt the selected
Mifare card and stop the
further command execution on that
card till next reset.
Return value-command response
‘0’ - Command successful.
‘1’ - Card not found error.
‘2’ - Crc error.
‘3’ - Parity error.
‘4’ - Overflow error.
‘5’ - Framing error.
‘6’ - Access timeout error.
‘7’ - Collision error.
‘8’ - Not yet implemented error.
9) Increment & transfer:
Ivvvvvvvvv
vvvvvvvvv: Increment step value (9
digits).
This will issue the Increment and
Transfer command to the Mifare
Reader. The return value from the
reader is used to verify the status of
the command execution. This command
will increment the block value
by the given increment step and
transfers this incremented value to the
same block. The block data to be
incremented must be in the proper
value format for successful execution
of this command.
e.g. I000000010
This command will increment the
contents of the corresponding
block authenticated in the
‘Authenticate’ command by 10(ten)
and transfer the incremented data to
the same block.
Return value-command response
‘0’ - Command successful.
‘1’ - Card not found error.
‘8’ - Not yet implemented error.
‘9’ - Bit count error.
‘d’ - Card not authenticated.
‘g’ - Code error.
‘h’ - Value format error.
10) Decrement & transfer:
Dvvvvvvvvv
vvvvvvvvv: Decrement step value (9
digits).
This will issue the Decrement and
Transfer command to the Mifare
Reader. The return value from the
reader is used to verify the status of
the command execution. This command
will decrement the block value
by the given decrement step and
transfers this decremented value to
the same block. The block data to be
decremented must be in the
proper value format for successful
execution of this command.
e.g. D000000010
This command will decrement the
contents of the corresponding
block authenticated in the
‘Authenticate’ command by 10(ten)
and transfer the decremented data to
the same block.
Return value-command response
‘0’ - Command successful.
‘1’ - Card not found error.
‘8’ - Not yet implemented error.
‘9’ - Bit count error.
‘d’ - Card not authenticated.
‘g’ - Code error.
‘h’ - Value format error.
11) Restore & transfer:
Tbbtt
bb: Two digits Block no whose value
is to be transferred.
tt: Two digits Block no to transfer
the data to.
This will issue the Restore and
Transfer command to the Mifare
Reader. The return value from the
reader is used to verify the status of
the command execution. This command
will backup the given block
data by transferring it to the given
block no.
e.g. T0810
This command will restore the
contents of the block 8 (eight) by
transferring them to the block 10
(ten).
Return value-command response
‘0’ - Command successful.
‘1’ - Card not found error.
‘8’ - Not yet implemented error.
‘9’ - Bit count error.
‘d’ - Card not authenticated.
‘g’ - Code error.
‘h’ - Value format error.
12) Reset:
t
This will issue the Reset command to
the Mifare Reader. The return value from the reader is used to verify the
status of the command execution. This command will reset the Mifare command
execution sequence and ‘reset’ the reader for new command execution sequence.
e.g. t
This command will issue the reset
command to the Mifare reader and enable further Mifare command execution on it.
Return value-command response +
Mifare card ID (4 digits)
‘0’ - Command successful.
‘1’ - Card not found error.
‘2’ - Crc error.
‘3’ - Parity error.
‘4’ - Overflow error.
‘5’ - Framing error.
‘6’ - Access timeout error.
‘7’ - Collision error.
‘8’ - Not yet implemented error
READER –TAG INTERACTION
5.1 INTRODUCTION: -
When the tag is brought
into the read range of the reader, the RF power is induced into the antenna
coil & is rectified to charge the capacitor. When the capacitor voltage
reaches a threshold value, the tag device is re-stetted and transmits the data
through back scattering. The device includes the modulation transistor, which
is connected across a portion of the antenna circuit.
5.2 Modulation
Transistor: -
The transistor has high turn
of (a few MW) & low
turn on (3W)
resistance. When the transistor turn off, the resonant circuit is turned to the
carrier frequency of the reader. This condition is called uncloaking. When the
modulation transistor turns on, its turn on resistance shorts the antenna
position. As a result, the resonant circuit no longer resonates at the carrier
frequency. This is called “cloaking”. The induced voltage amplitude changes
with the modulation data. Higher amplitude during uncloaking (tuned) & lower
amplitude during cloaking (detuned). This is called amplitude modulation
signal. The receiver channel in the reader detects the amplitude modulation
signal & reconstructs the modulation data.
The occurrence of the cloaking & uncloaking
of the device is controlled by the modulating signal that turns the modulation
transistor on & off, resulting in communication from the device to the
reader.
For the efficient data
transfer between tag & reader, they should follow certain hand shaking
process.
This
process is as follows:
Ø The reader
continuously transmits an RF signal & catches always for modulated
back-scattered signal.
Ø Once the
tag has received sufficient energy to operate correctly, it begins cloaking
it’s data to the modulation transistor, which is connected to the antenna
circuit.
Ø The tags
modulation transistor shots the antenna circuit, sequentially corresponding to
the data, which is being clocked out of the memory array.
Ø Shorting
& releasing the antenna circuit according to the modulation data causes
amplitude fluctuations of antenna voltage across the antenna circuit.
Ø The reader
detects the amplitude variation of the tag & tag uses a demodulation
circuit to extract the modulation data for error free data transmission, the
data is encoded at the tag end.
Data encoding refers to
processing or altering the data bit stream in between the time it is retrieved
from the RFID chips data array and it’s transmission back to reader. The
various encoding algorithms affect error recovery, cost of implementation,
bandwidth, synchronization capability & other aspects of the system design.
The certain popular method used in RFID tagging.
5.3 Methods
used in RFID Tagging:-
There are three methods of RFID
tagging. There are:
NRZ (non return to
zero) direct
Ø Differential
bi phase
Ø Bi phase-L
(Manchester )
5.3.1 NRZ
(non return to zero) direct: -
In this method no data
encoding is done at all. The ones & zeros are clocked from the data array
directly to the modulation transistor. A low in the peek detective in the
modulation signal is a zero and a high is one.
Differential
biphase: Several different forms of differential bi phase are used, but in
general the bit stream being in clocked out of the data array is modified so
that transition always occurs on every clock edge, & once & zeros are
distinguished by the transitions with in the middle of the clock period. This
method is used to embed the clocking information to help synchronize the reader
to bit stream. Because it always has a transition at the clock edge, it
inherently provides some error correction capability. Any clock edge that does
not contain a transition in the data stream is in error & can be used to
reconstruct the data.
5.3.2 Biphase-L(Manchester ):-
Here one is transmitted as a
logic high to low level transition at mid of the transmitting pulse and a zero
is transmitted as a logic low to high level transition at the mid of the
transmitting pulse.
This biphase –L(Manchester ) coding helps us the tag’s hard
ware and there by it is a must for us to adopt to the same, and there is no
other operation, and we need to follow the same as that of the tag’s
technology.
HARDWARE DESIGN
The
Hardware design phase consists of several parts. They are:
a)
Micro-controller
circuit design.
b)
Reader
interface to the micro controller
c)
LCD
interface
The
design consideration associated with each part is as discussed below:
5.1 Designing of power supply:
The power supply circuit
has to provide a 5v-regulated power to the micro controller for its
operation. The dc power required is derived from a 230v AC supply mains.
The circuit diagram of the designed
power supply is as shown in fig 5.1.
In the
circuit, a step down transformer of rating 230v primary with a isolated
secondary winding is used. The secondary winding provides an 8v ac output, with
a current capacity of 500mA.
The voltage provided by the
secondary winding, is rectified by using a bridge rectifier. A capacitor filter
to remove the ripple present in the output follows this. In these instrument
power supplies, the filter sections can be either p or L sections, but these
sections are not normally needed in low power, low voltage applications and
only a single capacitor is sufficient. The internal impedance of the secondary
winding is sufficient to limit the current during the initial surge. The
capacitor value should be of very high value for low ripple. Thus, a capacitor
of 1000mf
with a working voltage of 18v is sufficient, but with a factor of safety the
working voltage is considered as 35v.
The filtered DC output from
secondary winding, without any load has a value of 10v to 12v with normal input
supply of 230v AC. The input voltage may fluctuate over a wide range
practically. To accommodate these ranges a higher initial output, which is more
than 12v is considered. The regulator itself requires 2v higher than its
regulated output, i.e., 7v is needed for getting 5v. In order to accommodate
the voltage fluctuations on the lower side of 230v, another 5v additional
voltage is considered.
This voltage is fed to a three-pin
regulator 7805, which basically provides an output of 5v irrespective of its
input supply, provided the input is greater than 7v. But, at the maximum input
voltage, it should not exceed 32v, and as it is, it never happens, unless the
input supply voltage is greater then 400v, and is of rare nature. The output of
this regulator is connected with a small capacitor of 0.1mf to 1mf (between output and ground). This
capacitor improves the noise immunity of the power supply circuit. This output
drives the micro controller.
Fig.5.1.
Micro controller power supply.
5.2 Design of Micro controller circuit
The basic features needed with a
micro controller for this application are:
Ø
Approximately
8k-12k of ROM space for the basic implementation software, which is to be
developed during the project implementation.
Ø
Minimum
of 256 bytes of internal RAM to store the data received, process variables
while the program is running and also to use as stack.
Ø
11 I/O lines to interface the LCD, to display
the strings that are to be transmitted, and on the receiver side that are
received.
Ø
Serial
communication block for communicating
serially with the reader by setting the appropriate baud rate.
Apart
form these basic features, it is also required to have the following additional
features, to make the product a full- fledged commercial product.
Ø
Analog
input pins, to sense the parameters such as temperature, humidity, and wind
speed, etc. the environmental factors or certain other analog signals of
interest.
Ø
Additional
3-4 I/O lines to indicate the status and fault conditions through LEDs.
Ø
Additional
ROM/RAM memory space to incorporate other advanced control applications.
Most of the present day micro controllers from different manufacturers
satisfy these requirements.
Apart from these standard features, in order to use the micro
controllers, especially to write the developed code into ROM of the micro
controller, the necessary software and hardware support from the micro
controller manufacturer, commonly referred as developmental tools.
The features required by the micro controller to be used in this project
is to be advanced, but because of the non-availability of development tools and
also due to their cost, we resorted to a basic and popular micro controller
from ATMEL, the AT89C52. The operational features of the micro controller along
with the software instructions are provided in the “Annexure-A”.
The micro controller has to be used to
collect the data from the ADC and to display it. Several different types of
micro controllers are available in the market from different manufacturers with
different capabilities; such as in built ROM, RAM, I/O ports. Timers ADC, DAC
etc. also varies from one micro controller to the other.
For a particular application, apart
from these logic issues, the other main aspect is its economics, which mainly
decides the product final price. The other major issue, while choosing a micro
controller is the support provided by the manufacturer for utilizing it. To
write the program into the micro controller, a specific tool known as a writer
board is to be needed. The writer board is not a common gadget for all the
micro controllers. Even to develop the program is also a Herculean job.
Normally the programs can be written in assembly and are entered into a PC, via
the software provided by the micro controller manufacturer, the assembly code
is converted into mnemonics (Assembler). This mnemonic code is the one, which
is to be written in to the controller. This is done by a writer board, which is
hooked up to the PC, by using the RS-232 serial interface. Some times it is
highly difficult to write the programs in assembly, in those circumstances, the
programs are written in ‘C’ and the ‘C’ code is converted into the machine code
using a compiler, the code thus generated can be dumped into the micro
controller using a PC.
To speed up the process of development
of gadget, an emulator is needed, which can be used to develop the programs by
using what are called as break points. The assembler and compilers, are
software tools, while emulator is both hardware and software tool. Without these
basic tools, however good might be the micro controller, one cannot use it to
its optimum performance.
The operational
features of the micro controller along with the soft ware instructions were
provided in the “Annexure – A”. The internal block diagram of the micro
controller is provided in fig. 5.2
Fig.5.2.
Internal block diagram of the micro controller.
Any microprocessor or micro controller requires clock for its
operation. Most of them are having built in oscillators, and only a crystal of
appropriate frequency has to be connected across the terminals provided in the
IC. The 89C52 is designed to operate at 12MHz. So the crystal connected is
12MHz, and is connected across the specified pins as shown in fig.4.6.
Fig.4.6. RESET and clock
generation circuits.
In the case of power on or whenever the CPU enters into an endless loop
or a program of an unknown destination, the CPU has to be reset. In order to
achieve, both power on and manual reset, the circuit is to be connected as
shown in fig.4.6. In the reset circuit, it is required to maintain a high
voltage (logic 1 level) on the reset pin for a period 24 clock cycles of the
clock. The series RC circuit connected as shown in the fig.4.6 achieves this.
The R& C values are chosen in such a way to provide a high pulse for a
period of more than 24 clock periods, and they are10-Kohms and 10micro farads.
The time constant of the RC circuit is 100msecs. A press to on switch is
connected across the capacitor as shown in the fig . which on a press provides
a high signal on the reset pin.
Reader Interface to the
micro controller: The
main micro controller is to be interfaced to the reader micro controller
i.e., communication is to be established
between the two micro controllers. The Rx
pin(pin 10) of the main micro
controller is connected to Tx pin of the reader controller and the
Tx pin(pin 11) of the main micro
controller is connected to Rx pin of the reader controller.
LCD Interface to the
micro controller:- The LCD used in this project is a 16
character and 2 line LCD, which is normally referred as 16 X 2 LCD. This LCD is
an alphanumeric LCD that means it can be used to display the characters of both
alphabets and numerals apart from special symbols. The value to be displayed on
the LCD’s panel is sent in the form of ASCII code format. The values to be sent
and the commands to the LCD are sent on the data bus by using a port of the
micro controller, which is connected to the LCD through the port of the micro
controller. The same data bus is used to carry the data signals in both the
directions and also to send the commands to the LCD. The LCD’s accept the
standard commands and accept the ASCII codes. Internally the LCD controller
decodes these codes and performs the control activity and also decodes the
ASCII codes and sends the bit map format in order to display the character on
the LCD.
The 8 data pins of the LCD are connected to the 8 pins of
port 1. The rs (register select), r/w (read/write), and en (enable) pins of the
LCD are connected to P2.0,P2.1 and P2.2
respectively.
Block diagram of the RFID is given
below
SOFTWARE DESIGN
The main micro controller receives the tag information from the reader
micro controller. This is a code of certain bit length and is entirely
dependent on the tag silicon circuit. The information stored in the tag is one,
which is radiated by the tag and is received by the reader and decoded and is
given to the main micro controller. This code is unique for each tag. The micro
controller in the present application process, checks the received code with
the codes present in the database and once the received code is correct the
micro controller displays the name of the tag owner , and the access status on
an the LCD . The application software can be modified to perform other
functions also.
Initially all the ports, lcd and the serial communication are
initialized. The baudrate for the serial communication is set to 9600kbps.
After this a code for displaying
“WELCOME” is written.
Once the initialization part is over the command for resetting the
reader i.e “t enter” is transmitted
serially. If the reader responds to it and transmit ‘0’ then the main
controller transmits read command i.e.,” R100001 enter” serially. If the card
is present the reader micro controller transmits the code present in the card
to the main micro controller. The main micro controller stores the received
data in RAM and compares the data with code
present in data base. If the code matches then the name of the card holder and
“Access validated” is displayed on the LCD, if not “ Access Invalid “ is
displayed on the LCD.
The main micro controller
continuously keeps on transmitting the reset and read command to the reader
micro controller. This whole process is kept in a infinite loop.
Flow charts and the source code of
this project is given below:
FLOW CHARTS
MAIN PROGRAM
INTERRUPT
ROUTINE
SOURCE CODE
#include<reg51.h>
sfr
ldata=0x90;
sfr
motor=0x80;
sbit rs=P2^0;
sbit rw=P2^1;
sbit en=P2^2;
sbit busy=P1^7;
unsigned char
mybyte,lcd,msg,v[82],ii,w=0,i,z=0,n=1;
int k;
void main(void)
{
void lcddata(unsigned char);
void lcdcmd(unsigned char);
void check();
void sertx(unsigned char);
void delay(unsigned int);
void clockwise();
void anticlockwise();
void display(unsigned char
*dis,unsigned char rr);
TMOD=0x20;
TH1=0xFD;
SCON=0x50;
TR1=1;
IE=0X90;
lcdcmd(0x38);
lcdcmd(0X0e);
lcdcmd(0x01);
lcdcmd(0x06);
lcdcmd(0x80);
lcdcmd(0x01);
while(1)
{
ii=0;
w=0;
delay(10);
if(n==1)
{
lcdcmd(0x01);
lcdcmd(0x80);
display("WELCOME",7);
lcdcmd(0x0c);
n=0;
}
sertx('t');
sertx(0x0d);
delay(10);
if (v[0]==0x30)
{
sertx('R');
sertx(0x31);
sertx(0x30);
sertx(0x30);
sertx(0x30);
sertx(0x30);
sertx(0x31);
sertx(0x0d);
}
delay(100);
for(ii=1;ii<w;ii++)
{
if(v[ii]==0x41)
{
lcdcmd(0x01);
lcdcmd(0x80);
display("SARATH",6);
lcdcmd(0xc0);
display("ACCESS VALIDATED",16);
clockwise();
delay(200);
anticlockwise();
n=1;
break;
}
if(v[ii]==0x42)
{
lcdcmd(0x01);
lcdcmd(0x80);
display("JAGADEESH",9);
lcdcmd(0xc0);
display("ACCESS VALIDATED",16);
clockwise();
delay(200);
anticlockwise();
n=1;
break;
}
if(v[ii]==0x43)
{
lcdcmd(0x01);
lcdcmd(0x80);
display("ACCESS INVALID",14);
delay(100);
n=1;
break;
}
}
}
}
//}
void sertx(unsigned char x)
{
SBUF = x;
while(TI==0);
TI=0;
}
void ser_int() interrupt 4
{
if(RI)
{
v[ii]=SBUF;
w=ii;
ii++;
RI=0;
}
}
void display(unsigned char
*dis,unsigned char rr)
{
unsigned char m;
for (m=0;m<rr;m++)
{
lcddata(dis[m]);
}
}
void delay(unsigned int itime)
{
unsigned int a,b;
for(a=0;a<1275;a++)
{
for(b=0;b<itime;b++);
}
return;
}
void lcdcmd(unsigned char value)
{
check();
ldata=value;
rs=0;
rw=0;
en=1;
for(k=0;k<1275;k++);
en=0;
return;
}
void
lcddata(unsigned char value)
{
check();
ldata=value;
rs=1;
rw=0;
en=1;
for(k=0;k<1275;k++);
en=0;
return;
}
void
check(void)
{
busy=1;
rs=0;
rw=1;
while(busy==1)
{
en=0;
for(k=0;k<1275;k++);
en=1;
}
return;
}
void
clockwise()
{
int i;
for(i=0;i<20;i++)
{
motor=0x66;
delay(5);
motor=0xcc;
delay(5);
motor=0x99;
delay(5);
motor=0x33;
delay(5);
}
}
void anticlockwise()
{
int i;
for(i=0;i<20;i++)
{
motor=0x66;
delay(5);
motor=0x33;
delay(5);
motor=0x99;
delay(5);
motor=0xcc;
delay(5);
}
}
RESULTS AND CONCLUSIONS
The project is working
satisfactorily for the features it has developed for.
The project can be further extended to
implement other applications like security,restricted access, attendance,
library applications and time office keeping, etc. , with the application software change suited in the
main micro controller. This is only a basic RFID.
0 Comments