smart card synopsis
TRANSCRIPT
-
8/4/2019 Smart Card Synopsis
1/74
LIST OF CONTENTS
SECTION 1:-INTRODUCTION..5
SECTION 2:-COMPONENT USED7
SECTION 3:-CIRCUIT DIAGRAM9
SECTION 4:-COMPONENT DESCRIPTION11
SECTION 5:-PCB LAYOUT44
SECTION 6:-WORKING OF PROJECT..49
SECTION 7:-PROGRAMMING OF PROJECT52
SECTION 8:-SNAPSHOT OF PROJECT..68
SECTION 8:-APPLICATIONS & SCOPE..........70
SECTION 9:-BIBLIOGRAPHY74
-
8/4/2019 Smart Card Synopsis
2/74
-
8/4/2019 Smart Card Synopsis
3/74
INTRODUCTION TO PROJECT
Smart Card Entry Access is a basically a project which is used in big organizations for security
purposes. With the right controls in place, the user must have the smart card and know the PIN to
gain access to network resources. The two-factor requirement significantly reduces the likelihood
of unauthorized access to an organizations network.
This project is based on 8051 Microcontroller. In this we have to give our identity using
password and smart card. This project is simple module which is valid for one person only.
The Smart Card is made of plastic, generally polyvinyl chloride, but sometimes acrylonitrile
butadiene styrene or polycarbonate . Smart cards may also provide strong security authentication
for single sign-on within large organizations.
As in any organization on swapping card gate opens and one can get into the special areas oforganization. In the same way swapping card through sensors D.C Motor rotates.
FEATURES
Fully micro controller based interface using PIC16F72 MCU
Working Voltage12V AC/DC
Operating Current - 500ma Approx
Relay Contact Rating 230V AC / 500W
On board 16 x 2 LCD display
Programmable user code
On board switches for programmed the smart card
-
8/4/2019 Smart Card Synopsis
4/74
SECTION-2
COMPONENTS USED
-
8/4/2019 Smart Card Synopsis
5/74
*MICROCONTROLLER(AT89S52)
*OSCILLATOR CLOCK CIRCUIT
*POWER SUPPLY
*TRANSFORMER
*KEYPAD MATRIX
*LIQUID CRYSTAL DISPLAY
*SENSORS(MOC 7811)
*D.C. MOTOR
*MOTOR DRIVER(L2930)
SECTION-3
-
8/4/2019 Smart Card Synopsis
6/74
CIRCUIT DIAGRAM
HARDWARE DESIGN OF PROJECT
-
8/4/2019 Smart Card Synopsis
7/74
-
8/4/2019 Smart Card Synopsis
8/74
SECTION-4
COMPONENT DESCRIPTION
MICROCONTROLLER (AT89S52)
-
8/4/2019 Smart Card Synopsis
9/74
8051 family microcontrollers is based on an architecture which is highly optimized for
embedded control systems. It is used in a wide variety of applications from military
equipment to automobiles to the keyboard. Second only to the Motorola 68HC11 in eight bit
processors sales, the 8051 family of microcontrollers is available in a wide array of variations
from manufacturers such as Intel, Philips, and Siemens. These manufacturers have added
numerous features and peripherals to the 8051 such as I2C interfaces, analog to digital
converters, watchdog timers, and pulse width modulated outputs. Variations of the 8051 with
clock speeds up to 40MHz and voltage requirements down to 1.5 volts are available. This
wide range of parts based on one core makes the 8051 family an excellent choice as the base
architecture for a company's entire line of products since it can perform many functions and
developers will only have to learn this one platform.
AT89S52 is a low-power,high-performance CMOS 8-bit controller 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 pinout. The on-chip Flash allows the program memory to be reprogrammed in-system
or by a conventional nonvolatile memory programmer. 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. 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.
PIN CONFIGURATION
-
8/4/2019 Smart Card Synopsis
10/74
-
8/4/2019 Smart Card Synopsis
11/74
VCC:- Supply voltage
GND:- Ground.
PORT 0
Port 0 is an 8-bit open drain bidirectional I/O port. As an output port, each pin can sink eight
TTL inputs. When 1s are written to port 0 pins, the pins can be used as high impedance inputs
.Port 0 can also be configured to be the multiplexed low order address/data bus during accesses
to external program and data memory. In this mode, P0 has internal pull ups. Port 0 also receives
the code bytes during Flash programming and outputs the code bytes during program verification
.External pull ups are required during program verification.
PORT 1
Port 1 is an 8-bit bidirectional I/O port with internal pull ups. The Port 1 output buffers can
sink/source four TTL inputs. When 1s are written to Port 1 pins, they are pulled high by the
internal pull ups and can be used as inputs. As input ,Port 1 pins that are externally being pulled
low will source current (IIL) because of the internal pull ups. In addition, P1.0 and P1.1 can be
configured to be the timer/counter 2 external count input (P1.0/T2) and the timer/counter 2
-
8/4/2019 Smart Card Synopsis
12/74
trigger input (P1.1/T2EX).Port 1 also receives the low-order address bytes during Flash
programming and verification.
Port 2
Port 2 is an 8-bit bidirectional I/O port with internal pull ups. The Port 2 output buffers can
sink/source four TTL inputs. When 1s are written to Port 2 pins, they are pulled high by the
internal pull ups and can be used as inputs. As inputs, Port 2 pins that are externally being pulled
low will source current (IIL) because of the internal pull ups. Port 2 emits the high-order address
byte during fetches from external program memory and during accesses to external data memory
that use 16-bit addresses (MOVX @DPTR). In this application, Port uses strong internal pull ups
when emitting 1s. During accesses to external data memory that use 8-bit addresses (MOVX @
RI), Port 2 emits the contents of the P2 Special Function Register. Port 2 also receives the high-
order address bits and some control signals during Flash programming and verification.
Port 3
Port 3 is an 8-bit bidirectional I/O port with internal pull ups .The Port 3 output buffers can
sink/source four TTL inputs. When 1s are written to Port 3 pins, they are pulled high by the
. With the bit set, ALE is active only during a MOVX or MOVC instruction. Otherwise, the pin
is weakly pulled high. Setting the ALE-disable bit has no effect if the microcontroller is in
external execution mode.
PSEN
Program Store Enable (PSEN) is the read strobe to external internal pull ups and can be used as
inputs. As inputs, Port 3 pins that are externally being pulled low will source Current (IIL)
because of the pull ups .Port 3 also serves the functions of various special features of the
AT89S52, as shown in the following table .Port 3 also receives some control signals for Flash
programming and verification.
RST
Reset input. A high on this pin for two machine cycles while the oscillator is running resets the
device. This pin drives High for 96 oscillator periods after the Watchdog times out .The DISRTO
bit in SFR AUXR (address 8EH) can be used to disable this feature. In the default state of bit
DISRTO, the RESET HIGH out feature is enabled.
ALE/PROG
-
8/4/2019 Smart Card Synopsis
13/74
Address Latch Enable (ALE) is an output pulse for latching the low byte of the address during accesses to
external memory. This pin is also the program pulse input (PROG) during Flash programming. In normal
operation, ALE is emitted at a constant rate of 1/6 the oscillator frequency and may be used for external
timing or clocking purposes. Note, however, that one ALE pulse is skipped during each access to external
data memory. If desired, ALE operation can be disabled by setting bit 0 of SFR location 8EHprogram
memory. When the AT89S52 is executing code from external program memory, PSEN is activated twice
each machine cycle, except that two PSEN activations are skipped during each access to external data
memory.
EA/VPP
External Access Enable. EA must be strapped to GND in order to enable the device to fetch
code from external program memory locations starting at 0000H up to FFFFH. Note, however,
that if lock bit 1 is programmed, EA will be internally latched on reset. EA should be strapped toVCC for internal program executions. This pin also receives the 12-volt programming enable
voltage(VPP) during Flash programming.
XTAL1
Input to the inverting oscillator amplifier and input to the internal clock operating circuit
XTAL2
Output from the inverting oscillator amplifier
SPECIAL FUNCTION REGISTERA map of the on-chip memory area called the Special Function Register (SFR) space .
Note that not all of the addresses are occupied, and unoccupied addresses may not be
implemented on the chip. Read accesses to these addresses will in general return effect. User
software should not write 1s to these unlisted locations, since they may be used in future
products to invoke new features. In that case, the reset or inactive values of the new bits will
always be 0.
TIMER 2 REGISTER:
Control and status bits are contained in registers T2CON and T2MOD for Timer 2. The register
pair (RCAP2H, RCAP2L) are the Capture/Reload registers for Timer 2 in 16-bit capture mode or
16-bit auto-reload mode.
-
8/4/2019 Smart Card Synopsis
14/74
INTERRUPT REGISTER:
The individual interrupt enable bits are in the IE register. Two priorities can be set for each of
the six interrupt sources in the IP register.
DUAL DATA POINT REGISTER
To facilitate accessing both internal and external data memory, two banks of 16-bit Data Pointer
Registers are provided: DP0 at SFR address locations 82H-83H and DP1 at 84H-85H. Bit DPS =
0 in SFR AUXR1 selects DP0 and DPS = 1 selects DP1. The user should always initialize theDPS bit to the appropriate value before accessing the respective Data Pointer Register.
POWER OFF REGISTER
The Power Off Flag (POF) is located at bit 4 (PCON.4) in the PCON SFR. POF is set to 1
during power up. It can be set and rest under software control and is not affected by reset.
-
8/4/2019 Smart Card Synopsis
15/74
-
8/4/2019 Smart Card Synopsis
16/74
MEMORY ORGANISATOIN
MCS-51 devices have a separate address space for Program and Data Memory. Up to 64K bytes
each of external Program and Data Memory can be addressed.
PROGRAM MEMORY
If the EA pin is connected to GND, all program fetches are directed to external memory.
On the AT89S52, if EA is connected to VCC, programfetches to addresses 0000H through
1FFFH are directed tointernal memory and fetches to addresses 2000H through FFFFH are to
external memory.
DATA MEMORY
The AT89S52 implements 256 bytes of on-chip RAM. The upper 128 bytes occupy a parallel
address space to the Special Function Registers. This means that the upper 128 bytes have the
same addresses as the SFR space but are physically separate from SFR space. When an
instruction accesses an internal location above address 7FH, the address mode used in the
instruction specifies whether the CPU accesses the upper 128 bytes of RAM or the SFR space.
Instructions which use direct addressing access of the SFR space. For example, the following
direct addressing instruction accesses the SFR at location 0A0H (which is P2).
MOV 0A0H, #data
Instructions that use indirect addressing access the upper 128 bytes of RAM. For example, the
following indirect addressing instruction, where R0 contains 0A0H, accesses the data byte at
address 0A0H, rather than P2 (whose address is 0A0H).
MOV @R0, #data
Note that stack operations are examples of indirect addressing, so the upper 128 bytes of data
RAM are available as stack space.OSCILLATOR CLOCK CIRCUIT
It uses a quartz crystal oscillator
We can observe the frequency on the XTAL2 pin
-
8/4/2019 Smart Card Synopsis
17/74
The crystal frequency is the basic internal frequency of the microcontroller.
The internal counters must divide the basic clock rate to yield standard
communication bit per second (baud) rates.
An 11.0592 megahertz crystal, although seemingly an odd value, yields a crystal
frequency of 921.6 kilohertz, which can be divided evenly by the standard communication
baud rates of 19200, 9600, 4800, 2400, 1200, and 300 hertz
The function of an oscillator circuit is to provide an accurate and stable periodic clock signal to
a microcontroller. The frequency of this clock signal can range from a few kilohertz to tens of
megahertz and determines how quickly the microcontroller executes its instructions. Most
microcontrollers include a clock driver circuit which is designed to drive a quartz crystal into
oscillation. The clock driver circuitry built into the PIC micro family is very flexible and allows
for four different clocking options: clock signal supplied from another oscillator, an R-C clock
(based on a resistor-capacitor charging time constant), a ceramic resonator, or a crystal oscillator.
An R-C clock circuit is the simplest but does not provide accurate timing since both resistor and
capacitor values can vary greatly with temperature. Crystal oscillator and ceramic resonator-
based clock circuits provide the most stable and accurate time bases, and require only a few extra
parts than a simple R-C oscillator (see the schematic diagram, above)..
The clock circuit consists of capacitors C1 and C2, a quartz crystal or ceramic resonator Y1, and
a series resistor, R3. The values of capacitors C1 and C2 is determined by both the clock speed at
which you intend to run the PIC micro, and by the selection of a quartz crystal or a ceramic
resonator as the clock source. Use the table as a guide to select the appropriate capacitors.
When the capacitance of C1 orC2 is shown as a range of values, select a higher capacitance for
lower frequencies of operation, and a lower capacitance for higher clock frequencies. For
example, when using the XT oscillator mode with a 100 kHz quartz crystal, select a value of C1
close to 30 pF and a value of C2 close to 300 Pf for the best performance.
Series resistor R3 is required for some types of crystals in HS or XT mode. Including R3 with
crystals that do not require a series resistor will not degrade the performance of the oscillator
-
8/4/2019 Smart Card Synopsis
18/74
circuit. A low value of resistance, up to a few hundred ohms, will keep the clock driver circuit in
the PICmicro from overdriving the crystal.
SELECTING THE COMPONETS
Quartz crystals and ceramic resonators are similar, but have some physical differences. As
shown in the diagram, quartz crystals are typically mounted in a hermetically sealed metal case
with two wire leads protruding from the bottom. Sometimes crystals may have a third ground
lead soldered or welded to the top of the metal can. Grounding the pin on the metal
can helps to both stabilize the crystal, lessening the impact of mechanical shock, as well as
reduces RF emissions. Select a quartz crystal specified as a microprocessor crystal rather than a
tuning crystal for radio. Typically, these are stocked in common frequencies by most large
electronic distributors. Ceramic resonators are usually produced in the form of molded or dipped
parts with two or three wire leads. The center wire, if present, connects to the circuit ground.
Both quartz crystals and ceramic resonators are non-polarized electronic devices and can be
installed in the oscillator circuit in either orientation. Lastly, the type of resistor and capacitors
chosen for the circuit are not critical. Any ceramic or monolithic capacitor of the suggested
value should work, as should any typical watt metal or carbon film resistor.
BUILDING THE OSCILLATOR
-
8/4/2019 Smart Card Synopsis
19/74
A few general precautions should be observed when building the oscillator circuit. Since the
clock oscillator is typically the source of the fastest signals, and potentially, the major source of
RF
emissions in a circuit, good design practice dictates that all clock circuit signal lengths should be
kept as short as possible. A good, low impedance ground return wire from capacitors C1 and C2
to the circuit ground is also necessary Some PIC micros, like the PIC16C711, use the pins
adjacent
to the clock oscillator circuit as analog inputs. For accurate analog to- digital conversion it is
especially important to minimize the length of any clock oscillator signal wires running in
parallel with the analog input lines. Ideally, separate the analog signal lines from any digital
signals by using a ground wire as a shield between all analog and digital wiring.
PROGRAMMING THE MEMORY
Before you download your program into a PIC micro, you must select the appropriate clock
oscillator
fuse settings. These settings tell the PIC micro which of the four clock oscillator options to use.
The oscillator fuse settings are most commonly set by the downloading software, but some
assemblers allow you to specify the oscillator type in your source code. Make sure that you know
how to select the oscillator before programming your microcontroller.
THE RESET CIRCUIT
A real reset circuit is not necessary in order for a PIC micro to function in a circuit. The only
component required to run a PIC micro, other than those parts that make up the oscillator circuit,
is a pull-up
resistor connected to the MCLR/ Vpp pin. In the schematic diagram, R2 functions as the pull up
resistor.If you omit the pull-up resistor, your PIC micro will remain in reset (clear) mode on
power-up, and will not execute its program. Resistor R1 and pushbutton switch S1 make up an
actual reset circuit. When S1 is pressed, it completes a low impedance connection from the
MCLR/Vpp pin to ground, forcing the PIC micro into reset (clear) mode. Resistor R1 is optional,
-
8/4/2019 Smart Card Synopsis
20/74
and is used to limit the current on the MCLR/Vpp pin to prevent a condition called latch upin
which the input circuit of a CMOS chip can become stuck. Electrostatic discard (ESD) from a
person touching the reset switch could potentially cause latch-up. S1 is not two push button
switches as the schematic seems to indicate. We use a small pcb mounted pushbutton switch with
four legs in our circuitsthats why the one in the schematic is shown with four circles attached
to wires. There is one last part in the basic oscillator and reset circuit.
Capacitor C3 is a decoupling capacitor which forms part of the power supply circuit.
POWER SUPPLY
A power supply is a device that supplies electrical energy to one or more electric loads. The term
is most commonly applied to devices that convert one form of electrical energy to another,
though it may also refer to devices that convert another form of energy (e.g., mechanical,
chemical, solar) to electrical energy. A regulated power supply is one that controls the output
voltage or current to a specific value; the controlled value is held nearly constant despite
variations in either load current or the voltage supplied by the power supply's energy
source.Every power supply must obtain the energy it supplies to its load, as well as any energy it
consumes while performing that task, from an energy source. Depending on its design, a power
supply may obtain energy from:
Electrical energy transmission systems. Common examples of this include power
supplies that convert AC line voltage to DC voltage.
Energy storage devices such as batteries and fuel cells.
Electromechanical systems such as generators and alternators.
Solar Power
-
8/4/2019 Smart Card Synopsis
21/74
A power supply may be implemented as a discrete, stand-alone device or as an integral device
that is hardwired to its load. In the latter case, for example, low voltage DC power supplies are
commonly integrated with their loads in devices such as computers and household electronics.
An electronic circuit is only stable as its power supply. Capacitor C3 is a decoupling capacitor
which is used to reduce ringing and ground-bounce on the power supply lines. In other words,
C3 works to cleanup any voltage fluctuations at the power supply pins of the PIC micro. To be
most effective, it is important to mount C3 as close to the PIC micro power supply pin (Vdd) as
possible. The schematic diagram on the last page of this project sheet shows a simple regulator
circuit that will produce a five volt output from any input voltage between approximately eight
and twenty volts (its shown with a 9V source attached). U2 is a 7805 three-terminal voltage
regulator IC. It works by actively maintaining a five volt output independent of the output
current. The difference between the output voltage (5V) and the input voltage is converted to
heat. The higher the input voltage, the hotter U2 will get. You may need to add a heat sink to U2
if you have a high input voltage, or a high output current. Capacitors C5 and C6 are input and
output filter capacitors for the voltage regulator. C5 may not be necessary if a battery is used to
power the circuit, and as long asthe battery wires are kept short. Capacitor C6 is important as an
output filter capacitor for the regulator. If you wish to add other circuits to the voltage regulator,
try to run a separate set of wires from your new circuit back to the +5V and ground common
connections at C6
TRANSFORMER
A transformer is a device that transfers electrical energy from one circuit to another through
inductively coupled conductorsthe transformer's coils. A varying current in the first or primary
winding creates a varying magnetic flux in the transformer's core and thus a varying magnetic
field through the secondary winding. This varying magnetic field induces a varying
electromotive force (EMF) or "voltage" in the secondary winding. This effect is called mutual
induction.
If a load is connected to the secondary, an electric current will flow in the secondary winding and
electrical energy will be transferred from the primary circuit through the transformer to the load.
In an ideal transformer, the induced voltage in the secondary winding (Vs) is in proportion to the
-
8/4/2019 Smart Card Synopsis
22/74
primary voltage (Vp), and is given by the ratio of the number of turns in the secondary (Ns) to
the number of turns in the primary (Np) as follows:
By appropriate selection of the ratio of turns, a transformer thus allows an alternating current
(AC) voltage to be "stepped up" by making Ns greater than Np, or "stepped down" by making Ns
less than Np.
Here we use step down Transformer which will convert 220 Volt D.C Power Supply into 5 volt
which is the basic requirement of our project.
CONSTRUCTION, TYPES, AND CHARACTERISTICS
1. A transformer is an apparatus for converting electrical power in an ac system at one voltage
or current into electrical power at some other voltage or current without the use of rotating parts.
2. A constant-voltage transformer consists essentially of three parts: the primary coil which
carries the alternating current from the supply lines, the core of magnetic material in which is
produced an alternating magnetic flux, and the secondary coil in which is generated an emf by
the change of magnetism in the core which it surrounds. Sometimes the transformer may have
only one winding, which will serve the dual purpose of primary and secondary coils. The high-
tension winding is composed of many turns of relatively fine copper wire, well insulated to
withstand the voltage impressed on it. The low-tension winding is composed of relatively few
turns of heavy copper wire capable of carrying considerable current at a low voltage.
3. Transformer terminology Theprimary winding is the winding of the transformer which is
connected to the source of power. It may be either the high- or the low voltage winding,
depending upon the application of the transformer.The secondary winding is the winding of the
-
8/4/2019 Smart Card Synopsis
23/74
transformer which delivers power to the load. It may be either the high- or the low-voltage
winding, depending upon the application of the transformer. The core is the magnetic circuit
upon which the windings are wound. The high tension winding is the one which is rated for the
higher voltage. The low-tension winding is the one which is rated for the lower voltage. A step-
up transformer is a constant-voltage transformer so connected that the delivered voltage is
greater than the supplied voltage. A step-down transformeris one so connected that the delivered
voltage is less than that supplied; the actual transformer may be the same in one case as in the
other, the terms stepup and step-down relating merely to the application of the apparatus.
4. Transformer cores Until recently, all transformer cores were made up of stacks of sheet-steel
punchings firmly clamped together. One method of assembly and clamping of the sheets is
shown in Fig. 5.2. Sometimes the laminations are coated with a thin varnish to reduce eddy
current losses. When the laminations are not coated with varnish, a sheet of insulating paper is
inserted between laminations at regular intervals. A new type of core construction consists of a
continuous strip of silicon steel which is wound in a tight spiral around the insulated coils and
firmly held by spot welding at the end. This type of construction reduces the cost of manufacture
and reduces the power loss in the core due to eddy currents.
-
8/4/2019 Smart Card Synopsis
24/74
5. Cooling of transformers A certain amount of the electrical energy delivered to a transformer
is transformed into heat energy because of the resistance of its windings and the hysteresis and
eddy currents in the iron core. Means must be provided for removing this heat energy from the
transformer and dissipating it into the surrounding air. If this were not done in a satisfactory
manner, the transformer would operate at an excessively high temperature, which would destroy
or harm the insulation of the transformer. In self-aircooled transformers the windings are
simply surrounded by air at atmospheric pressure. The heat is removed by natural convection of
the surrounding air and by radiation from the different parts of the transformer structure. Air
cooling has long been employed for transformers of very small capacity. The development of
satisfactory coil insulation materials, such as porcelain, mica, glass, and asbestos.
KEYPAD MATRIX
The key board here we are interfacing is a matrix keyboard. The key board is designed with a
particular rows & columns. These rows & columns are connected to the microcontroller through
its ports of the microcontroller 8051. We normally use 4*3 matrix keyboard . So only one port
of 8051 can be easily connected to the rows of the keyboard.
When ever a key is pressed , a row and a column gets shorted through that pressed key and aal
the other keys are left open. When a key is pressed only a bit in the port goes high. By this high
on the bit key in the corresponding column is identified.
-
8/4/2019 Smart Card Synopsis
25/74
-
8/4/2019 Smart Card Synopsis
26/74
This reference design illustrates the implementation of a keypad matrix scanner using a Silicon
Blue iCE65 FPGA. The keypad scanner HDL code is a generic implementation, which supports
any number of rows and columns. This document describes 7x7 matrix keypad scanner,
commonly used to accept inputs from a QWERTY keypad, generally found in PDAs and other
hand held devices. The design includes functionalities such as user definable key debounce time
setting and auto sleep feature for conserving power.
A keypad forms an important part of the user interface of any electronic device. It is generally
implemented using a grid of rows and columns, as shown in Figure 1. An event such as a key
-
8/4/2019 Smart Card Synopsis
27/74
press or a key release can be decoded by driving and reading these rows and columns in a
specific manner.
In this application example, the columns have been configured as outputs and the rows as inputs.
All the row lines have been pulled up using pull-up resistors near the iCE65 FPGA inputs. On
power-up, or on reset, all the columns are driven low and the status of all the seven rows is
constantly monitored. This state is also known as the keypad scanner's Sleep Mode, in which
the dynamic scanning of every line is suspended to conserve power. Silicon Blue. Beforepressing any key, initialize keypad scanner by supplying a high pulse to its 'rst' input. A key
press is indicated whenever the valid line is high. This bit will remain high as long as the key
remains pressed. During this time, the row_addr and col_addr buses provide the matrix address
of the pressed key in terms of its row and column number. The keypad scanner design listed in
this application note when implemented using Silicon Blue device iCE65L04-UCB284C for a
keypad matrix of size 7x7, runs at a frequency of 32 kHz utilizing 50 Flip-Flops and 153 LUTs
(Post P&R data).
This example design demonstrates the implementation of a keypad scanner on iCE FPGAs. ICE
FPGAs, due to their very low power capabilities, are ideal for implementing applications
requiring a keypad, such as hand held and mobile devices where power saving is of paramount
importance. Silicon Blue is providing this document, design example, or information "as is."
Silicon Blue does not ensure that this implementation or information is void of any claims of
infringement. As a reader / implementer, you are responsible for obtaining any rights you may
require for your implementation. Silicon Blue also does not warranty the fitness of this design
example to be readily implemented in any specific context. It is your sole responsibility to
validate this design example and its correctness while implementing it for your requirement. This
example design demonstrates the implementation of a keypad scanner on iCE FPGAs. ICE
FPGAs, due to their very low power capabilities, are ideal for implementing applications
requiring a keypad, such as hand held and mobile devices where power saving is of paramount
importance.
Before pressing any key, initialize keypad scanner by supplying a high pulse to its 'rst' input. A
key press is indicated whenever the valid line is high. This bit will remain high as long as the key
remains pressed. During this time, the row_addr and col_addr buses provide the matrix address
of the pressed key in terms of its row and column number.
-
8/4/2019 Smart Card Synopsis
28/74
The keypad scanner design listed in this application note when implemented using Silicon Blue
device iCE65L04-UCB284C for a keypad matrix of size 7x7, runs at a frequency of 32 kHz
utilizing 50 Flip-Flops and 153 LUTs (Post P&R data).
LIQUID CRYSTAL DISPLAY
The LCD is a dot matrix liquid crystal display that displays alphanumeric, kana(Japanese)
character and symbols. The built-in controller & driver LSIs provide convenient connectivity
between a dot matrix LCD and most 4 or 8 bit microprocessor or microcontrollers. Al the
functions required for dot matrix liquid crystal display drive are internally provided. Internal
refresh is provided by the LCD. The CMOC technology makes the device ideal for application in
hand held, portable and other battery powered instruments with low power consumption.
DESCRIPTION
The HD44780U dot-matrix liquid crystal display controller and driver LSI displays
alphanumerics, Japanese kana characters, and symbols. It can be configured to drive a dot-matrix
liquid crystal display under the control of a 4- or 8-bit microprocessor. Since all the functions
such as display RAM, character generator, and liquid crystal driver, required for driving a dot
matrix liquid crystal display are internally provided on one chip, a minimal system can be
interfaced with this controller/driver. A single HD44780U can display up to one 8-character line
or two 8-character lines. The HD44780U has pin function compatibility with the HD44780S
which allows the user to easily replace an LCD-II with an HD44780U. The HD44780U character
generator ROM is extended to generate 208 5 8 dot character fonts and 32 5 10 dot character
fonts for a total of 240 different character fonts.The low power supply (2.7V to 5.5V) of the
HD44780U is suitable for any portable battery-driven product requiring low power dissipation.
FEATURES
5 8 and 5 10 dot matrix possible
Low power operation support:
2.7 to 5.5V
Wide range of liquid crystal display driver power
3.0 to 11V
Liquid crystal drive waveform
-
8/4/2019 Smart Card Synopsis
29/74
A (One line frequency AC waveform)
Correspond to high speed MPU bus interface
2 MHz (when VCC = 5V)
4-bit or 8-bit MPU interface enabled
80 8-bit display RAM (80 characters max.)
9,920-bit character generator ROM for a total of 240 character fonts
208 character fonts (5 8 dot)
32 character fonts (5 10 dot)
REGISTER
The HD44780U has two 8-bit registers, an instruction register (IR) and a data register (DR). The
IR stores instruction codes, such as display clear and cursor shift, and address information for
display data RAM (DDRAM) and character generator RAM (CGRAM). The IR can only be
written from the MPU. The DR temporarily stores data to be written into DDRAM or CGRAM
and temporarily stores data to be read from DDRAM or CGRAM. Data written into the DR from
the MPU is automatically written into DDRAM or CGRAM by an internal operation. The DR is
-
8/4/2019 Smart Card Synopsis
30/74
also used for data storage when reading data from DDRAM or CGRAM. When address
information is written into the IR, data is read and then stored into the DR from DDRAM or
CGRAM by an internal operation. Data transfer between the MPU is then completed when the
MPU reads the DR. After the read, data in DDRAM or CGRAM at the next address is sent to the
DR for the next read from the MPU. By the register selector (RS) signal, these two registers can
be selected .
BUSY FLAG (BF)
When the busy flag is 1, the HD44780U is in the internal operation mode, and the next
instruction will not be accepted. When RS = 0 and R/W = 1 (Table 1), the busy flag is output to
DB7. The next instruction must be written after ensuring that the busy flag is 0.
ADDRESS COUNTER (AC)
The address counter (AC) assigns addresses to both DDRAM and CGRAM. When an address of
an instruction is written into the IR, the address information is sent from the IR to the AC.
Selection of either DDRAM or CGRAM is also determined concurrently by the instruction.
After writing into (reading from) DDRAM or CGRAM, the AC is automatically
DISPLAY DATA RAM (DDRAM)
Display data RAM (DDRAM) stores display data represented in 8-bit character codes. Its
extended capacity is 80 8 bits, or 80 characters. The area in display data RAM (DDRAM) that
is not used for display can be used as general data RAM. See Figure 1 for the relationships
between DDRAM addresses and positions on the liquid crystal display. The DDRAM address
(ADD) is set in the address counter (AC) as hexadecimal.
CHARATER GENERATOR ROM (CGROM)
The character generator ROM generates 5 8 dot or 5 10 dot character patterns from 8-bit
character codes It can generate 208 5 8 dot character patterns and 32 5 10 dot character
patterns. Userdefined character patterns are also available by mask-programmed ROM.
CHARACTER GENERATOR RAM (CGRAM)
In the character generator RAM, the user can rewrite character patterns by program. For 5 8
dots, eight character patterns can be written, and for 5 10 dots, four character patterns can be
-
8/4/2019 Smart Card Synopsis
31/74
written. Write into DDRAM the character codes at the addresses shown as the left column of
character patterns stored in CGRAM. for the relationship between CGRAM addresses and data
and display patterns. Areas that are not used for display can be used as general data RAM.
MODIFYING CHARACTER PATTERNS
Character pattern development procedure
1. Determine the correspondence between character codes and character patterns.
2. Create a listing indicating the correspondence between EPROM addresses and data.
3. Program the character patterns into the EPROM.
4. Send the EPROM to Hitachi.
5. Computer processing on the EPROM is performed at Hitachi to create a character pattern
listing, which is sent to the user.
6. If there are no problems within the character pattern listing, a trial LSI is created at Hitachi
and samples are sent to the user for evaluation. When it is confirmed by the user that the
character patterns are correctly written.
TIMING GENERATION CIRCUIT:-
The timing generation circuit generates timing signals for the operation of internal circuits such
as DDRAM, CGROM and CGRAM. RAM read timing for display and internal operation timing
by MPU access are generated separately to avoid interfering with each other. Therefore, when
writing data to DDRAM, for example, there will be no undesirable interferences, such asflickering, in areas other than the display area.
Liquid Crystal Display Driver Circuit
The liquid crystal display driver circuit consists of 16 common signal drivers and 40 segment
signal drivers. When the character font and number of lines are selected by a program, the
required common signal drivers automatically output drive waveforms, while the other common
signal drivers continue to output non-selection waveforms. Sending serial data always starts at
the display data character pattern corresponding to the last address of the display data RAM
(DDRAM). Since serial data is latched when the display data character pattern corresponding to
the starting address enters the internal shift register, the HD44780U drives from the head display.
Cursor/Blink Control Circuit
-
8/4/2019 Smart Card Synopsis
32/74
The cursor/blink control circuit generates the cursor or character blinking. The cursor or the
blinking will appear with the digit located at the display data RAM (DDRAM) address set in the
address counter (AC).
Instruction Description
Clear Display
Clear display writes space code 20H (character pattern for character code 20H must be a blank
pattern) into all DDRAM addresses. It then sets DDRAM address 0 into the address counter, and
returns the display to its original status if it was shifted. In other words, the display disappears
and the cursor or blinking goes to the left edge of the display (in the first line if 2 lines are
displayed). It also sets I/D to 1 (increment mode) in entry mode. S of entry mode does not
change
Return Home
Return home sets DDRAM address 0 into the address counter, and returns the display to its
original status if it was shifted. The DDRAM contents do not change. The cursor or blinking go
to the left edge of the display (in the first line if 2 lines are displayed).
Entry Mode Set
I/D: Increments (I/D = 1) or decrements (I/D = 0) the DDRAM address by 1 when a character
code is written into or read from DDRAM.The cursor or blinking moves to the right when
incremented by 1 and to the left when decremented by 1. The same applies to writing and
reading of CGRAM.
S: Shifts the entire display either to the right (I/D = 0) or to the left (I/D = 1) when S is 1. The
display does not shift if S is 0. If S is 1, it will seem as if the cursor does not move but the
display does. The display does not shift when reading from DDRAM. Also, writing into or
reading out from CGRAM does not shift the display.
Display On/Off Control
D: The display is on when D is 1 and off when D is 0. When off, the display data remains in
DDRAM, but can be displayed instantly by setting D to 1.
C: The cursor is displayed when C is 1 and not displayed when C is 0. Even if the cursor
disappears, the function of I/D or other specifications will not change during display data write.
The cursor is displayed using 5 dots in the 8th line for 5 8 dot character font selection and in the
11th line for the 5 10 dot character font selection (Figure 13).
-
8/4/2019 Smart Card Synopsis
33/74
B: The character indicated by the cursor blinks when B is 1 (Figure 13). The blinking is
displayed as switching between all blank dots and displayed characters at a speed of 409.6-ms
intervals when fcp or Fosc is 250 kHz. The cursor and blinking can be set to display
simultaneously. (The blinking frequency changes according to fOSC or the reciprocal of fcp. For
example, when fcp is 270 kHz, 409.6 250/270 = 379.2 ms
Instruction and Display Correspondence
It can store data for 80 characters, as explained before, the RAM can be used for displays such as
for advertising when combined with the display shift operation. Since the display shift operation
changes only the display position with DDRAM contents unchanged, the first display data
entered into DDRAM can be output when the return home operation is performed.
The program must set all functions prior to the 4-bit operation (Table 12). When the power is
turned on, 8-bit operation is automatically selected and the first write is performed as an 8-bit
operation. Since DB0 to DB3 are not connected, a rewrite is then required. However, since one
operation is completed in two accesses for 4-bit operation, a rewrite is needed to set the
functions). Thus, DB4 to DB7 of the function set instruction is written twice. Thus, if there are
only 8 characters in the first line, the DDRAM address must be again set after the 8th character is
completedNote that the display shift operation is performed for the first and second lines. In the
example of the display shift is performed when the cursor is on the second line. However, if the
shift operation is performed when the cursor is on the first line, both the first and second lines
move together. If the shift is repeated, the display of the second line will not move to the first
line. The same display will only shift within its own line for the number of times the shift is
repeated.: When using the internal reset, the electrical characteristics in the Power Supply
Conditions Usin Internal Reset Circuit table must be satisfied.
SENSORS (MOC 7811)
The infrared reflectance sensor is a small rectangular device that contains a phototransistor(sensitive to infrared light) and an infrared emitter. The amount of light reflected from the
emitter into the phototransistor yields a measurement of a surface's reflectance, for example, to
determine whether the surface is black or white. The phototransistor has peak sensitivity at the
wavelength of the emitter (a near-visible infrared), but is also sensitive to visible light and
-
8/4/2019 Smart Card Synopsis
34/74
infrared light emitted by visible light sources. For this reason, the device should be shielded from
ambient lighting as much as possible in order to obtain reliable results.
Magnetic field sensorsThe KMZ range of magnetoresistive sensors is characterized by high sensitivity in thedetection of magnetic fields, a wide operating temperature range, a low and stable offset andlow sensitivity to mechanical stress. They therefore provide an excellent means of measuringboth linear and angular displacement under extreme environmental conditions, because theirvery high
sensitivity means that a fairly small movement of actuating
components in, for
example, cars or machinery (gear wheels, metal rods, cogs, cams, etc.) can create measurablechanges in magnetic field. Other applications for magnetoresistive sensors include rotationalspeedmeasurement and current measurement.Examples where their properties can be put to good effect can be found in automotive
applications, such as wheel speed sensors for ABS and motor management systems and position
sensors for chassis position, throttle and pedal position measurement. Other examples include
instrumentation and control equipment, which often require position sensors capable of detecting
displacements in the region of tenths of a millimetre (or even less), and in electronic ignition
systems, which must be able to determine the angular position of an internal combustion engine
with great accuracy. Finally, because of their high sensitivity, magnetoresistive sensors can
measure very weak magnetic fields and are thus ideal for application in electronic compasses,
earth field correction and traffic detection. If the KMZ sensors are to be used to maximum
-
8/4/2019 Smart Card Synopsis
35/74
advantage, however, it is important to have a clear understanding of their operating principles
and characteristics, and how their behaviour may be affected by external influences and by their
magnetic history.
OPERATING PRINCIPLES
Magnetoresistive (MR) sensors make use of the magnetoresistive effect, the property of a
current-carrying magnetic material to change its resistivity in the presence of an external
magnetic field Assume that, when no external magnetic field is present, the permalloy has an
internal magnetization vector parallel to the current flow (shown to flow through the permalloy
from left to right). If an external magnetic field H is applied, parallel to the plane of the
permalloy but perpendicular to the current flow, the internal magnetization vector of the
permalloy will rotate around an angle a. As a result, the resistance of R of the permalloy will Ro
and DRo are material parameters and to achieve optimum sensor characteristics this material,
DRo is of the order of 3.In this basic form, the MR effect can be used effectively for angular
measurement and some rotational speed measurements, which do not require linearization of the
sensor characteristic. In the KMZ series of sensors, four permalloy strips are arranged in a
meander fashion on the silicon (Fig.4 shows one example, of the pattern on a KMZ10). They are
connected in a Wheatstone bridge configuration, which has a number of advantages: Reduction
of temperature drift .
It smoothes the rectified signal so that a single continuous output signal is generated. As long asa compensation coil is used, it is recommended that this filter is also used, to ensure stable
operation. If compensation is not used, then it is possible to use less expensive components. This
block, as well as the rectifier Block 4 can even be omitted entirely if, for example, the output
signal is then passed to a microcontroller which can easily perform the rectification and
smoothing, especially if it is also being used to generate the flipping frequency. The components
in Block 6 drive the compensation coil and ensure that Vout is proportional to the compensation
current. If the application does not need the highest accuracy, reduced circuit complexity can be
used.
-
8/4/2019 Smart Card Synopsis
36/74
APPLICATIONS
The amount of light reflected from the emitter into the phototransistor yields a measurement of a
surface's reflectance (when other factors, such as the distance from the sensor to the surface, are
held constant). The reflectance sensor can also be used to measure distance, provided that the
surface reflectance is constant. A reflectance sensor can be used to detect features drawn on a
surface or segments on a wheel used to encode rotations of a shaft. It is important to remember
that the reflectivity measurement indicates the surface's reflectivity at a particular wavelength of
light (the near-visible infrared). A surface's properties with respect to visible light may or maynot be indicators of infrared light reflectance. In general, though, surfaces that absorb visible
light (making them appear dark to the eye) will absorb infrared light as well.
D.C MOTOR
-
8/4/2019 Smart Card Synopsis
37/74
An electric motor uses electrical enrgy to produce mechanical energy, nearly always by the
interaction of magnetic fields and curent- carrying conductors. The reverse process, that of using
mechanical energy to produce electrical energy, is accomplished by a generator or dynamo.
Traction motors used on vehicles often perform both tasks.
Electric motors are found in a myriad of uses such as industrial fans, blowers and pumps,
machine tools, household appliances, power tools, and computer disk drives, among many other
applications.
Nearly all motors exploit the force which is exerted on a current carrying conductor placed in
magnetic field. This phenomenon is often demonstrated in classroom experiments where a bar
magnet is placed near a wire carrying current, and the resultant force can be seen to distort the
-
8/4/2019 Smart Card Synopsis
38/74
shape of the wire. Unfortunately, the force generated in such an experiment is miniscule and
could hardly be used to do any useful mechanical work. In order to make a useful electric motor
we need to arrange for there to be a strong magnetic field and for it to interact with many
conductors, each carrying as much current as possible. The component parts of a motor are
designed so that interaction of currents and magnetic fields produces a continuous, smooth
rotational movement. A brushed DC motor is the simplest of all motor types, and typically
consists of the following parts; Stator. The stationary part of the motor in which the rotor
revolves. The stator typically takes the form of a metal can, open at one end, with two or more
curved magnets mounted inside it.
The stator housing often doubles up as the housing for the motor as a whole.The rotating part of
the motor, mounted axially in the centre of the stator housing. The motor windings are wound on
the rotor. A series of electromechanical contacts which enable current to flow to the rotating
motor windings in the correct sequence and direction. The stationary brushes make electrical
contact with part of the rotor known as the commutator. This arrangement creates the correct
sequence of current through the motor coils as the rotor rotates.The commutator is usually in the
form of a cylinder, consisting of segments of conducting material interspersed with, and
insulated from one another by, an insulating material. Current flow is in through the left hand
-
8/4/2019 Smart Card Synopsis
39/74
brushand out through the right hand brush, and is indicated by the red arrows. If the rotation is
clockwise, it can beseen that one sixth of a revolution after the instant shown, the current in coils
A and D will have changeddirections. As successive commutator segments pass under the
brushes, their current directions will also change. This rotating magnetic field interacts with
the stationary field generated by the stator magnets, and the result is continuous rotational
motion produced in the motors rotor.Assuming the motor is stationary before voltage is applied
to the terminals, when voltage is applied, Ewill be zero and hence Iwill be limited only by R
andL. As the motor builds up speed, Ebegins to increase, reducing the voltage across R andL
and hence also reducing I. If the motor windings were made of perfect conductors, with no
resistance, and the motor had zero friction in its bearings, then we would eventually reach a point
whereE = VandI = 0. All that would be required to keep the motor running in this condition
would be to maintain the voltage V at the motor terminals. Of course, real motors have both
winding resistance and friction in their bearings, so even in a no load condition, I is greater
than zero. Another way to look at this is to consider the motor as an energy conversion
mechanism where; electrical energy in = mechanical energy out + energy dissipated in bearings
and windings.
If we now apply some load to a motor running in a no load condition, the speed of the motor
will decrease. As a result, E will also decrease and hence I will increase. As I increases, the
motor speed increases again and soE increases. In this way, the motor will quickly reach an
equilibrium speed once more. Although this self regulation mechanism will go some way to
restoring the original motor speed under the new load condition, it cannot compensate for the
voltage dropped across (and power dissipated in) the motor winding resistance.
Hence we see the motor speed drop with increasing load. Motors with higher winding resistance
will tend to have worse speed regulation under load, as well as being less efficient dissipating
more power and running hotter for a given output power
MOTOR DRIVER
-
8/4/2019 Smart Card Synopsis
40/74
L293D is a dual H-Bridge motor driver, So with one IC we can interface two DC motors which
can be controlled in both clockwise and counter clockwise direction and if you have motor with
fix direction of motion the you can make use of all the four I/Os to connect up to four DC
motors. L293D has output current of 600mA and peak output current of 1.2A per channel.
Moreover for protection of circuit from back EMF ouput diodes are included within the IC. The
output supply (VCC2) has a wide range from 4.5V to 36V, which has made L293D a best choice
for DC motor driver.
As you can see in the circuit, three pins are needed for interfacing a DC motor (A, B, Enable). If
you want the o/p to be enabled completely then you can connect Enable to VCC and only 2 pins
needed from controller to make the motor work.
As per the truth mentioned in the image above its fairly simple to program the microcontroller.
Its also clear from the truth table of BJT circuit and L293D the programming will be same for
both of them, just keeping in mind the allowed combinations of A and B. We will discuss about
programming in C as well as assembly for running motor with the help of a microcontroller.
DESCRIPTION
The Device is a monolithic integrated high voltage, high current four channel driver designed to
accept standard DTL or TTL logic levels and drive inductive loads (such as relays solenoides,
DC and stepping motors) and switching power transistors. To simplify use as two bridges each
pair of channels is equipped with an enable input. A separate supply input is provided for the
logic, allowing operation at a lower voltage and internal clamp diodes are included. This device
-
8/4/2019 Smart Card Synopsis
41/74
is suitable for use in switching applications at frequencies up to 5 kHz. The L293D is assembled
in a 16 lead plastic packaage which has 4 center pins connected together and used for heatsinking
The L293DD is assembled in a 20 lead surface mount which has 8 center pins connected together
and used for heatsinking.
CIRCUIT OPERATION
The L297 is intended for use with a dual bridge driver, quad darlington array or discrete power
devices in step motor driving applications. It receives step clock, direction and mode signals
from the systems controller (usually a microcomputer chip) and generates control signals for the
power stage. The principal functionsare a translator,which generates the motor phase sequences,
and a dual PWMchopper circuit which regulates the current in the motor windings.The translator
generatesthree different sequences, selected by the HALF/FULL input. These are normal (two
phases energised), wave drive (one phase energised) and half-step (alternately one phase
energised/two phases energised). Two inhibit signals are also generated by the L297 in half step
and wavedrive modes.These signals, whichconnect directly to the L298senable inputs, are
intended to speed current decay when a winding is de-energised.When the L297 is used to drive
a unipolarmotor the chopper acts on these lines. An input calledCONTROL determines whether
the chopper will act on the phase lines ABCD or the inhibit lines INH1 and INH2.When the
phase lines are choppedthe non-activephase line of each pair (AB or CD)is activated(ratherthan
interrupting the line then active).In L297 + L298 configurationsthis technique reduces dissipation
in the load current sense resistors. A common on-chip oscillator drives the dual chopper. It
suppliespulses at the chopper rate which set the two flip-flops FF1 and FF2.Whenthe current in a
winding reaches the programmed peakvalue the voltage across the sense resistor (connected to
one of the sense inputs SENS1 or SENS2) equals Vref and the corresponding comparator resets
its flip flop, interrupting the drive current until the next oscillator pulse arrives. The peak current
for both windingsis programmedbya voltage divideron the Vref input. Ground noise problems in
multiple configurations can be avoided by synchronising the chopper oscillators. This is done by
connecting all the SYNC pins together, mounting the oscillator RC network on one device only
and grounding the OSC pin on all other devices.
-
8/4/2019 Smart Card Synopsis
42/74
SECTION- 5
PCB LAYOUT
-
8/4/2019 Smart Card Synopsis
43/74
-
8/4/2019 Smart Card Synopsis
44/74
Printed Circuit Board or PCB is used as support to electronic components by providing means of
connection between electronic devices. It uses trails and conduits that are imprinted into copper
sheets.The history and progression of the printed circuit board runs way back in 1930s but
became increasingly prolific throughout the 1940s and 1950s. As PCBs have become more
common, their structures and mechanics have changed, allowing for more dependability and
-
8/4/2019 Smart Card Synopsis
45/74
usability. Today, PCBs are widely used in almost all modern electronic devices and equipments
as they provide a relatively economical and efficient method of electronic data printing that are
most suitable to companies with elevated volume and data needs.Printed Circuit Boards are now
constructed using thin layers of copper, coated in a nonconductive layer of glass fibers mixed
with other materials.
STEP1 - CHOOSINGAND INCORPORATING SOFTWARE
There are many types of software and manufacturing tools available for creating and printing a
PCB image. Printed circuit board software works to create an image that will aid a technician in
successfully transferring and printing a plan onto a PCB. This software is used throughout the
printing and etching process to ensure these procedures are done correctly. A company that
prints and creates PCB will have to look for the best tools available in order to create quality
PCBs at high volumes and rates. Software incorporation and options however, depends on the
customers needs and requirements, as well as their financial capacity.
STEP2:- DESIGNING THE PCB STRUCTURE:-
The layout of a PCB image is formed by the creation of various mechanisms of the PCB and
linking of each mechanism. This process requires supervision from a technician to ensure proper
software use and performance.
STEP 3 :-CREATING THE PCB MECHANISMS AND STRUCTURE
Once the plan has been determined, each element of the PCB must be planned and drawn into the
copper sheets through either additive or subtractive method. In the subtractive method, the image
can be created using a variety of inks to imprint the image into the copper and removing the
excess and unnecessary copper once it was finalized. This can also be done by simply using the
PCB machinery. On the other hand, additive method uses printed layer of the image and add
copper that is later removed in the etching process.
Step 4DETERMINIG THE PCB FORM
-
8/4/2019 Smart Card Synopsis
46/74
The printed circuit boards parameters and components should be properly measured and applied
in order to ensure proper PCB imaging and set-up. Any mistake on this level of design and
production can cause significant problems in the PCB.
STEP 5 - ENSURING RULES OF STRUCTURE AND CREATION
See to it that that every part of the PCB image is placed and attached correctly with every other
part. At this stage, the PCB software should have been successful in its imaging and application.
STEP 6 LOCATING AND POSITIONING DESING PARTS
This process can be very time-consuming, but PCB software and mechanisms work to streamline
it. With the copper printed and properly placed, etching is done to remove excess copper and fix
the impression. Then, the copper and board are connected and a layer of tin or lead is used tooverlay the PCB, thus allowing etching to occur. Depending on its complexity, PCB layers can
be molded together by placing small holes using high-performance drills. This allows the printed
circuit boards conductivity and performance efficiency.
STEP 7 - ROUTING PCB TRACES
Once the process of determining and creating the printed circuit board is complete, it is
necessary to test each route and connection. This process is completed by using high-level
computer software and voltage that help technicians work through the board to ensure that the
electronic traces are working properly and efficiently
STEP 8USING AUTOROUTING APPLICATION
Autorouting is more helpful compared to manual routing. This enables the technicians to
accurately pinpoint trace errors or changes. Autorouting softwares now come in many varieties
and are constantly improving. Its many options allows better organization of the process.
STEP 9 - CHECKING RULES OF CREATION AND INCOPORATION
The printed circuit board is now ready to be analyzed and tested by computer software. This
software checks the image and reports faulty aspects.
-
8/4/2019 Smart Card Synopsis
47/74
Step 10 - Using Gerber Files
The process of creating and manufacturing printed circuit boards can be both time-consuming
and extensive. The details and specifications in the manufacturing process should all be entered
and compiled into the Gerber Files as this can be used by the manufacturing company for furtherPCB creation. For companies with high-volume needs, using a trusted and reliable PCB
production company can make the process much easier and cost-efficient.
-
8/4/2019 Smart Card Synopsis
48/74
SECTION-6
WORKING OF PROJECT
WORKING
It is a system which can be used where accessing of door or any other electrical device, can be
open using a smart card on inserting the card users data is being read by the micro controller
-
8/4/2019 Smart Card Synopsis
49/74
which will process the data the card is an EPROM IC where we can store the data in that there
where quick updating, quick record database generator for the person using for and where few
organization cant work efficiently like post, telegraph, telephone. Manual handling required for
telephone.
The smart card is one of the latest additions to the world of information technology. Similar in
size to today's plastic payment card, the smart card has a microprocessor or memory chip
embedded in it that, when coupled with a reader, has the processing power to serve many
different applications. As an access-control device, smart cards make personal and business data
available only to the appropriate users. Another application provides users with the ability to
make a purchase or exchange value. Smart cards provide data portability, security and
convenience. We use a system that is called smart card connectivity which has the following
features.
Analysis, computation, decision making is easier & faster: Space constraints sensitive to
environmental condition computer literates are required to operate. We have developed a system,
which can use for remote sites or area.
The EEPROM (memory) on the smart card is there for security. The host computer and card
reader actually "talk" to the EEPROM. The EEPROM enforces access to the data on the card. If
the host computer read and wrote the smart card's random access memory (RAM), it would be no
different than a diskette.
Smarts cards may have up to 512 kilobytes of EEPROM. The smart card uses a serial interface
and receives its power from external sources like a card reader. The processor uses a limited
instruction set for applications such as cryptography.
Smart cards can be used with a smart-card reader attachment to a personal computer to
authenticate a user. Web browsers also can use smart card technology to supplement Secure
Sockets Layer (SSL) for improved security of Internet transactions. Visa's Smart Card FAQ
shows how online purchases work using a smart card and a PC equipped with a smart-card
reader. Smart-card readers can also be found in mobile phones and vending machines.
Working
with ROMs and EPROMs can be a wasteful business. Even though they are inexpensive per
chip, the cost can add up over time. Erasable programmable read-only memory (EPROM)
addresses this issue. EPROM chips can be rewritten many times. Erasing an EPROM requires a
special tool that emits a certain frequency of ultraviolet (UV) light. EPROMs are configured
-
8/4/2019 Smart Card Synopsis
50/74
using an EPROM programmer that provides voltage at specified levels depending on the type of
EPROM used. In the smart card we used a two-wire serial EEPROM AT24C04 is used in the
circuit to store the user code, as the memory ensures reading of the latest saved settings by the
micro controller. This 12C bus-compatible- 2048-bit (2-kbit) EEPROM is organized as 256x8
bits. It can retain data for more than ten years.
The smart card is a microcontroller-based card and has 32 kilobytes (KB) of memory, of which
22 KB will be used for four kinds of information:
Personal information, including the card serial number, date of issue and cardholders name,
gender, date of birth, ID number, and picture.
NHI-related information, including cardholder status, remarks for catastrophic diseases,
number of visits and admissions, use of NHI health prevention programs, cardholders
premium records, accumulated medical expenditure records and amount of cost-sharing.
Medical service information, including drug allergy history and long-term prescriptions of
ambulatory care and certain medical treatments. This information is planned to be gradually
added depending on how health care providers adapt to the system.
Public health administration information (such as the cardholders personal immunization
chart and instructions for organ donation).
The Taiwanese government has reserved the other 10 KB of memory for future use.
Moving to the smart card system has resulted in the following changes:
Hospitals and clinics upload electronic records daily to BNHI.
After every six patient visits, card iinformation is uploaded online for data analysis, audit, and
authentication.
The reimbursement process is faster
-
8/4/2019 Smart Card Synopsis
51/74
SECTION 7
PROGRAMMING OF PROJECT
;HARDWARE DECLARATION
LCDPORT EQU P0
LCDCD EQU P2.4
LCDE EQU P2.5
ROW0 EQU P1.0
ROW1 EQU P1.1
ROW2 EQU P1.2
ROW3 EQU P1.3
COL0 EQU P1.5
COL1 EQU P1.6
COL2 EQU P1.7
SENSOR1 EQU P3.2
SENSOR2 EQU P3.3
SENSOR3 EQU P3.4
-
8/4/2019 Smart Card Synopsis
52/74
DCM1 EQU P3.6
DCM2 EQU P3.7
;RAM DECLARATION
KEYPRESS EQU 34H
UNIT EQU 30H
TEN EQU 31H
HUND EQU 32H
THSND EQU 33H
FLAG BIT 00H
FLAG1 BIT 01H
;BIT DECLARATION
STACKVAL EQU 70H
;START OF MAIN PROGRAM
;INTERRUPT VECTOR TABLE
ORG 0000H
LJMP POWERON
ORG 0003H;EXT INT0
RETI
ORG 000BH;TIMER0
RETI
ORG 0013H;EXT INT1
RETI
ORG 001BH;TIMER1
RETI
ORG 0023H;SERIAL
-
8/4/2019 Smart Card Synopsis
53/74
RETI
ORG 002BH;TIMER2
RETI
ORG 0033H;
POWERON:
MOV SP,#STACKVAL
MOV P0,#0FFH
MOV P1,#0FFH
MOV P2,#0FFH
MOV P3,#0FFH
MOV IE,#00H
MOV IP,#00H
MOV KEYPRESS,#0FFH
MOV UNIT,#00H
MOV TEN,#00H
MOV HUND,#00H
MOV THSND,#00H
CLR FLAG
CLR FLAG1
ACALL SECDELAY
ACALL SECDELAY
MOV A,#01H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV A,#02H
ACALL SENDLCDCMD
-
8/4/2019 Smart Card Synopsis
54/74
ACALL SECDELAY
MOV A,#28H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV A,#28H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV A,#28H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV A,#0FH
ACALL SENDLCDCMD
ACALL SECDELAY
MOV A,#06H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV A,#02H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV A,#01H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV R0,00H
-
8/4/2019 Smart Card Synopsis
55/74
MOV DPTR,#CODETABLE3
WELCOME: MOV A,R0
MOVC A,@A+DPTR
ACALL SENDLCDDATA
INC R0
CJNE R0,#07,WELCOME
ACALL SECDELAY
MOV A,#02H
ACALL SENDLCDCMD
ACALL SECDELAY
MOV R0,00H
MOV DPTR,#CODETABLE4
PASSWORD: MOV A,R0
MOVC A,@A+DPTR
ACALL SENDLCDDATA
INC R0
CJNE R0,#14,PASSWORD
ACALL SECDELAY
MOV A,#02H
ACALL SENDLCDCMD
ACALL SECDELAY
MAINLOOP:
JB FLAG,NEXT
-
8/4/2019 Smart Card Synopsis
56/74
ACALL KEYCHECK
ACALL KEYACTION
SJMP MAINLOOP
NEXT:
ACALL CARDDETECT
SJMP MAINLOOP
KEYCHECK:SETB COL1
SETB COL2
SETB COL0
CLR COL0
JNB ROW0,KEY1
JNB ROW1,KEY4
JNB ROW2,KEY7
JNB ROW3,KEYA
SETB COL0
CLR COL1
JNB ROW0,KEY2
JNB ROW1,KEY5
JNB ROW2,KEY8
JNB ROW3,KEYB
SETB COL1
CLR COL2
JNB ROW0,KEY3
-
8/4/2019 Smart Card Synopsis
57/74
JNB ROW1,KEY6
JNB ROW2,KEY9
JNB ROW3,KEYC
SETB COL2
MOV KEYPRESS,#0FFH
RET
KEY1: MOV KEYPRESS,#01H
RET
KEY4: MOV KEYPRESS,#04H
RET
KEY7: MOV KEYPRESS,#07H
RET
KEYA: MOV KEYPRESS,#0AH
RET
KEY2: MOV KEYPRESS,#02H
RET
KEY5: MOV KEYPRESS,#05H
RET
KEY8: MOV KEYPRESS,#08H
RET
KEYB: MOV KEYPRESS,#0BH
-
8/4/2019 Smart Card Synopsis
58/74
RET
KEY3: MOV KEYPRESS,#03H
RET
KEY6: MOV KEYPRESS,#06H
RET
KEY9: MOV KEYPRESS,#09H
RET
KEYC: MOV KEYPRESS,#0CH
RET
KEYACTION:
MOV A,KEYPRESS
CJNE A,#0FFH,ENTER
CLR FLAG
CLR FLAG1
RET
ENTER:
CJNE A,#05H,SHIFT
ACALL COMPARE
RET
SHIFT: MOV R0,#00H
-
8/4/2019 Smart Card Synopsis
59/74
MOV DPTR,#CODETABLE
JB FLAG,L2
SETB FLAG
MOV THSND,HUND
MOV HUND,TEN
MOV TEN,UNIT
MOV UNIT,KEYPRESS
MOV A,KEYPRESS
MOVC A,@A+DPTR
ACALL SENDLCDDATA
RET
L2:
RET
COMPARE:JB FLAG1,L2
SETB FLAG1
MOV A,UNIT
CJNE A,#01,FAIL
MOV A,TEN
CJNE A,#01,FAIL
MOV A,HUND
CJNE A,#01,FAIL
MOV A,THSND
CJNE A,#01,FAIL
ACALL PASS
-
8/4/2019 Smart Card Synopsis
60/74
RET
FAIL: MOV UNIT,#14
MOV TEN,#15
MOV HUND,#16
MOV THSND,#17
ACALL DISPLAY1
LJMP POWERON
RET
PASS: MOV UNIT,#10
MOV TEN,#11
MOV HUND,#12
MOV THSND,#13
ACALL DISPLAY1
SETB FLAG
RET
CARDDETECT:
JNB SENSOR1,CARDDENY
JNB SENSOR3,CARDDENY
JB SENSOR2,GORET
SETB DCM1
CLR DCM2
ACALL CARDACCEPT
GORET: RET
-
8/4/2019 Smart Card Synopsis
61/74
CARDACCEPT:
MOV DPTR,#CODETABLE1
MOV R0,#00H
LABEL: MOV A,R0
MOVC A,@A+DPTR
ACALL SENDLCDDATA
INC R0
CJNE R0,#13,LABEL
ACALL SECDELAY
RET
CARDDENY: MOV DPTR,#CODETABLE2
MOV R0,#00H
LABEL1: MOV A,R0
MOVC A,@A+DPTR
ACALL SENDLCDDATA
INC R0
CJNE R0,#09,LABEL1
ACALL SECDELAY
RET
SENDLCDCMD: CLR LCDCD
ACALL SECDELAY
MOV LCDPORT,A
ACALL SECDELAY
SETB LCDE
ACALL SECDELAY
CLR LCDE
-
8/4/2019 Smart Card Synopsis
62/74
ACALL SECDELAY
SWAP A
MOV LCDPORT,A
ACALL SECDELAY
SETB LCDE
ACALL SECDELAY
CLR LCDE
ACALL SECDELAY
SETB LCDCD
RET
SENDLCDDATA:SETB LCDCD
ACALL SECDELAY
MOV LCDPORT,A
ACALL SECDELAY
SETB LCDE
ACALL SECDELAY
CLR LCDE
ACALL SECDELAY
SWAP A
MOV LCDPORT,A
ACALL SECDELAY
SETB LCDE
ACALL SECDELAY
CLR LCDE
ACALL SECDELAY
CLR LCDCD
RET
-
8/4/2019 Smart Card Synopsis
63/74
DISPLAY:MOV A,UNIT
MOVC A,@A+DPTR
ACALL SENDLCDDATA
ACALL SECDELAY
DISPLAY1:MOV A,UNIT
MOVC A,@A+DPTR
ACALL SENDLCDDATA
ACALL SECDELAY
MOV A,TEN
MOVC A,@A+DPTR
ACALL SENDLCDDATA
ACALL SECDELAY
MOV A,HUND
MOVC A,@A+DPTR
ACALL SENDLCDDATA
ACALL SECDELAY
MOV A,THSND
MOVC A,@A+DPTR
ACALL SENDLCDDATA
ACALL SECDELAY
RET
-
8/4/2019 Smart Card Synopsis
64/74
SECDELAY: MOV R7,#10
LOOP2: MOV R6,#20
LOOP1: MOV R5,#100
LOOP0: DJNZ R5,LOOP0
DJNZ R6,LOOP1
DJNZ R7,LOOP2
RET
CODETABLE:DB '0123456789PASSFAIL'
CODETABLE1:DB 'CARD ACCEPT'
CODETABLE2:DB 'CARD DENY'
CODETABLE3:DB 'WELCOME'
CODETABLE4:DB 'ENTER PASSWORD'
-
8/4/2019 Smart Card Synopsis
65/74
SECTION 8:-
SNAPSHOT OF PROJECT
-
8/4/2019 Smart Card Synopsis
66/74
-
8/4/2019 Smart Card Synopsis
67/74
-
8/4/2019 Smart Card Synopsis
68/74
-
8/4/2019 Smart Card Synopsis
69/74
SECTION 8:-
APPLICATION & SCOPE
The most common smart card applications are:-
1. CREDIT CARD
A credit card, such as VISA or MasterCard, allows you to pay for sales or services by borrowing
against your line of credit with the credit card company and to make monthly payments on the
outstanding balance. A charge card, such as American Express requires payment in full each
-
8/4/2019 Smart Card Synopsis
70/74
month of the outstanding balance charged to the account.They allow you to make purchases on
credit without carrying around a lot of cash. They allow accurate record-keeping by
consolidating purchases into a single statement. They allow convenient ordering by mail or
phone. They allow you to pay for large purchases in small, monthly installments. Under certain
circumstances, they allow you to withhold payment for merchandise which proves defective.
When you have been issued a credit card you are given a line of credit. You can make purchases
or receive cash advances up to that amount with your card. When you make a purchase, the
merchant gives proof of your purchase to the credit card company and they pay the merchant on
your behalf; in effect granting you a loan. The credit card issuer then bills you for reimbursement
of the purchase or cash advance amount. You can either pay the balance in full or make
payments. The issuer must send you periodic billing statements giving you information on your
account which includes the minimum payment due, date it is due, and the periodic interest rate
on unpaid balances.Federal law protects consumers when they use credit cards.
Errors on Your Bill. There are specific rules that the card issuer must follow for promptly
correcting billing errors. The issuer must furnish you a statement describing the rules when you
open a credit card account and at least once a year after that.
2. ELECTRONIC CASH
'Electronic Cash' is the debit card system of the German Central Credit Committee, theassociation which represents the top German financial interest groups. Usually paired with a
checking account, cards with an Electronic Cash logo are only handed out by proper credit
institutions. An electronic card payment is generally made by the card owner entering their PIN
(Personal Identification Number) at a so-called EFT-POS-terminal (Electronic-Funds-Transfer-
Terminal). The name EC originally comes from the unified European checking system
Eurocheque. Comparable debit card systems are Maestro and Visa Electron. Banks and credit
institutions who issue these cards often pair EC debit cards with Maestro functionality.
These combined cards, recognizable by an additional Maestro logo, are referred to as
EC/Maestro cards.Contents All card terminals working with the electronic cash system have to
be certified by the ZKA (the German Central Credit Committee) in order to take part in cashless
payment transactions. Terminals working exclusively with EDD do not require a ZKA
-
8/4/2019 Smart Card Synopsis
71/74
certificate. Operating a card terminal requires a provider contract with the network operator. The
data collected by the terminal is processed by the provider. For the time the terminal is in use the
user (for example, the retailer) can contact the service provider. He can call a hotline and is
guaranteed on-site technical support by a technician. He has a contact person who helps with
questions about the account, transaction control, managing the contract, etc.
3. ATM SECURITY SYSTEM
The drastic growth in the popularity of the Internet and in the use of communication between
computers makes the subject of computer security very relevant. The reasons behind hacking keep
changing. If once hackers had broken into computers in order to satisfy their curiosity and pump up their
ego, nowadays more and more hackings are intended to steal information or damage systems for
purposes of profit or revenge. Many times our basic lack of knowledge of the dangers that lie in the
network, such as weak passwords or trusting any e-mail that reaches our mailbox, is what makes it
easier For hackers. Nowadays, the web is crawling with viruses, worms, Trojan horses and the like (all
the above mentioned concepts are explained below in our site) so that if your computer is not well
secured and you are falling behind on your updates, catching one of them is almost certain. To enter a
computer system, you probably should know the login command. Nearly all computers ask from the
user to supply correct password within limited number of tries.
4. WIRELESS COMMUNICATION
In telecommunications, wireless communication may be used to transfer information over short
distances (a few meters as in television remote control) or long distances (thousands or millions
of kilometers for radio communications). The term is often shortened to "wireless". It
encompasses various types of fixed, mobile, and portable two-way radios, cellular telephones,
personal digital assistants (PDAs), and wireless networking. Other examples of wireless
technology include GPS units, garage door openers and or garage doors, wireless computer mice,
keyboards and headsets, satellite television and cordless telephones Wireless operations permits
-
8/4/2019 Smart Card Synopsis
72/74
services, such as long range communications, that are impossible or impractical to implement
with the use of wires. The term is commonly used in the telecommunications industry to refer to
telecommunications systems (e.g. radio transmitters and receivers, remote controls, computer
networks, network terminals, etc.) which use some form of energy (e.g. radio frequency (RF),
infrared light, laser light, visible light, acoustic energy, etc.) to transfer information without the
use of wires.[1] Information is transferred in this manner over both short and long distances.
.
5. SATELLITE TV
Early satellite TV viewers were explorers of sorts. They used their expensive S-Band, then C-
Band dishes to discover unique programming that wasnt necessarily intended for mass
audiences. The dish and receiving equipment gave viewers the tools to pick up foreign stations,
live feeds between different broadcast stations and a lot of other stuff transmitted using satellites.
Some satellite owners still seek out this sort of programming on their own, but today, most
satellite TV customers in developed television markets get their programming through a direct
broadcast satellite (DBS) provider, such as DISH TV or the recently launched Doordarshan DTH
platform. The provider selects programs and broadcasts them to subscribers as a set package.
Basically, the providers goal is to bring dozens or even hundreds of channels to the customers
television in a form that approximates the competition from Cable TV. Unlike earlier
programming, the providers broadcast is completely digital, which means it has high picture and
stereo sound quality.
-
8/4/2019 Smart Card Synopsis
73/74
SECTION 9:-
BIBLIOGRAPHY
Electronics devices and circuit by Sanjeev Gupta ,third edition, dhanpat rai
publications
Electronics devices and circuits by Robert.L.Boylested, ninth edition,pearson
publications.
www.howstuffwork.com
www.datasheetcatalogue.com
www.google.com
www.wikepedia.com
www.robust.com
http://www.howstuffwork.com/http://www.howstuffwork.com/http://www.datasheetcatalogue.com/http://www.datasheetcatalogue.com/http://www.google.com/http://www.google.com/http://www.wikepedia.com/http://www.wikepedia.com/http://www.robust.com/http://www.robust.com/http://www.robust.com/http://www.wikepedia.com/http://www.google.com/http://www.datasheetcatalogue.com/http://www.howstuffwork.com/ -
8/4/2019 Smart Card Synopsis
74/74
www.8051.com
http://www.robust.com/http://www.robust.com/http://www.8051.com/http://www.8051.com/http://www.8051.com/