Вы находитесь на странице: 1из 70

Finger Print Based Security System

1. INTRODUCTION
1.1 Objective
Nowadays accurate personal identification is becoming more and more important. Usual means (smart cards, passwords) have shown their limits (falsification, loss). Biometrics (i.e. analysis of personal biological characteristics) can bring a satisfying answer to those latter problems. Currently fingerprint recognition is the most widely used technique for personal identification. Fingerprints are made up of locally parallel ridges with singular points (minutiae), and they constitute a unique permanent universal pattern. The use of ink and paper to get an image from a finger was used for a long time, but technological advances have enabled to automate the acquisition stage by means of solid-state sensors. These sensors exploit different techniques to acquire the image (pressure, electrical field, temperature) and require a static (matrix sensor) or mobile finger position (sweeping mode sensor). Our project is developed to provide security for a Organization. In this project the fingerprint sensor sense the thumb impression of the corresponding person and that image will be compared with registered image, if the both images are unique, then the finger print device activates particular task like access control to a secured area, identification of the employee etc. The project contains 2 modes, the first one is master mode and the second is user mode. The master mode is used to register the new user and gives the mode of authorization. The master mode has the ability to create and delete the users. The user mode is an ordinary mode used for the authentication of the employees. In user mode of authorization, creation and deletion of a user cannot be performed. The Master mode operations are done directly through interfacing the FM10 (Finger Print Module) to the COM PORT of the computer. The application program is developed using java API in Swings. The Java communication API is used for communicating with the Fingerprint device. The employee details along with biometric information database is stored in the flash memory of the Fingerprint module. The Microcontroller 89S52 is programmed to operate under user mode. Microcontroller is programmed using C51 cross compiler. Fingerprint image is scanned by the fingerprint device. If the scanned image matches with the registered image then Microcontroller sends the authorized persons Id to the computer when the person enters and leaves the organization. By this daily attendance of employees, many employee records are maintained. The employee records are stored in the database.

Finger Print Based Security System

1.2 Principle of operation


When a finger is kept at the finger print reader, it will give the information accordingly to microcontroller by sending appropriate commands to the reader and which is displayed on the LCD. If the information matches with the one within the device then the DC motor interfaced to the microcontroller responds accordingly. And if the information provided by the user is incorrect or mismatch in finger prints is detected then access is denied. Finger print reader and the microcontroller unit are connected using serial interface.

Embedded Systems
Embedded System is a combination of hardware and software used to achieve a single specific task. An embedded system is a microcontroller-based, software driven, reliable, real-time control system, autonomous, or human or network interactive, operating on diverse physical variables and in diverse environments and sold into a competitive and cost conscious market. An embedded system is a special-purpose computer system designed to perform a dedicated function. Unlike a general-purpose computer, such as a personal computer, an embedded system performs one or a few pre-defined tasks, usually with very specific requirements, and often includes task-specific hardware and mechanical parts not usually found in a general-purpose computer. Since the system is dedicated to specific tasks, design engineers can optimize it, reducing the size and cost of the product. Embedded systems are often mass-produced, benefiting from economies of scale. Physically, embedded systems range from portable devices such as digital watches and MP3 players, to large stationary installations like traffic lights, factory controllers, or the systems controlling nuclear power plants. In terms of complexity embedded systems run from simple, with a single microcontroller chip, to very complex with multiple units, peripherals and networks mounted inside a large chassis or enclosure. Mobile phones or handheld computers share some elements with embedded systems, such as the operating systems and microprocessors which power them, but are not truly embedded systems themselves because they tend to be more general purpose, allowing different applications to be loaded and peripherals to be connected.

Finger Print Based Security System Examples of Embedded Systems An embedded system typically has a specialized function with programs stored on ROM. Examples of embedded systems are chips that monitor automobile functions, including engine controls, antilock brakes, air bags, active suspension systems, environmental systems, security systems, and entertainment systems. Everything needed for those functions is custom designed into specific chips. No external operating system is required. Network managers will need to manage more and more embedded systems devices, ranging from printers to scanners, to handheld computing devices, to cell phones. All of these have a need to connect with other devices, either directly or through a wireless or directconnect network. Most will have custom operating systems or variations of existing operating systems (e.g., Microsoft Windows CE). It's easy to picture nearly every electronic device as having an embedded system. For example, refrigerators, washing machines, and even coffee brewers will benefit in some way from embedded systems. A critical feature of an embedded system is its ability to communicate, so embedded systems support Ethernet, Bluetooth (wireless), infrared, or other technologies. A weather station on top of a building may employ an embedded system that gathers information from external sensors. This information can be pushed or pulled. In the push scenario, the data is automatically sent to devices that have requested it. In the pull scenario, users or network devices access the weather station to read the latest information.

Characteristics of Embedded System:


An embedded system is any computer system hidden inside a product other than a computer There will encounter a number of difficulties when writing embedded system software in addition to those we encounter when we write applications
1. Throughput Our system may need to handle a lot of data in a short period of

time.
2. ResponseOur system may need to react to events quickly 3. TestabilitySetting up equipment to test embedded software can be difficult

Finger Print Based Security System


4. DebugabilityWithout a screen or a keyboard, finding out what the software is

doing wrong (other than not working) is a troublesome problem


5.

Reliability embedded systems must be able to handle any situation without human intervention

6. Memory space Memory is limited on embedded systems, and you must make

the software and the data fit into whatever memory exists
7. Program installation you will need special tools to get your software into

embedded systems
8. Power consumption Portable systems must run on battery power, and the

software in these systems must conserve power


9. Processor hogs computing that requires large amounts of CPU time can

complicate the response problem


10. Cost Reducing the cost of the hardware is a concern in many embedded system

projects; software often operates on hardware that is barely adequate for the job.

Embedded systems have a microprocessor/ microcontroller and a memory. Some have a serial port or a network connection. They usually do not have keyboards, screens or disk drives.

1.3 Applications

Personal laptops and ATM Door lock system and Safe box Vehicles Industry

2. BLOCK DIAGRAM AND DESCRIPTION 2.1 Block Diagram

Finger Print Based Security System

Fig 2.1 Block Diagram

2.2 Block Diagram Description


The block diagram and its brief description are explained in block wise and this consists of following blocks MICROCONTROLLER FINGERPRINT MODULE RS-232 Cable, MAX-232. LCD (LIQUID CRYSTAL DISPLAY) POWER SUPPLY DC MOTOR

Microcontroller AT89S52
The major heart of this project is at89s52 microcontroller, the reasons why we selected this in our project?,. The AT89S52 provides the following standard features: 8K

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

Fingerprint module
Fingerprint module consists of f fingerprint sensor and scanning section.A fingerprint pattern is composed of a sequence of ridges and valleys. In a fingerprint image, the ridges appear as dark lines while the valleys are the light areas between the ridges. A cut or burn to a finger does not affect the underlying ridge structure, and the original pattern will be reproduced when new skin grows. Ridges and valleys generally run parallel to each other, and their patterns can be analyzed on a global and local level. Ridges and valleys generally run parallel to each other, and their patterns can be analyzed on a global and local level.

LCD Module
A liquid crystal is a material (normally organic for LCDs) that will flow like a liquid but whose molecular structure has some properties normally associated with solids. The Liquid Crystal Display (LCD) is a low power device. The power requirement is typically in the order of microwatts for the LCD. However, an LCD requires an external or internal light source. It is limited to a temperature range of about 0C to 60C and lifetime is an area of concern, because LCDs can chemically degrade There are two major types of LCDs which are: 1. Dynamic-scattering LCDs 2. Field-effect LCDs

Field-effect LCDs are normally used in such applications where source of energy is a prime factor (e.g., watches, portable instrumentation etc.).They absorb considerably less power than the light-scattering type. However, the cost for field-effect units is typically

Finger Print Based Security System higher, and their hoight is limited to 2 inches. On the other hand, light-scattering units are available up to 8 inches in height. Field-effect LCD is used in the project for displaying the appropriate information. The turn-on and turn-off time is an important consideration in all displays. The response time of LCDs is in the range of 100 to 300ms.The lifetime of LCDs is steadily increasing beyond 10,000+hours limit. Since the color generated by LCD units is dependent on the source of illumination, there is a wide range of color choice.

Power supply
The Entire Project needs power for its operation. However, from the study of this project it comes to know that we supposed to design 5v and 12v dc power supply. So by utilizing the following power supply components, required power has been gained. (230/12v (1A and 500mA) Step down transformers, Bridge rectifier to converter ac to dc, booster capacitor and +5v (7805) and +12v (7812) regulator to maintain constant 5v & 12 supply for the controller circuit and Fingerprint module).

DC Motors
In this project DC motors can be used to drive the gates. There are always two options in front of the designer whether to use a DC motor or a stepper motor. When it comes to speed, weight, size, cost... DC motors are always preferred over stepper motors. There are many things which you can do with your DC motor when interfaced with a microcontroller. For example you can control the speed of motor; you can control the direction of rotation. In this part of tutorial we will learn to interface and control of a DC motor with a microcontroller. Usually Hbridge is preferred way of interfacing a DC motor. These days many IC manufacturers have Hbridge motor driver available in the market like L293D is most used H Bridge driver IC. Hbridge can also be made with the help of transistors and MOSFETs etc. rather of being cheap, they only increase the size of the design board, which is sometimes not required so using a small 16 pin IC is preferred for this purpose.

3. FINGERPRINT MODULE
3.1 Introduction
In the 21st century the use of biometric based systems have seen an exponential growth. This is all because of tremendous progress in this field making it possible to bring down their prices, easiness of use and its diversified use in every day life. Biometrics is

Finger Print Based Security System becoming new state of art method of security systems. Biometrics are used to prevent unauthorized access to ATM, cellular phones , laptops , offices, cars and many other security concerned things. Biometric have brought significant changes in security systems making them more secure then before, efficient and cheap. They have changed the security system from what you remember (such as password) or what you possess (such as car keys) to something you embody (retinal patterns, fingerprints, voice recognition).

What is biometrics?
Biometrics is the science of verifying the identity of an individual through physiological measurements or behavioral traits. Since biometric identifiers are associated permanently with the user they are more reliable than token or knowledge based authentication methods.

Advantages of Biometrics
Biometrics offers several advantages over traditional security measures. Some of them are presented below. 1. Accuracy and Security Biometrics based security systems are far most secure and accurate than traditional password or token based security systems. For example a password based security system has always the threat of being stolen and accessed by the unauthorized user. Further more the traditional security systems are always prone to accuracy as compared to biometrics which is more accurate. 2.One individual, Multiple IDs Traditional security systems face the problem that they dont give solution to the problem of individuals having multiple IDs. For examples a person having multiple passports to enter a foreign country. Thanks to biometrics!!! They give us a system in which an individual cant possess multiple IDs and cant change his ID through out his life time. Each individual is identified through a unique Biometric identity throughout the world. 3. One ID, multiple individuals In traditional security systems one ID can be used by multiple individuals. For example in case of a password based security system a single password can be shared among multiple individuals and they can share the resources allotted to a single individual. Biometric based security system doesnt allow such a crime. Here each individual has a single unique ID and it cant be shared with any other individual.

Finger Print Based Security System

Biometrics categories
Biometrics can be categorized in various categories as follow. 1.Physical biometrics 2. Behavioral biometrics Physical biometrics This biometrics involves measurement of physical characteristics of individuals. The most prominent of these include Fingerprints Face Hand geometry Iris scans

Behavioral biometrics This category of biometrics is temporal in nature. They are evolved during the life time of an individual. It involves measuring the way in which an individual performs certain tasks. Behavioral biometrics include Gait Handwriting Speech Signature

3.2 History of Fingerprint


Fingerprints have been scientifically studied for many years in our society. The characteristics of fingerprints were studied as early as 1600s. Meanwhile, using fingerprints as a means of identification first occurred in the mid-1800s. Sir William Herschel, in 1859, discovered that fingerprints do not change over time and that each pattern is unique to an individual. With these findings, he was the first to implement a system using fingerprints and handprints to identify an individual in 1877. By 1896, police forces in India realized the benefit of using fingerprints to identify criminals, and they began collecting the fingerprints of prisoners along with their other measurements

Finger Print Based Security System With a growing database of fingerprint images, it soon became desirable to have an efficient manner of classifying the various images. Between 1896 and 1897, Sir Edward Henry developed the Henry Classification System, which quickly found worldwide acceptance within a few years. This system allows for logical categorization of a complete set of the ten fingerprint images for a person. By establishing groupings based on fingerprint pattern types, the Henry System greatly reduces the effort of searching a large database. Until the mid-1990s, many organizations continued to use the Henry Classification System to store their physical files of fingerprint images. As fingerprints began to be utilized in more fields, the number of requests for fingerprint matching began to increase on a daily basis. At the same time, the size of the databases continued to expand with each passing day. Therefore, it soon became difficult for teams of fingerprint experts to provide accurate results in a timely manner. In the early 1960s, the FBI, Home Office in the United Kingdom, and Paris Police Department began to devote a large amount of resources in developing automatic fingerprint identification systems. These systems allowed for an improvement in operational productivity among law enforcement agencies. At the same time, the automated systems reduced funding requirements to hire and train human fingerprint experts. Today, automatic fingerprint recognition technology can be found in a wide range of civilian applications.

What is A Fingerprint ?
A fingerprint is the feature pattern of one finger. It is believed with strong evidences that each fingerprint is unique. Each person has his own fingerprints with the permanent uniqueness. So fingerprints have being used for identification and forensic investigation for a long time. Fingerprint recognition is one of the most reliable identification techniques. Fingerprint technology is the most widely used for security purposes. The Technology is being frequently used in criminal investigation purpose.

Finger Print Based Security System

Figure 3.2 Fingerprint image acquired by an Optical Sensor.

3.3 Fingerprint features


A fingerprint pattern is composed of a sequence of ridges and valleys. In a fingerprint image, the ridges appear as dark lines while the valleys are the light areas between the ridges. A cut or burn to a finger does not affect the underlying ridge structure, and the original pattern will be reproduced when new skin grows. Ridges and valleys generally run parallel to each other, and their patterns can be analyzed on a global and local level. Ridges and valleys generally run parallel to each other, and their patterns can be analyzed on a global and local level. Depending on the application, fingerprint based systems can be used in one of two modes 1) Master Mode (enrollment, deletion..). 2) User Mode (Verification or identification). 1. Master Mode (Enrollment, Deletion): Enrollment is done in this mode. In this mode fingerprint image is captured by a scanner, enhanced, encoded, and stored as a reference template for future comparisons. How fingerprint systems extract features and encode and store information in the template is based on the system vendors proprietary algorithms. Template size varies depending on the vendor and the technology. Templates can be stored remotely in a central database or within the device itself. The reference template is linked to the identity specified on the identification

Finger Print Based Security System document. This reference template linked to the corresponding identity is later used for the authentication purpose. Deletion of the enrolled users is also done in this mode.

Figure3.3.1 Master Mode Block Diagram The registration of the employees is done directly through interfacing the FM10 (Finger Print Module) to the computer in the master mode. The application program is developed using java API. The Java communication API is used to communicate with the fingerprint device by which registration process can be done. The employee details along with biometric information database are stored in the flash memory of the Fingerprint module. The flash memory can store 100 users of data. The fingerprint image is scanned twice for each user and the corresponding two images along with the user ID and password are stored in the flash memory. 2. User Mode (Verification or Identification) In this mode, the step after enrollment is to verify that a person is who he or she claims to be (i.e., the person who enrolled). After the individual provides the fingerprint he or she enrolled with, which the fingerprint system captures, generating a trial template that is based on the vendors algorithm. The system then compares the trial biometric template with this persons reference template, which was stored in the system during enrollment, to determine whether the individuals trial and stored templates match (see figure 1).

FINGER PRINT FINGER SENSOR MAX23 PRINT 2

MICRO CONTROLLER
ULN 89S52

L.C.D

Finger Print Based Security System

Figure 3.3.2 User Mode Block diagram Microcontroller 89S52 is programmed to operate under user mode. The microcontroller is interfaced with Fingerprint sensor, Computer, Infrared sensors, Keyboard, LCD display, Relays, Door Activators. Important sections involved in the user mode:

Fingerprint Scanning section. Microcontroller section. LIQUID CRYSTAL DISPLAY Section. Microcontroller-computer Interface Section. Relay section.

3.4 Fingerprint Scanning section


NITIGEN FIM10 a stand-alone Fingerprint Recognition Device is used for scanning the finger fingerprint image. It provides the high recognition performance, the low power dissipation and the RS-232 serial interface with the simple protocol for easy integration into a wide range of applications. It has a in built Flash Memory which has a capacity of storing 100

Finger Print Based Security System users. The Fingerprint sensor is scans the Fingerprint and convert that Fingerprint image to an equivalent 16 byte template. For each user two Fingerprint images each of size 16 bytes, ID (10 bytes), Password (16 bytes) is stored in the Flash Memory. In this user mode this FIM10 (Fingerprint Device) is interfaced with the Microcontroller 89S52. Before entering an organization the employee provides his ID and fingerprint device is used to scan the fingerprint of he or she enrolled with, generating a trial template. The device then compares the trial fingerprint template with this persons reference template, which was stored in the device memory during enrollment, to determine whether the employee trial and stored templates match. This information is reported to the Microcontroller. The Microcontroller is programmed to do necessary tasks.

Position of the fingerprint


In order to capture the most minutiae, maximize the surface area of the fingerprint on the fingerprint input window. Figure shows the correct positioning of the fingerprint on the input window.

Figure 3.4.1 Correct positioning of fingerprint on input window

Figure Common mistakes

Finger Print Based Security System Allowable angle of fingerprint rotation FIM10 allows up to 45 degrees for input fingerprint rotation, as illustrated in Figure.

Figure 3.4.2 The allowable angle of fingerprint rotation.

Fingerprint Recognition
Our fingerprint recognition system is ultimately based on a well defined representation of a fingerprint recognition Technique. Taking a Fingerprint at first we enhanced the quality of that image to make the image clearer for easy further operations. Since the fingerprint images acquired from sensors or other medias are not assured with perfect quality, those enhancement methods, for increasing the contrast between ridges and furrows and for connecting the false broken points of ridges due to insufficient amount of ink, are very useful for keep a higher accuracy to fingerprint recognition. various methods that are adopted in our fingerprint recognition system to enhance the image quality are Fingerprint Enhancement by Histogram Equalization and Fingerprint Enhancement by Fourier Transform. The fingerprint recognition problem can be grouped into two sub-domains: one is fingerprint verification and the other is fingerprint identification. Fingerprint verification is to verify the authenticity of one person by his fingerprint. The user provides his fingerprint together with his identity information like his ID number. The fingerprint verification system retrieves the fingerprint template according to the ID number and matches the template with the real-time acquired fingerprint from the user. Usually it is the underlying design principle of AFAS (Automatic Fingerprint Authentication System).Fingerprint identification is to specify one persons identity by his fingerprint(s). Without knowledge of the persons identity, the fingerprint identification system tries to match his fingerprint(s) with those in the whole fingerprint database. It is especially useful for criminal investigation cases. And it is

Finger Print Based Security System the design principle of AFIS (Automatic Fingerprint Identification System). However, all fingerprint recognition problems, either verification or identification, are ultimately based on a well-defined representation of a fingerprint. As long as the representation of fingerprints remains the uniqueness and keeps simple, the fingerprint matching, either for the 1-to-1 verification case or 1-to-m identification case, is straightforward and easy.

FIM30N
FIM30N is a low-price stand-alone Fingerprint Identification Device with many excellent features. It provides benefits such as high identification performance, low power consumption and RS-232 serial interface with the various commands for easy integration into a wide range of applications. It is a durable and compact device with fingerprint identification module containing NITGEN optics-based fingerprint sensor inside.

Target Application
1. Door-lock system 2. Safe Box 3. Simple Access Controller 4. Vehicle Control 5. ATM , POS 6. And more

Basic Feature
Hardware Specification

Finger Print Based Security System

Table 3.4.1 Hardware specification of FIM3030 Operation Specification

Table 3.4.2 Operational specification of FIM3030 Verification systems can contain databases ranging from dozens to millions of enrolled templates but are always predicated on matching an individuals presented fingerprint against his or her reference template. Nearly all verification systems can render a matchno-match decision in less than a second. A system that requires employees to authenticate their claimed identities before granting them access to secure buildings or to

Finger Print Based Security System computers is a verification application. In this mode creation and deletion of users is not possible. Our project is developed to provide security to an Organization. In this project NITIGEN fingerprint sensor is used to scan the fingerprint image. The registration of the employees is done directly through interfacing the FM10 (Fingerprint Module) to the computer in the master mode. The application program is developed using java API. The employee details along with biometric information database is stored in the flash memory of the Fingerprint Module. The Microcontroller 89S52 is programmed to operate under user mode.

Figure 3.4.4 The Fingerprint Verification Process

4.MICROCONTROLLER

Finger Print Based Security System

4.1 Introduction to Microcontroller


A microcontroller (or MCU) is a computer-on-a-chip. It is a type of microprocessor emphasizing self-sufficiency and cost-effectiveness, in contrast to a general-purpose microprocessor (the kind used in a PC).

Typical Microcontroller Architecture and Features


The basic internal designs of microcontrollers are pretty similar. Figure1 shows the block diagram of a typical microcontroller. All components are connected via an internal bus and are all integrated on one chip. The modules are connected to the outside world via I/O pins.

Figure 4.1 Basic Layout of Microcontroller The following list contains the modules typically found in a microcontroller. You can find a more detailed description of these components in later sections.

Processor Core
The CPU of the controller . It contains the arithmetic logic unit, the control unit, and the registers (stack pointer, program counter, accumulator register, register file . . .). Memory

Finger Print Based Security System The memory is sometimes split into program memory and data memory. In larger controllers, a DMA controller handles data transfers between peripheral components and the memory. Interrupt Controller Interrupts are useful for interrupting the normal program flow in case of (important) external or internal events. In conjunction with sleep modes, they help to conserve power. Timer/Counter Most controllers have at least one and more likely 2-3 Timer/Counters, which can be used to timestamp events, measure intervals, or count events. Many controllers also contain PWM (pulse width modulation) outputs, which can be used to drive motors or for safe breaking (antilock brake system, ABS). Furthermore the PWM output can, in conjunction with an external filter, be used to realize a cheap digital/analog converter. Digital I/O Parallel digital I/O ports are one of the main features of microcontrollers. The number of I/O pins varies from 3-4 to over 90, depending on the controller family and the controller type. Analog I/O Apart from a few small controllers, most microcontrollers have integrated analog/digital converters, which differ in the number of channels (2-16) and their resolution (8-12 bits). The analog module also generally features an analog comparator. In some cases, the microcontroller includes digital/analog converters.

The UART: What it is and how it works


The Universal Asynchronous Receiver/Transmitter (UART) controller is the key component of the serial communications subsystem of a computer. The UART takes bytes of data and transmits the individual bits in a sequential fashion. At the destination, a second UART re-assembles the bits into complete bytesSerial transmission is commonly used with modems and for non-networked communication between computers, terminals and other devices. There are two primary forms of serial transmission: Synchronous and Asynchronous. Depending on the modes that are supported by the hardware, the name of the communication

Finger Print Based Security System sub-system will usually include a A if it supports Asynchronous communications, and a S if it supports Synchronous communications. Both forms are described below.

Synchronous Serial Transmission


Synchronous serial transmission requires that the sender and receiver share a clock with one another, or that the sender provide a strobe or other timing signal so that the receiver knows when to read the next bit of the data. In most forms of serial Synchronous communication, if there is no data available at a given instant to transmit, a fill character must be sent instead so that data is always being transmitted. Synchronous communication is usually more efficient because only data bits are transmitted between sender and receiver, and synchronous communication can be more costly if extra wiring and circuits are required to share a clock signal between the sender and receiver. A form of Synchronous transmission is used with printers and fixed disk devices in that the data is sent on one set of wires while a clock or strobe is sent on a different wire. Printers and fixed disk devices are not normally serial devices because most fixed disk interface standards send an entire word of data for each clock or strobe signal by using a separate wire for each bit of the word. In the PC industry, these are known as Parallel devices. The standard serial communications hardware in the PC does not support Synchronous operations. This mode is described here for comparison purposes only

Asynchronous Serial Transmission


Asynchronous transmission allows data to be transmitted without the sender having to send a clock signal to the receiver. Instead, the sender and receiver must agree on timing parameters in advance and special bits are added to each word which are used to synchronize the sending and receiving units. When a word is given to the UART for Asynchronous transmissions, a bit called the "Start Bit" is added to the beginning of each word that is to be transmitted. The Start Bit is used to alert the receiver that a word of data is about to be sent, and to force the clock in the receiver into synchronization with the clock in the transmitter. These two clocks must be accurate enough to not have the frequency drift by more than 10% during the transmission of the remaining bits in the word. (This requirement was set in the days of mechanical tele printers and is easily met by modern electronic equipment.)

Finger Print Based Security System After the Start Bit, the individual bits of the word of data are sent, with the Least Significant Bit (LSB) being sent first. Each bit in the transmission is transmitted for exactly the same amount of time as all of the other bits, and the receiver looks at the wire at approximately halfway through the period assigned to each bit to determine if the bit is a 1 or a 0. For example, if it takes two seconds to send each bit, the receiver will examine the signal to determine if it is a 1 or a 0 after one second has passed, then it will wait two seconds and then examine the value of the next bit, and so on. The sender does not know when the receiver has looked at the value of the bit. The sender only knows when the clock says to begin transmitting the next bit of the word. When the entire data word has been sent, the transmitter may add a Parity Bit that the transmitter generates. The Parity Bit may be used by the receiver to perform simple error checking. Then at least one Stop Bit is sent by the transmitter. When the receiver has received all of the bits in the data word, it may check for the Parity Bits (both sender and receiver must agree on whether a Parity Bit is to be used), and then the receiver looks for a Stop Bit. If the Stop Bit does not appear when it is supposed to, the UART considers the entire word to be garbled and will report a Framing Error to the host processor when the data word is read. The usual cause of a Framing Error is that the sender and receiver clocks were not running at the same speed, or that the signal was interrupted. Regardless of whether the data was received correctly or not, the UART automatically discards the Start, Parity and Stop bits. If the sender and receiver are configured identically, these bits are not passed to the host. If another word is ready for transmission, the Start Bit for the new word can be sent as soon as the Stop Bit for the previous word has been sent.

4.2 AT89S52 MICROCONTROLLER


Description
The AT89s52 is a low power, high performance CMOS 8-bit micro computer with 8K bytes of flash programmable and erasable read only memory(PEROM).The device is manufactured using Atmels high density nonvolatile memory technology and is compatible with the industry standard 80c51 and 80C52 instruction set and pin out. The onchip 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 flash on a monolithic chip, the Atmel AT89s52 Is a powerful microcomputer which provides a highly

Finger Print Based Security System flexible and cost effective solution to many embedded control applications. The main advantages of 89s52 over 8051 are Software Compatibility Program Compatibility Rewritability The 89s52 microcontroller has an excellent software compatability, i.e. the software used can be applicable to any other microcontroller. The program written on this microcontroller can be carried to any base. Program compatibility is the major advantage in 89s52. The program can be used in any other advanced microcontroller. The program can be reloaded and changed for nearly 1000 times.

Features
Compatible with MCS-51 Products 8K Bytes of In-System Programmable (ISP) Flash Memory 4.0V to 5.5V Operating Range Fully Static Operation: 0 Hz to 33 MHz Three-level Program Memory Lock 256 x 8-bit Internal RAM 32 Programmable I/O Lines Three 16-bit Timer/Counters Eight Interrupt Sources Full Duplex UART Serial Channel Low-power Idle and Power-down Modes Interrupt Recovery from Power-down Mode Watchdog Timer Dual Data Pointer

Finger Print Based Security System Power-off Flag

89S52 Processor Architecture


The AT89s52 provides the following standard features: 8K bytes of Flash, 256 bytes of RAM, 32 I/O lines, three 16-bit timer/counters, a six-vector two-level interrupt architecture, a full-duplex serial port, on-chip oscillator, and clock circuitry. In addition, the AT89s52 is designed with static logic for operation down to zero frequency and supports two software selectable power saving modes. The Idle Mode stops the CPU while allowing the RAM, timer/counters, serial port, and interrupt system to continue functioning. The Powerdown mode saves the RAM contents but freezes the oscillator, disabling all other chip functions until the next hardware reset.

Finger Print Based Security System

Figure 4.2.1 89S52 microcontroller architecture

Finger Print Based Security System

Pin Diagram

Figure 4.2.2 Pin diagram of 89S52

Pin Description VCC


Pin 40 provides supply voltage to the chip. The voltage source is + 5V.

GND
Pin 20 provides ground.

Finger Print Based Security System

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 inputs, 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 trigger input (P1.1/T2EX), respectively, as shown in the following table. Port 1 also receives the low-order address bytes during Flash programming and verification.

Finger Print Based Security System Table 4.2.1 Port1 specifications

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 uses 16-bit addresses (MOVX @ DPTR). In this application, Port 2 uses strong internal pull-ups when emitting 1s. During accesses to external data memory that uses 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 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.

Finger Print Based Security System Table 4.2.2 Port3 specifications

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
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 8EH. 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 program 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 enables. 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 to VCC for internal program executions. This pin also receives the 12-volt programming enable voltage (VPP) during Flash programming.

Finger Print Based Security System

XTAL1
Input to the inverting oscillator amplifier and input to the internal clock operating circuit.

XTAL2
Output from the inverting oscillator amplifier.

Special Function Registers


A map of the on-chip memory area called the Special Function Register (SFR) space is shown in Table 1. 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 random data, and write accesses will have an indeterminate 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 Registers
Control and status bits are contained in registers T2CON (shown in Table 2) and T2MOD (shown in Table 3) for Timer 2. The register pair (RCAP2H, RCAP2L) is the Capture/Reload registers for Timer 2 in 16-bit capture mode or 16-bit auto-reload mode.

Interrupt Registers
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 Pointer Registers


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 the DPS bit to the appropriate value before accessing the respective Data Pointer Register.

Finger Print Based Security System

Power Off Flag


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.

Memory Organization
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, program fetches to addresses 0000H through 1FFFH are directed to internal 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.

Finger Print Based Security System

Watchdog Timer (One-time Enabled with Reset-out)


The WDT is intended as a recovery method in situations where the CPU may be subjected to software upsets. The WDT consists of a 13-bit counter and the Watchdog Timer Reset (WDTRST) SFR. The WDT is defaulted to disable from exiting reset. To enable the WDT, a user must write 01EH and 0E1H in sequence to the WDTRST register (SFR location 0A6H). When the WDT is enabled, it will increment every machine cycle while the oscillator is running. The WDT timeout period is dependent on the external clock frequency. There is no way to disable the WDT except through reset (either hardware reset or WDT overflow (reset). When WDT overflows, it will drive an output RESET HIGH pulse at the RST pin.

Using the WDT


To enable the WDT, a user must write 01EH and 0E1H in sequence to the WDTRST register (SFR location 0A6H). When the WDT is enabled, the user needs to service it by writing 01EH and 0E1H to WDTRST to avoid a WDT overflow. The 13-bit counter overflows when it reaches 8191 (1FFFH), and this will reset the device. When the WDT is enabled, it will increment every machine cycle while the oscillator is running. This means the user must reset the WDT at least every 8191 machine cycles. To reset the WDT the user must write 01EH and 0E1H to WDTRST. DTRST is a write-only register. The WDT counter cannot be read or written. When WDT overflows, it will generate an output RESET pulse at the RST pin. The RESET pulse duration is 96xTOSC, where TOSC=1/FOSC. To make the best use of the WDT, it should be serviced in those sections of code that will periodically be executed within the time required to prevent a WDT reset.

WDT during Power-down and Idle


In Power-down mode the oscillator stops, which means the WDT also stops. While in Power-down mode, the user does not need to service the WDT. There are two methods of exiting Power-down mode: by a hardware reset or via a level-activated external interrupt which is enabled prior to entering Power-down mode. When Power-down is exited with hardware reset, servicing the WDT should occur as it normally does whenever the AT89S52 is reset. Exiting Power-down with an interrupt is significantly different. The interrupt is held low long enough for the oscillator to stabilize. When the interrupt is brought high, the interrupt is serviced. To prevent the WDT from resetting the device while the interrupt pin is held low, the WDT is not started until the interrupt is pulled high. It is suggested that the WDT be reset during the interrupt service for the interrupt used to exit Power-down mode.

Finger Print Based Security System To ensure that the WDT does not overflow within a few states of exiting Powerdown, it is best to reset the WDT just before entering Power-down mode. Before going into the IDLE mode, the WDIDLE bit in SFR AUXR is used to determine whether the WDT continues to count if enabled. The WDT keeps counting during IDLE WDIDLE bit = 0) as the default state. To prevent the WDT from resetting the AT89S52 while in IDLE mode, the user should always set up a timer that will periodically exit IDLE, service the WDT, and reenter IDLE mode. With WDIDLE bit enabled, the WDT will stop to count in IDLE mode and resumes the count upon exit from IDLE.

UART
Serial data communication uses two methods, asynchronous and synchronous. The synchronous method transfers a block of data (characters ) at a time, while the asynchronous method transfers a single byte at a time. It is possible to write software to use either of these methods, but programs can be tedious and long. For this reason, there are special IC chips made by the manufacturers for the serial data communications. These chips are commonly referred to as UART ( universal asynchronous receiver-transmitter) and USART ( universal synchronous receiver-transmitter). The 8052 has built-in UART.

Timer 0
The 16-bit register of timer 0 is accessed as low byte and high byte. The low byte register is called TL0 ( Timer 0 low byte) and the high byte register is referred to as TH0 ( Timer 0 high byte). These registers can be accessed like any other registers , such as A,B,R0,R1,R2 etc. for example the instruction MOV TL0,#4FH moves the value 4FH into TL0, the low byte of Timer 0. These registers can also be read like any other register. For example, MOV R5,TH0 saves TH0 ( high byte of Timer 0) in R5.

Timer1
Timer 1 is also 16 bits and its 16-bit register is split into two bytes, referred to as TL1 (Timer 1 low byte ) and TH1 ( Timer 1 high byte). These registers are accessible in the same way as the registers of Timer 0.

Finger Print Based Security System

Timer 2
Timer 2 is a 16-bit Timer/Counter that can operate as either a timer or an event counter. The type of operation is selected by bit C/T2 in the SFR T2CON (shown in Table 2). Timer 2 has three operating modes: capture, auto-reload (up or down counting), and baud rate generator. The modes are selected by bits in T2CON, as shown in Table 3. Timer 2 consists of two 8-bit registers, TH2 and TL2. In the Timer function, the TL2 register is incremented every machine cycle. Since a machine cycle consists of 12 oscillator periods, the count rate is 1/12 of the oscillator frequency.

Table 4.2.3 Timer2 Operating Modes of AT89S52 In the Counter function, the register is incremented in response to a 1-to-0 transition at its corresponding external input pin, T2. In this function, the external input is sampled during S5P2 of every machine cycle. When the samples show a high in one cycle and a low in the next cycle, the count is incremented. The new count value appears in the register during S3P1 of the cycle following the one in which the transition was detected. Since two machine cycles (24 oscillator periods) are required to recognize a 1-to-0 transition, the maximum count rate is 1/24 of the oscillator frequency. To ensure that a given level is sampled at least once before it changes, the level should be held for at least one full machine cycle.

Oscillator Characteristics
XTAL1 and XTAL2 are the input and output, respectively, of an inverting amplifier that can be configured for use as an on-chip oscillator, as shown in Figure 11. Either a quartz

Finger Print Based Security System crystal or ceramic resonator may be used. To drive the device from an external clock source, XTAL2 should be left unconnected while XTAL1 is driven, as shown in Figure 12. There are no requirements on the duty cycle of the external clock signal, since the input to the internal clocking circuitry is through a divide-by-two flip-flop, but minimum and maximum voltage high and low time specifications must be observed.

Oscillator connections

Figure 4.2.3 Oscillator Connections of AT89S52 Note: C1, C2 = 30 pF 10 pF for Crystals = 40 pF 10 pF for Ceramic Resonators

External Clock Drive Configuration

Finger Print Based Security System

Figure 4.2.4 External Clock Drive Configuration of AT89S52

Idle Mode
In idle mode, the CPU puts itself to sleep while all the on chip peripherals remain active. The mode is invoked by software. The content of the on-chip RAM and all the special functions registers remain unchanged during this mode. The idle mode can be terminated by any enabled interrupt or by a hardware reset. Note that when idle mode is terminated by a hardware reset, the device normally resumes program execution from where it left off, up to two machine cycles before the internal reset algorithm takes control. On-chip hardware inhibits access to internal RAM in this event, but access to the port pins is not inhibited. To eliminate the possibility of an unexpected write to a port pin when idle mode is terminated by a reset, the instruction following the one that invokes idle mode should not write to a port pin or to external memory.

Power-down Mode
In the Power-down mode, the oscillator is stopped, and the instruction that invokes Power-down is the last instruction executed. The on-chip RAM and Special Function Registers retain their values until the Power-down mode is terminated. Exit from Powerdown mode can be initiated either by a hardware reset or by an enabled external interrupt. Reset redefines the SFRs but does not change the on-chip RAM. The reset should not be activated before VCC is restored to its normal operating level and must be held active long enough to allow the oscillator to restart and stabilize.

Finger Print Based Security System Status of External Pins during Idle and Power-down Modes

Table 4.2.4 Power down and Idle Modes of AT89S52

5. FUNCTIONAL DESCRIPTIONS 5.1 Lcd Display


Liquid crystal display (LCD) has material which combines the properties of both liquid and crystals. They have a temperature range within which the molecules are almost as

Finger Print Based Security System mobile as they would be in a liquid, but are grouped together in an order form similar to a crystal.

Fig 5.1.1 LCD module More microcontroller devices are using 'smart LCD' displays to output visual information. The following discussion covers the connection of a Hitachi LCD display to a PIC microcontroller. LCD displays designed around Hitachi's LCD HD44780 module, are inexpensive, easy to use, and it is even possible to produce a readout using the 8 x 80 pixels of the display. Hitachi LCD displays have a standard ASCII set of characters plus Japanese, Greek and mathematical symbols.

Hardware Diagram

Finger Print Based Security System

Fig 5.1.2 LCD pin configuration For an 8-bit data bus, the display requires a +5V supply plus 11 I/O lines. For a 4-bit data bus it only requires the supply lines plus seven extra lines. When the LCD display is not enabled, data lines are tri-state which means they are in a state of high impedance (as though they are disconnected) and this means they do not interfere with the operation of the microcontroller when the display is not being addressed. The LCD also requires 3 "control" lines from the microcontroller. When the LCD is initialized, it is ready to continue receiving data or instructions. If it receives a character, it will write it on the display and move the cursor one space to the right. The Cursor marks the next location where a character will be written. When we want to write a string of characters, first we need to set up the starting address, and then send one character at a time.

K D7

Pins description

ACK

Finger Print Based Security System

Table 5.1 pins for LCD


Logic status on control lines RS (Command / Data): This bit is to specify weather received byte is command or data. So that LCD can recognize the operation to be performed based on the bit status. RS RS RW (Read / Write) RW bit is to specify weather controller wants READ from LCD or WRITE to LCD. The READ operation here is just ACK bit to know weather LCD is free or not. RW RW EN (Enable LCD) EN bit is to ENABLE or DISABLE the LCD. When ever controller wants to write some thing into LCD or READ acknowledgment from LCD it needs to enable the LCD. EN EN = 0 = 1 => => High Impedance Low Impedance = 0 = 1 => => Write Read = 0 = 1 => => Command Data

ACK (LCD Ready) ACK bit is to acknowledge the MCU that LCD is free so that it can send new command or data to be stored in its internal Ram locations.

Finger Print Based Security System ACK = 1 ACK = 0 => => Not ACK ACK

Reading data from the LCD is done in the same way, but control line R/W has to be high. When we send a high to the LCD, it will reset and wait for instructions. Typical instructions sent to LCD display after a reset are: turning on a display, turning on a cursor and writing characters from left to right. Characters that can be shown on the display are stored in data display (DD) RAM. The size of DDRAM is 80 bytes. Before we access DD RAM after defining a special character, the program must set the DD RAM address. Writing and reading data from any LCD memory is done from the last address which was set up using set-address instruction. Once the address of DD RAM is set, a new written character will be displayed at the appropriate place on the screen. Until now we discussed the operation of writing and reading to an LCD as if it were an ordinary memory. But this is not so. The LCD controller needs 40 to 120 microseconds (uS) for writing and reading. Other operations can take up to 5 mS. During that time, the microcontroller can not access the LCD, so a program needs to know when the LCD is busy. We can solve this in two ways.One way is to check the BUSY bit found on data line D7. This is not the best method because LCD's can get stuck, and program will then stay forever in a loop checking the BUSY bit. The other way is to introduce a delay in the program. The delay has to be long enough for the LCD to finish the operation in process. At the beginning we mentioned that we needed 11 I/O lines to communicate with an LCD. However, we can communicate with an LCD through a 4-bit data bus. Thus we can reduce the total number of communication lines to seven.

5.2 Power Supply Unit


The input to the circuit is applied from the regulated power supply. The a.c. input i.e., 230V from the mains supply is step down by the transformer to 12V and is fed to a rectifier. The output obtained from the rectifier is a pulsating d.c voltage. So in order to get a pure d.c voltage, the output voltage from the rectifier is fed to a filter to remove any a.c components present even after rectification. Now, this voltage is given to a voltage regulator to obtain a pure constant dc voltage.

Finger Print Based Security System

BLOCK DIAGRAM

230 AC 50Hz

DC OUT PUT

Step down transformer

Bridge rectifier

filter

Regulator

Fig 5.2.1 power supply Power supply unit consists of following units i) Step down transformer ii) Rectifier unit iii) Input filter iv).Regulator unit v) Output filter

Step down Transformer The Step down Transformer is used to step down the main supply voltage from 230V AC to lower value. This 230 AC voltage cannot be used directly, thus it is stepped down. The Transformer consists of primary and secondary coils. To reduce or step down the voltage, the transformer is designed to contain less number of turns in its secondary core. The output from the secondary coil is also AC waveform. Thus the conversion from AC to DC is essential. This conversion is achieved by using the Rectifier Circuit/Unit.

Finger Print Based Security System Step down transformers can step down incoming voltage, which enables you to have the correct voltage input for your electrical needs. For example, if our equipment has been specified for input voltage of 12 volts, and the main power supply is 230 volts, we will need a step down transformer, which decreases the incoming electrical voltage to be compatible with your 12 volt equipment. Rectifier Unit The Rectifier circuit is used to convert the AC voltage into its corresponding DC voltage. The most important and simple device used in Rectifier circuit is the diode. The simple function of the diode is to conduct when forward biased and not to conduct in reverse bias. Now we are using three types of rectifiers. They are 1. Half-wave rectifier 2. Full-wave rectifier 3. Bridge rectifier Half-Wave Rectifier In half wave rectification, either the positive or negative half of the AC wave is passed, while the other half is blocked. Because only one half of the input waveform reaches the output, it is very inefficient if used for power transfer. Half-wave rectification can be achieved with a single diode in a one phase supply, or with three diodes in a three-phase supply

Bridge Rectifier A bridge rectifier makes use of four diodes in a bridge arrangement to achieve fullwave rectification. This is a widely used configuration, both with individual diodes wired as shown and with single component bridges where the diode bridge is wired internally. A diode bridge or bridge rectifier is an arrangement of four diodes in a bridge configuration that provides the same polarity of output voltage for either polarity of input voltage. When used in its most common application, for conversion of alternating current (AC) input into direct current (DC) output, it is known as a bridge rectifier. A bridge rectifier provides full-wave rectification from a two-wire AC input, resulting in lower cost and weight as compared to a center-tapped transformer design.

Finger Print Based Security System The Forward Bias is achieved by connecting the diodes positive with positive of the battery and negative with batterys negative. The efficient circuit used is the Full wave Bridge rectifier circuit. The output voltage of the rectifier is in rippled form, the ripples from the obtained DC voltage are removed using other circuits available. The circuit used for removing the ripples is called Filter circuit. Input Filter Capacitors are used as filter. The ripples from the DC voltage are removed and pure DC voltage is obtained. And also these capacitors are used to reduce the harmonics of the input voltage. The primary action performed by capacitor is charging and discharging. It charges in positive half cycle of the AC voltage and it will discharge in negative half cycle. So it allows only AC voltage and does not allow the DC voltage. This filter is fixed before the regulator. Thus the output is free from ripples. Regulator Unit Regulator regulates the output voltage to be always constant. The output voltage is maintained irrespective of the fluctuations in the input AC voltage. As and then the AC voltage changes, the DC voltage also changes. Thus to avoid this Regulators are used. Also when the internal resistance of the power supply is greater than 30 ohms, the output gets affected. Thus this can be successfully reduced here. The regulators are mainly classified for low voltage and for high voltage. Further they can also be classified as i) Positive regulator 1. input pin 2. ground pin 3. output pin It regulates the positive voltage. ii) Negative regulator 1. ground pin 2. input pin 3. output pin It regulates the negative voltage. Fixed Regulators

Finger Print Based Security System

Fig 5.2.2 An assortment of 78xx series ICs "Fixed" three-terminal linear regulators are commonly available to generate fixed voltages of plus 3 V, and plus or minus 5 V, 9 V, 12 V, or 15 V when the load is less than about 7 amperes. 7805 Voltage Regulator The 7805 provides circuit designers with an easy way to regulate DC voltages to 5v. Encapsulated in a single chip/package (IC), the 7805 is a positive voltage DC regulator that has only 3 terminals. They are: Input voltage, Ground, Output Voltage.

General Features: Output Current up to 1A Output Voltages of 5, 6, 8, 9, 10, 12, 15, 18, 24V Thermal Overload Protection Short Circuit Protection Output Transistor Safe Operating Area Protection

Output Filter The Filter circuit is often fixed after the Regulator circuit. Capacitor is most often used as filter. The principle of the capacitor is to charge and discharge. It charges during the

Finger Print Based Security System positive half cycle of the AC voltage and discharges during the negative half cycle. So it allows only AC voltage and does not allow the DC voltage. This filter is fixed after the Regulator circuit to filter any of the possibly found ripples in the output received finally. Here we used 0.1F capacitor. The output at this stage is 5V and is given to the Microcontroller. The output voltage overshoots when the load is removed or a short clears. When the load is removing from a switching mode power supply with a LC low-pass output filter, the only thing the control loop can do is stop the switching action so no more energy is taken from the source. The energy that is stored in the output filter inductor is dumped into the output capacitor causing a voltage overshoot. The magnitude of the overshoot is the vector sum of two orthogonal voltages, the output voltage before the load is removed and the current through the inductor times the characteristic impedance of the output filter, Zo = (L/C)^1/2. This can be derived from conservation of energy considerations. The two energies are equal when the load is removed, since the load is no longer taking energy from the system. Equating the two energies, substituting zero current for the final inductor current, then the solution for the final voltage Vf is: This is the orthogonal vector sum of the output voltage and the load current times the characteristic impedance and is illustrated in Figure .The problem becomes worse if the current in the inductor is established by a short circuit on the output and the short circuit clears. In this case, the initial voltage is zero (short circuit) and the overshoot is I*Zo, where I can be very large, resulting in a ruinous overshoot.

5.3 Serial Communication


The information from micro controller is sent to system through serial communication by using MAX-232 ic in between micro controller and RS232 DB9 connector. This MAX232 acts as voltage level translator i.e., the TTL logic voltage level is to be transformed to RS232 DB9 connector voltage level of the system. In short a MAX 232 is nothing but a clamper circuit, which consists of diodes and capacitors i.e., the voltage level translator. is done through clamping circuit here diodes are inbuilt, whereas the capacitors are to be connected externally . Introduction

Finger Print Based Security System In this chapter we are going to cover basic concepts involved in the project such as serial communication and modem activation commands. The serial communication is between the modem and MCU and also between modem and PC. Serial Communication In order to connect micro controller to a modem or a pc to modem a serial port is used. Serial is a very common protocol for device communication that is standard on almost every PC. Most computers include two RS-232 based serial ports. Serial is also a common communication protocol that is used by many devices for instrumentation; numerous GPIBcompatible devices also come with an RS-232 port. Furthermore, serial communication can be used for data acquisition in conjunction with a remote sampling device The concept of serial communication is simple. The serial port sends and receives bytes of information one bit at a time. Although this is slower than parallel communication, which allows the transmission of an entire byte at once, it is simpler and can be used over longer distances. For example, the IEEE 488 specifications for parallel communication state that the cabling between equipment can be no more than 20 meters total, with no more than 2 meters between any two devices. serial, however, can extend as much as 1200 meters. Typically, serial is used to transmit ASCII data. Communication is completed using 3 transmission lines: (1) Ground, (2) Transmit, and (3) Receive. Since serial is asynchronous, the port is able to transmit data on one line while receiving data on another. Other lines are available for handshaking, but are not required. The important serial characteristics are baud rate, data bits, stop bits, and parity. For two ports to communicate, these parameters must match. Baud rate It is a speed measurement for communication. It indicates the number of bit transfers per second. For example, 300 baud is 300 bits per second. When a clock cycle is referred it means the baud rate. For example, if the protocol calls for a 4800 baud rate, then the clock is running at 4800Hz. This means that the serial port is sampling the data line at 4800Hz. Common baud rates for telephone lines are 14400, 28800, and 33600. Baud rates greater than these are possible, but these rates reduce the distance by which devices can be separated. These high baud rates are used for device communication where the devices are located together, as is typically the case with GPIB devices. Data bits

Finger Print Based Security System A measurement of the actual data bits in a transmission. When the computer sends a packet of information, the amount of actual data may not be a full 8 bits. Standard values for the data packets are 5, 7, and 8 bits. Which setting choosen depends on what information transferred? For example, standard ASCII has values from 0 to 127 (7 bits). Extended ASCII uses 0 to 255 (8 bits). If the data being transferred is simple text (standard ASCII), then sending 7 bits of data per packet is sufficient for communication. A packet refers to a single byte transfer, including start/stop bits, data bits, and parity. Since the number of actual bits depends on the protocol selected, the term packet is used to cover all instances. Stop bits Used to signal the end of communication for a single packet. Typical values are 1, 1.5, and 2 bits. Since the data is clocked across the lines and each device has its own clock, it is possible for the two devices to become slightly out of sync. Therefore, the stop bits not only indicate the end of transmission but also give the computers some room for error in the clock speeds. The more bits that are used for stop bits, the greater the lenience in synchronizing the different clocks, but the slower the data transmission rate.

Parity A simple form of error checking that is used in serial communication. There are four types of parity: even, odd, marked, and spaced. The option of using no parity is also available. For even and odd parity, the serial port sets the parity bit (the last bit after the data bits) to a value to ensure that the transmission has an even or odd number of logic high bits. For example, if the data is 011, then for even parity, the parity bit is 0 to keep the number of logic-high bits even. If the parity is odd, then the parity bit is 1, resulting in 3 logic-high bits. Marked and spaced parity does not actually check the data bits, but simply sets the parity bit high for marked parity or low for spaced parity. This allows the receiving device to know the state of a bit to enable the device to determine if noise is corrupting the data or if the transmitting and receiving device clocks are out of sync. RS 232 RS-232 (ANSI/EIA-232 Standard) is the serial connection found on IBM-compatible PCs. It is used for many purposes, such as connecting a mouse, printer, or modem, as well as industrial instrumentation. Because of improvements in line drivers and cables, applications often increase the performance of RS-232 beyond the distance and speed listed in the

Finger Print Based Security System standard. RS-232 is limited to point-to-point connections between PC serial ports and devices. RS-232 hardware can be used for serial communication up to distances of 50 feet .
DB-9 pin connector

12345 6789

Pin Functions:

Data: Handshake: Common: Other:

TxD on pin 3, RxD on pin 2 RTS on pin 7, CTS on pin 8, DSR on pin 6, CD on pin 1, DTR on pin 4 Common pin 5(ground) RI on pin 9

The method used by RS-232 for communication allows for a simple connection of three lines: Tx, Rx, and Ground. The three essential signals for 2 way RS-232 Communications are these: TXD: carries data from DTE to the DCE. RXD: carries data from DCE to the DTE SG: signal ground Here in our project DTE is the micro controller at the remote station and PC at the base station, DCE is the modem at both the stations. However the data to be transmitted, both sides have to be clocking the data at the same baud rate. Even though this method is sufficient for most applications, it is limited in being able to respond to problems such as the receiver getting overloaded. This is where serial handshaking can help. This method uses actual hardware lines. There are two pairs of hand shaking signals DTR/DSR and RTS/CTS each pair has uses defined by the standard. There are several ways to describe the state of RS-232 and other control signals. A signal with a valid positive voltage may be described as true to indicate that it is in the active state for example when DTR is true the data terminal is ready. to bring the signal true the controlling device raises the line. A signal with a valid negative voltage may be described as false or ff to indicate that its inactive state .for example when DTR is false, the data terminal is not ready. To bring the signal false the controlling device lowers the line. The DTR/DSR handshake is intended for

Finger Print Based Security System providing information about the status of the phone line or other communications channel connected to the modem. the terminal raises DTR to request the modem to connect to the communication channel. In response the modem raises DSR to indicate that it is connected .DSR is false when the modem is not connected to the communication channel or on detecting a fault. the terminal may also raise DTR in response to RI (ring indicator) to tell the modem to answer a call. The RTS/CTS handshake provides additional information about whether a device is ready to receive data. This signal pair provides a full handshake. when the terminal has data to send ,it raises RTS (request to send). In response the modem raises CTS (clear to send) to indicate that it is ready to receive. When the transmission is finished the terminal may lower RTS. the modem should then be continue processing whatever data it has received and lower CTS when its ready to respond to the next RTS. When RTS is false, the terminal should wait for CTS to be false before raising RTS to request a new transmission. RI is true when a ringing signal is present on the communications channel. The signal is true when the audible ring is present and false in the pauses between the rings .The final control signal is the CD (carrier detect). The modem raises CD when it detects a signal of expected frequency on the phone lines, indicating that a connection has been established to a remote modem.

MAX232
PIN DIAGRAM OF MAX232

Fig 5.3 max232 pin diagram

Finger Print Based Security System This module is primary of interest for people building their own electronics with an RS-232 interface. Off-the-shelf computers with RS-232 interfaces already contain the necessary electronics, and there is no need to add the circuitry as described here. Serial RS-232 (V.24) communication works with voltages (-15V ... -3V for high [sic]) and +3V ... +15V for low [sic]) which are not compatible with normal computer logic voltages. On the other hand, classic TTL computer logic operates between 0V ... +5V (roughly 0V ... +0.8V for low, +2V ... +5V for high). Modern low-power logic operates in the range of 0V ... +3.3V or even lower. So, the maximum RS-232 signal levels are far too high for computer logic electronics, and the negative RS-232 voltage for high can't be grokked at all by computer logic. Therefore, to receive serial data from an RS-232 interface the voltage has to be reduced, and the low and high voltage level inverted. In the other direction (sending data from some logic over RS-232) the low logic voltage has to be "bumped up", and a negative voltage has to be generated, too.

Table 5.3.1 Voltage levels for RS232 and TTL All this can be done with conventional analog electronics, e.g. a particular power supply and a couple of transistors or the once popular 1488 (transmitter) and 1489 (receiver) ICs. However, since more than a decade it has become standard in amateur electronics to do the necessary signal level conversion with an integrated circuit (IC) from the MAX232 family (typically a MAX232A or some clone). In fact, it is hard to find some RS-232 circuitry in amateur electronics without a MAX232A or some clone. The MAX232 from Maxim was the first IC which in one package contains the necessary drivers (two) and receivers (also two), to adapt the RS-232 signal voltage levels to TTL logic. It became popular, because it just needs one voltage (+5V) and generates the

Finger Print Based Security System necessary RS-232 voltage levels (approx. -10V and +10V) internally. This greatly simplified the design of circuitry. Circuitry designers no longer need to design and build a power supply with three voltages (e.g. -12V, +5V, and +12V), but could just provide one +5V power supply, e.g. with the help of a simple 78x05 voltage converter. The MAX232 has a successor, the MAX232A. The ICs are almost identical, however, the MAX232A is much more often used (and easier to get) than the original MAX232, and the MAX232A only needs external capacitors 1/10th the capacity of what the original MAX232 needs. It should be noted that the MAX232(A) is just a driver/receiver. It does not generate the necessary RS-232 sequence of marks and spaces with the right timing, it does not decode the RS-232 signal, it does not provide a serial/parallel conversion. All it does is to convert signal voltage levels. Generating serial data with the right timing and decoding serial data has to be done by additional circuitry, e.g. by a 16550 UART or one of these small micro controllers (e.g. Atmel AVR, Microchip PIC) getting more and more popular. The MAX232 and MAX232A were once rather expensive ICs, but today they are cheap. It has also helped that many companies now produce clones (i.e. Sipex). These clones sometimes need different external circuitry, e.g. the capacities of the external capacitors vary. It is recommended to check the data sheet of the particular manufacturer of an IC instead of relying on Maxim's original data sheet. The original manufacturer (and now some clone manufacturers, too) offers a large series of similar ICs, with different numbers of receivers and drivers, voltages, built-in or external capacitors, etc. E.g. The MAX232 and MAX232A need external capacitors for the internal voltage pump, while the MAX233 has these capacitors built-in. The MAX233 is also between three and ten times more expensive in electronic shops than the MAX232A because of its internal capacitors. It is also more difficult to get the MAX233 than the garden variety MAX232A.A similar IC, the MAX3232 is nowadays available for low-power 3V logic. MAX232Application The MAX232(A) has two receivers (converts from RS-232 to TTL voltage levels) and two drivers (converts from TTL logic to RS-232 voltage levels). This means only two of the RS-232 signals can be converted in each direction. The old MC1488/1498 combo provided four drivers and receivers.

Finger Print Based Security System Typically a pair of a driver/receiver of the MAX232 is used for TX and RX and the second one for CTS and RTS. There are not enough drivers/receivers in the MAX232 to also connect the DTR, DSR, and DCD signals. Usually these signals can be omitted when e.g. communicating with a PC's serial interface. If the DTE really requires these signals either a second MAX232 is needed, or some other IC from the MAX232 family can be used (if it can be found in consumer electronic shops at all). An alternative for DTR/DSR is also given below.Maxim's data sheet explains the MAX232 family in great detail, including the pin configuration and how to connect such an IC to external circuitry. Exactly to connect the RS232 signals to the IC. So here is one possible example:

MAX232 Pin Nbr. MAX232 Pin Name Signal Voltage DB9 Pin 7 8 9 10 11 12 13 14 15 T2out R2in R2out T2in T1in R1out R1in T1out GND CTS RTS RTS CTS TX RX RX TX GND RS-232 7 RS-232 8 TTL TTL TTL TTL n/a n/a n/a n/a

RS-232 2 RS-232 3 0 5

Table 5.3.2 RS232-DB9 pin Diagram

5.4 DC Motor
Introduction

Finger Print Based Security System Whenever a robotics hobbyist talk about making a robot, the first thing comes to his mind is making the robot move on the ground. And there are always two options in front of the designer whether to use a DC motor or a stepper motor. When it comes to speed, weight, size, cost... DC motors are always preferred over stepper motors. There are many things which you can do with your DC motor when interfaced with a microcontroller. For example you can control the speed of motor; you can control the direction of rotation. In this part of tutorial we will learn to interface and control of a DC motor with a microcontroller. Usually Hbridge is preferred way of interfacing a DC motor. These days many IC manufacturers have Hbridge motor driver available in the market like L293D is most used H Bridge driver IC. Hbridge can also be made with the help of transistors and MOSFETs etc. rather of being cheap, they only increase the size of the design board, which is sometimes not required so using a small 16 pin IC is preferred for this purpose. DC Motor Driver (L293D) 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 output 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. L293D Dual H-Bridge Motor Driver

Finger Print Based Security System

5.4 Pin diagram of L293D Motor Driver 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. 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 output diodes are included with in 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. A simple schematic for interfacing a DC motor using L293D is shown below.

Finger Print Based Security System

Figure DC Motor Driver

6. SOFT WARE REQUIREMENTS


Keil an ARM Company makes C compilers, macro assemblers, real-time kernels, debuggers, simulators, integrated environments, evaluation boards, and emulators for ARM7/ARM9/Cortex-M3, XC16x/C16x/ST10, 251, and 8051 MCU families. The Keil 8051 Development Tools are designed to solve the complex problems facing embedded software developers

Finger Print Based Security System Keil development tools for the 8051 Microcontroller Architecture support every level of software developer from the professional applications engineer to the student just learning about embedded software development. When starting a new project, simply select the microcontroller you use from the Device Database and the Vision IDE sets all compiler, assembler, linker, and memory options for you. Numerous example programs are included to help you get started with the most popular embedded 8051 devices. The Keil Vision Debugger accurately simulates on-chip peripherals (IC, CAN, UART, SPI, Interrupts, I/O Ports, A/D Converter, D/A Converter, and PWM Modules) of your 8051 device. Simulation helps you understand hardware configurations and avoids time wasted on setup problems. Additionally, with simulation, you can write and test applications before target hardware is available

EMBEDDED C:
Ex: Hitec c, Keil c

HI-TECH Software makes industrial-strength software development tools and C compilers that help software developers write compact, efficient embedded processor code. For over two decades HI-TECH Software has delivered the industry's most reliable embedded software development tools and compilers for writing efficient and compact code to run on the most popular embedded processors. Used by tens of thousands of customers including General Motors, Whirlpool, Qualcomm, John Deere and many others, HI-TECH's reliable development tools and C compilers, combined with world-class support have helped serious embedded software programmers to create hundreds of breakthrough new solutions. Which ever embedded processor family you are targeting with your software, whether it is the ARM, PICC or 8051 series, HI-TECH tools and C compilers can help you write better code and bring it to market faster. HI-TECH PICC is a high-performance C compiler for the Microchip PIC micro 10/12/14/16/17 series of microcontrollers. HI-TECH PICC is an industrial-strength ANSI C compiler - not a subset implementation like some other PIC compilers. The PICC compiler implements full ISO/ANSI C, with the exception of recursion. All data types are supported including 24 and 32 bit IEEE standard floating point. HI-TECH PICC makes full use of specific features and using an intelligent optimizer, can generate

Finger Print Based Security System high-quality code easily rivaling hand-written assembler. Automatic handling of page and bank selection frees the programmer from the trivial details of assembler code.

EMBEDDED C COMPILER

ANSI C - full featured and portable. Reliable - mature, field-proven technology. Multiple C optimization levels . An optimizing assembler. Full linker, with overlaying of local variables to minimize RAM usage. Comprehensive C library with all source code provided. Includes support for 24-bit and 32-bit IEEE floating point and 32-bit long data types.

Mixed C and assembler programming. Unlimited number of source files. Listings showing generated assembler. Compatible - integrates into the MPLAB IDE, MPLAB ICD . Runs on multiple platforms: Windows, Linux, UNIX, Mac OS X, Solaris.

EMBEDDED SYSTEM TOOLS


ASSEMBLER An assembler is a computer program for translating assembly language essentially, a mnemonic representation of machine language into object code. A cross assembler (see cross compiler) produces code for one type of processor, but runs on another. The computational step where an assembler is run is known as assembly time. Translating assembly instruction mnemonics into opcodes, assemblers provide the ability to use symbolic names for memory locations (saving tedious calculations and manually updating addresses when a program is slightly modified), and macro facilities for performing textual substitution

Finger Print Based Security System typically used to encode common short sequences of instructions to run inline instead of in a subroutine. Assemblers are far simpler to write than compilers for high-level languages. ASSEMBLY LANGUAGE HAS SEVERAL BENEFITS Speed: Assembly language programs are generally the fastest programs around. Space: Assembly language programs are often the smallest. Capability: You can do things in assembly which are difficult or impossible in High level languages. Knowledge: Your knowledge of assembly language will help you write better programs, even when using High level languages. An example of an assembler we use in our project is RAD 51. SIMULATOR Simulator is a machine that simulates an environment for the purpose of training or research. We use a UMPS simulator for this purpose in our project.

UMPS
Universal microprocessor program simulator simulates a microcontroller with its external environment. UMPS is able to simulate external components connected to the microcontroller. Then, debug step is dramatically reduced. UMPS is not dedicated to only one microcontroller family, it can simulate all kind of microcontrollers. The main limitation is to have less than 64K-Bytes of RAM and ROM space and the good microcontroller library. UMPS provide all the facilities other low-cost simulator does not have. It offers the user to see the "real effect" of a program and a way to change the microcontroller family without changing IDE. UMPS provide a low-cost solution to the problems. UMPS is really the best solution to your evaluation. UMPS KEY FEATURES The speed, UMPS can run as fast as 1/5 the real microcontroller speed. No need to wait 2 days to see the result of a LCD routine access. All the microcontroller parts are simulated, interrupts, communication protocol, parallel handshake, timer and so on. UMPS have an integrated assembler/disassembler and debugger. It is able to accept an external

Finger Print Based Security System assembler or compiler. It has a text editor which is not limited to 64K-bytes and shows keyword with color. It can also communicate with an external compiler to integrate all the debug facilities you need. UMPS is universal, it can easily be extended to other microcontroller with a library. Ask us for toolkit development. External resource simulation is not limited. It can be extended to your proper needs by writing your own DLL. UMPS allows you to evaluate at the lowest cost the possibility to build a microcontroller project without any cable. - UMPS include a complete documentation on each microcontroller which describe special registers and each instruction.

USER INTERFACES
User interfaces for embedded systems vary widely, and thus deserve some special comment. User interface is the ultimate aim for an embedded module as to the user to check the output with complete convenience. One standard interface, widely used in embedded systems, uses two buttons (the absolute minimum) to control a menu system (just to be clear, one button should be "next menu entry" the other button should be "select this menu entry"). Another basic trick is to minimize and simplify the type of output. Designs sometimes use a status light for each interface plug, or failure condition, to tell what failed. A cheap variation is to have two light bars with a printed matrix of errors that they select- the user can glue on the labels for the language that he speaks. For example, most small computer printers use lights labeled with stick-on labels that can be printed in any language. In some markets, these are delivered with several sets of labels, so customers can pick the most comfortable language. In many organizations, one person approves the user interface. Often this is a customer, the major distributor or someone directly responsible for selling the system. PLATFORM There are many different CPU architectures used in embedded designs such as ARM, MIPS, Coldfire/68k, PowerPC, X86, PIC, 8051, Atmel AVR, H8, SH, V850, FR-V, M32R etc. This in contrast to the desktop computer market, which as of this writing (2003) is limited to just a few competing architectures, mainly the Intel/AMD x86, and the Apple/Motorola/IBM PowerPC, used in the Apple Macintosh. With the growing acceptance of Java in this field, there is a tendency to even further eliminate the dependency on specific CPU/hardware (and OS) requirements.

Finger Print Based Security System Standard PC/104 is a typical base for small, low-volume embedded and ruggedized system design. These often use DOS, Linux or an embedded real-time operating system such as QNX or Inferno. A common configuration for very-high-volume embedded systems is the system on a chip, an application-specific integrated circuit, for which the CPU was purchased as intellectual property to add to the IC's design. A related common scheme is to use a fieldprogrammable gate array, and program it with all the logic, including the CPU. Most modern FPGAs are designed for this purpose.

TOOLS
Like typical computer programmers, embedded system designers use compilers, assemblers, and debuggers to develop embedded system software. However, they also use a few tools that are unfamiliar to most programmers. Software companies that specialize in the embedded market Ported from the GNU software development tools. Sometimes, development tools for a personal computer can be used if the embedded processor is a close relative to a common PC processor. Embedded system designers also use a few software tools rarely used by typical computer programmers. One common tool is an "in-circuit emulator" (ICE) or, in more modern designs, an embedded debugger. This debugging tool is the fundamental trick used to develop embedded code. It replaces or plugs into the microprocessor, and provides facilities to quickly load and debug experimental code in the system. A small pod usually provides the special electronics to plug into the system. Often a personal computer with special software attaches to the pod to provide the debugging interface. Another common tool is a utility program (often home-grown) to add a checksum or CRC to a program, so it can check its program data before executing it. An embedded programmer that develops software for digital signal processing often has a math workbench such as MathCad or Mathematical to simulate the mathematics. Less common are utility programs to turn data files into code, so one can include any kind of data in a program. A few projects use Synchronous programming languages for extra reliability or digital signal processing.

DEBUGGING

Finger Print Based Security System Debugging is usually performed with an in-circuit emulator, or some type of debugger that can interrupt the microcontroller's internal microcode. The microcode interrupt lets the debugger operate in hardware in which only the CPU works. The CPU-based debugger can be used to test and debug the electronics of the computer from the viewpoint of the CPU. This feature was pioneered on the PDP-11. As the complexity of embedded systems grows, higher level tools and operating systems are migrating into machinery where it makes sense. For example, cell phones, personal digital assistants and other consumer computers often need significant software that is purchased or provided by a person other than the manufacturer of the electronics. In these systems, an open programming environment such as Linux, OSGi or Embedded Java is required so that the third-party software provider can sell to a large market.

OPERATING SYSTEM
Embedded systems often have no operating system, or a specialized embedded operating system (often a real-time operating system), or the programmer is assigned to port one of these to the new system.

BUILT- IN SELF- TEST


Most embedded systems have some degree or amount of built-in self-test. There are several basic types. 1. Testing the computer. 2. Test of peripherals. 3. Tests of power. 4. Communication tests. 5. Cabling tests. 6. Rigging tests. 7. Consumables test. 8. Operational test.

Finger Print Based Security System

7. CODE GENERATION
#include<reg52.h> #include<lcd.h> #include<serial.h> #include<string.h> sbit SW sbit motor1 = P3^7; = P2^0;

unsigned char D[20]; unsigned char i,value; bit flag; void Disp_Hex(unsigned char); void FINGER_FUN_IDT(); // finger identification

Finger Print Based Security System void serial(void ) interrupt 4 { if (RI) { D[i] = SBUF; if (i>15){flag=1;} else i++; } }

void main() { bit scan_flag;

SConfig(); scan_flag=0;motor1= 0; LCD_Init(); LCD_Cmd(0x80); Disp_Str(" WELCOME ");

Delay(50);clear(); LCD_Cmd(0x80); Disp_Str(" finger print "); LCD_Cmd(0xC0); Disp_Str(" BASED PROJECT "); Delay(100); LCD_Cmd(0x80); Disp_Str(" PRESS SWITCH ");

Finger Print Based Security System while(1) { LCD_Cmd(0x80);Disp_Str(" PRESS SWITCH "); if (SW==0) //scanning switch { // infinite loop

FINGER_FUN_IDT(); EA=1;ES=1; Delay(300); } if (flag==1) { flag=0;

//command identify function

if (D[12] == 0x00 && D[13] == 0x00 && D[14] == 0x00) { scan_flag=1; LCD_Cmd(0x80); Disp_Str(" VALID ");

LCD_Cmd(0xC0); Disp_Str(" } else if (D[12] == 0x00 && D[13] == 0x00 && D[14] == 0x01) { scan_flag=1; LCD_Cmd(0x80); Disp_Str(" VALID "); PERSON1 ");

LCD_Cmd(0xC0);

Finger Print Based Security System Disp_Str(" } else if (D[12] == 0x00 && D[13] == 0x00 && D[14] == 0x02) { scan_flag=1; LCD_Cmd(0x80); Disp_Str(" VALID "); PERSON2 ");

LCD_Cmd(0xC0); Disp_Str(" } else if (D[12] == 0x02) { LCD_Cmd(0xC0); Disp_Str("NO F.P ON SENSOR"); } else if (D[12] == 0x09) { LCD_Cmd(0xC0); Disp_Str("NO F.Pwere FOUND"); } EA=ES=0; } PERSON3 ");

if (scan_flag==1) { Delay(100); LCD_Cmd(0x80); Disp_Str(" DOOOR OPEN ");

Finger Print Based Security System motor1=0; Delay(600); LCD_Cmd(0x80); Disp_Str(" DOOR CLOSED "); motor1=1; Delay(600); motor1=0; }

//infinite loop end

// main loop end

void FINGER_FUN_IDT() { Send_Char(0xEF);Send_Char(0x01); Send_Char(0xFF);Send_Char(0xFF);Send_Char(0xFF);Send_Char(0xFF); Send_Char(0x01); Send_Char(0x00);Send_Char(0x03); Send_Char(0x01); Send_Char(0x00);Send_Char(0x05); }

Finger Print Based Security System

8.CONCLUSION

The project has been successfully implemented. In conclusion, FINGER PRINT BASED SECURITY SYSTEM is used to provide security and authentication for an organization using finger prints as forgery of that is not possible. The project report began with the introduction to the basic functioning of Microcontroller based Identification, Authentication and Setup of Security system. Project deals with Microcontroller as central controlling units for various other sections like Biometrics FIM 3030 module, LCD etc. Interfacing between all sections required for system and microcontroller 89S52 has been done successfully. For registration interfacing between biometrics module and personal computer has also been done successfully. When a new person who is not register with the system try to have access, system refuses access and displays message Unidentified FP. For the person who is registered with the system can get access through doors according to their designation. Doors opening and closing has been achieved successfully.

Finger Print Based Security System

9. FUTURE SCOPE
In this project we are using fingerprint module. It is most widely used for security purposes. This project is depend on the biometrics i.e fingerprint. It is very easy to implement because Each person has his own fingerprints with the permanent uniqueness. Compare to normal security system it is better and in this we can further to implement in every office that module contains total information of employes. When a finger is kept at the finger print reader, it will give the information accordingly to microcontroller by sending appropriate commands to the reader. If the information matches with the one within the device then the DC motor interfaced to the microcontroller responds accordingly. And if the information provided by the user is incorrect or mismatch in finger prints is detected then access is denied. Finger print reader and the microcontroller unit are connected using serial interface. In future this system is used to provide security and authentication for an organization using finger prints as forgery of that is not possible.

Finger Print Based Security System

10. BIBLIOGRAPHY
NAME OF THE SITES

www.at89s52.com/pdf/ www.microchips.com www.max232n.com/texas www.mikroelektronika.co.yu/english/product/books/PICbook/0_Uvod. www.wikipedia.com www.atmel.databook.com

BOOKS

Customizing and programming microcontroller-Myke Predcko-TMH publication2000 FIM30 user manual. C programming for embedded systems- Kirk Zurell 8051 and embedded system by Mazid and Mazidi Embedded Microcomputer system- onathan w.Valvano PHI publication2000 microcontroller inter facing- Douglas v.hall TMH publication-2000