1. UNIT III
Interfacing and Programming
Dr. P. H. Zope
SSBT’s College of Engineering and Technology Bambhori Jalgaon
North Maharashtra University
phzope@gmail.com
9860631040
2. 1. What is Interfacing and Need of interfacing.
2. Different Interfacing techniques.
3. Basic embedded C programs for on-chip peripherals
studied in system architecture.
4. Interfacing of different displays including Graphic LCD
(320X240), Interfacing of input devices including touch
screen etc,
5. Interfacing of output devices like thermal printer etc.,
6. Embedded communication using CAN and Ethernet,
7. RF modules, GSM modem for AT command study etc.
Topics
3. An interface is the point of interaction with software, or computer
hardware, or with peripheral devices such as a computer monitor or
a keyboard.
Some computer interfaces such as a touch screen can send and
receive data, while others such as a mouse, microphone or joystick
can only send data.
Types of Interfacing
1. Hardware
2. Software
What is Interfacing
4. Hardware interfaces
Hardware interfaces exist in computing systems between many of
the components such as the various buses, storage devices,
other I/O devices, etc.
A hardware interface is described by the mechanical, electrical and
logical signals at the interface and the protocol for sequencing
them (sometimes called signaling).
A standard interface, such as SCSI, decouples the design and
introduction of computing hardware, such as I/O devices, from the
design and introduction of other components of a computing
system, thereby allowing users and manufacturers great flexibility
in the implementation of computing systems.
Hardware interfaces can be parallel where performance is
important or serial where distance is important.
5. Software interfaces
A software interface may refer to a wide range of different types of
interface at different "levels": an operating system may interface
with pieces of hardware.
Applications or programs running on the operating system may need
to interact via streams, and in object oriented programs, objects
within an application may need to interact via methods.
6. Programming to the interface
The use of interfaces allows a programming style
called programming to the interface.
The idea behind this is to base programming logic on the interfaces
of the objects used, rather than on internal implementation details.
Programming to the interface reduces dependency on
implementation specifics and makes code more reusable.
It gives the programmer the ability to later change the behavior of
the system by simply swapping the object used with another
implementing the same interface.
7. Benefits
1.Low cost
2.Easy interfacing & Design
3.Easy Production
4.users choice for interfacing
5.No Maintenance
6.Easier Handling
Disadvantages
1.Compact size is not possible
2.Power consumption is more as compared to SOC
3.Leakage current is more
4.Limited Devices Addressing
5.No Support of Multi/ Master configuration
9. ROM image creation in an Embedded System
Process of converting C , C ++ -program into ROM image
and ready to use
To make the application run independently with the specific board one can
follow the steps given below so that the application developed on the host
system, after cross compiling the same for specific image and specific board
The step wise process is as follows :
To write your first program, you'll need to have the following
software installed on your system:
• Triton IDE installed
• JRE of version 1.5 or higher ( provided in Triton IDE setup)
• Philips Utility ( provided in Triton IDE setup)
10. Setting up the Project
To create an IDE project:
• Start Triton IDE.
• Select the workspace in which you can create all your projects as
shown in the figure below. Click OK.
Triton IDE C/C++ Environment opens as shown in below figure in
which you can create new project, open existing one etc.
11.
12. To create new project go to Project menu New C Project.
You will get below figure.
In the Project Name field, type keypad.
o Select the Target as per the board you have.
o Select the Variant from the variant list.
o Select Operating System as per your requirement.
o Select the Port from Port field.
o Select the Baud Rate.
o Select the Build options.
o Select the Download options
o Select the Debug type
o You can also change the location of project.
For that uncheck use default location.
o Check Create Project Using Template.
13. Click Next.
• Belo s ree ill appear. “ele t De ug a d
Release configurations.
14. Click Finish.
The project is created and opened in the IDE. You should see the following components:
• The Proje ts i do , hi h o tai s a tree ie of the o po e ts of the project, including
source files and properties file that your code depends on. .
• The “our e Editor i do ith a file alled ke pad_ ai . ope .
15.
16. Adding Code to the Generated Source File
Because you have left the Create Project Using Template checkbox selected in the New
Project wizard, the IDE has created a skeleton class for you. You can add your keypad
code to the skeleton code by replacing the line:
//TODO: You can write your code at here
Sample code for Keypad
-------------------------------
#include <board.h>
int main(void)
{
char key;
q_keyinit(SPIRIT);
q_lcdinit(SPIRIT); /* initialise the LCD*/
q_printf("%s rnkey;","Hello");
q_displaylcd("Hello", 5);
while(1)
{
while((key = q_keyread()) == 0);
key = key + 0x30;
q_clrscreen();
q_printf("%x n", key);
q_displaylcd(&key, 1);
}
}
Save the change by choosing File > Save.
17. Compiling the Project
To compile project you need to select Debug or Release mode.
• Debug mode: This creates an executable which you after
downloading on the target board are able to debug.
• Release mode: This creates an executable which you can download
on the target board but you won’t be able to debug.
• Right click on the keypad project and point to Active Build
Configuration and select Release as shown in the below screen.
18.
19. •To build Project right click on keypad project and select Build Project.
• Open the build console view to check for any errors as shown in the below figure.
20. If your project has built successfully *.hex will be created.
• If there are any errors in the project Build Console view will display the error
messages and from Build Output view you can check the location of errors in your
code.
• When you build the project, the keypad.hex is generated. You can see where
the new file is generated by opening the C/C++ Projects view and expanding the
keypad project node as shown in the following figure.
Now that you have built the
project, you download executable
on target board and run the
program.
21. Downloading the Program
• I Trito IDE e e uta le a e do loaded three optio s:
ISP Utility, Odyssey JTAG and FTP.
• “ele t the appropriate do load optio a d right li k o the *.he file ge erated
and click Download as shown below.
After successful download of
program you can check the
application by running it
on target board.
22.
23.
24.
25.
26.
27. Debugging the Program
In Triton IDE you can debug your program by three options:-
Monitor, Odyssey JTAG and Ethernet.
• As per your requirement select appropriate option for debugging and build the
project in debug mode (same step as Release mode)
• After compilation download the generated executable and you can now debug the
project.
• Right click on the project and select Debug As and click Debug Local C/C++
Application.
28.
29.
30. 330_09 30
GPIO - General purpose input/output.
FEATURES
• Direction control of individual bits
• Separate control of output set and clear
• All I/O default to inputs after reset
APPLICATIONS
• General purpose I/O
• Driving LEDs, or other indicators
• Controlling off-chip devices
• Sensing digital inputs
31. 330_09 31
IOPIN
GPIO Port Pin value register. The current state of the port pins
can always be read from this register, regardless of pin
direction and mode.
IOSET
GPIO Port Output set register. This register controls the state
of output pins in conjunction with the IOCLR register. Writing
ones produces highs at the corresponding port pins. Writing
zeroes has no effect.
IODIR
GPIO Port Direction control register. This register individually
controls the direction of each port pin.
IOCLR
GPIO Port Output clear register. This register controls the state
of output pins. Writing ones produces lows at the
corresponding port pins and clears the corresponding bits in
the IOSET register. Writing zeroes has no effect.
36. Seven-Segment Display
Seven-segment Displays
Used to display BCD digits
0 thru 9
A group of 7 LEDs physically
mounted in the shape of the
number eight
Plus a decimal point
Each LED is called a segment
‘a’ through ‘g’
Two types
Common anode
Common cathode
36330_09
37. Seven-Segment Display
Common Anode
All anodes are connected together to a power supply
Cathodes are connected to data lines
Logic 0 turns on a segment
Example: To display the digit 1
All segments except b and c should be off
11111001 = F9H
37330_09
Common Anode
38. Interface Seven-Segment Display
Common Cathode
All cathodes are connected together to ground
Anodes are connected to data lines
Logic 1 turns on a segment
Example: To display digit 1
All segments except b and c should be off
00000110 = 06H
38330_09
54. Interfacing Push-Button Keys
When a key is pressed (or released), mechanical metal contact
bounces momentarily and can be read as multiple inputs
Key debounce
Eliminating reading of one contact as multiple inputs
Hardware or Software
54330_09
55. Key Debounce Techniques
Hardware technique
Two NAND gates
S-R latch
The output of the latch is
a pulse without a bounce
Software technique
Wait for 10 to 20 ms
after detection of a
switch closure
If the reading is still the
same it is accepted
330_09 55
56. Interfacing a Matrix Keypad
Problem statement
Interface a 4 x 4 Hex keypad to ARM-7
Write a program to recognize a key pressed and
encode the key in its binary value
Display binary code on LCD
56330_09
57. Interfacing a Matrix Keypad
PIC18 Simulator Keypad Matrix
57330_09
1
4
7
A
2
5
8
0
3
6
9
B
C
D
E
F
58. Time Multiplex Scanning
Software
Codes of the numbers to be displayed are stored in data
registers in sequence
The program gets the codes from the data registers by
using the pointer (FSR0) and sends them out to the LED
segments through PORTB
One display at a time is turned on by sending logic 1 to the
corresponding transistor connected to PORTC
After an appropriate delay, the first display is turned off
and the next display is turned on
Turning displays on/off is repeated in sequence
58330_09
59. Interfacing LCD
Problem statement
Interface a 2-line x 16 character LCD module
with the built-in HD44780 controller to I/O ports
of the ARM-7 microcontroller.
Explain the control signals necessary to read
from and write to the LCD.
Write a program to display ASCII characters.
59330_09
60. Interfacing LCD
Hardware
16 x 2-line LCD display
Two lines with 16 characters per line
LCD has a display Data RAM
Stores data in 8-bit character code
Each register in Data RAM has its own address
60330_09
63. Interfacing LCD
Driver HD44780
8-bit data bus (RD7-RD0)
Three control signals
RS – Register Select
R/W – Read/Write
E – Enable
Three power connections
Power, ground, and variable resistor to control brightness
63330_09
64. Interfacing LCD
Can be interfaced either in 8-bit mode or 4-bit mode
In 8-bit mode, all eight data lines are connected
In 4-bit mode, only four data lines are connected
Two transfers per character (or instruction) are needed
Driver has two 8-bit internal registers
Instruction Register (IR) to write instructions to set up LCD
Table 9-3
Data Register (DR) to write data (ASCII characters)
64330_09
65. 330_09 65
Pin No Symbol I/O Description
1 Vss - Ground
2 Vcc +5V
3 Vee Contrast Control
4 RS Input Command/Data Register
5 R/W Input Read/Write Register
6 E Input/Output Enable
7 DB0 Input/Output Not Used in 4-Bit Mode
8 DB1 Input/Output Not Used in 4-Bit Mode
9 DB2 Input/Output Not Used in 4-Bit Mode
10 DB3 Input/Output Not Used in 4-Bit Mode
11 DB4 Input/Output Data Bus in 4-Bit Mode
12 DB5 Input/Output Data Bus in 4-Bit Mode
13 DB6 Input/Output Data Bus in 4-Bit Mode
14 DB7 Input/Output Data Bus in 4-Bit Mode
15 Vcc - For LCD Back Light
16 Vss - For LCD Back Light
LCD Pin Description
67. Interfacing LCD
LCD Operation
When the MPU writes an instruction to IR or data to DR,
the controller:
Sets DB7 high indicating that the controller is busy
Sets DB7 low after the completion of the operation
The MPU should always check whether DB7 is low
before sending an instruction or a data byte
67330_09
68. Interfacing LCD
Writing to or Reading from LCD
The MPU:
Asserts RS low to select IR
Asserts RS high to select DR
Reads from LCD by asserting the R/W signal high
Writes into LCD by asserting the R/W signal low
Asserts the E signal high and then low (toggles) to latch a data
byte or an instruction
68330_09
70. Interfacing LCD
Software
To write into the LCD
Send the initial instructions to set up the LCD
4-bit or 8-bit mode
Continue to check DB7 until it goes low
Write instructions to IR to set up LCD parameters
Number of display lines and cursor status
Write data to display a message
70330_09
71. 330_09 71
Pin Assignment: LCD display interface
Sr. No. Signal Description
1 Pin 16 (P1.16) Data 0
2 Pin 12 (P1.17) Data 1
3 Pin 8 (P1.18) Data 2
4 Pin 4 (P1.19) Data 3
5 Pin 48 (P1.20) Data 4
6 Pin 44 (P1.21) Data 5
7 Pin 40 (P1.22) Data 6
8 Pin 36 (P1.23) Data 7
9 Pin 13 (P0.28) RS
10 Pin 14 (P0.29) EN
11 GND WR
83. 330_09 83
STEPPER MOTOR CHARACTERISTICS
•Stepper motors are constant-power devices (power = angular velocity x torque).
•As motor speed increases, torque decreases.
•The torque curve may be extended by using current limiting drivers and
increasing the driving voltage.
•Steppers exhibit more vibration than other motor types, as the discrete step tends
to snap the rotor from one position to another.
•This vibration can become very bad at some speeds and can cause the motor to
lose torque.
•The effect can be mitigated by accelerating quickly through the problem speed
range, physically damping the system, or using a micro-stepping driver.
•Motors with greater number of phases also exhibit smoother operation than those
with fewer phases.
84. 84
Computer-controlled stepper motors are one of the most versatile
forms of positioning systems . They are typically digitally
controlled as part of an open loop system, and are simpler and
more rugged than closed loop servo systems. Industrial applications
are in high speed pick and place equipment and multi-axis machine
CNC machines often directly driving lead screws or ball screws .
In the field of lasers and optics they are frequently used in precision
positioning equipment such as linear actuators , linear stages ,
rotation stages and mirror mounts . Other uses are in packaging
machinery, and positioning of valve pilot stages for fluid control
systems. Commercially, stepper motors are used in floppy disk
drives , flatbed scanners , computer printers , plotters and many
more devices.
APPLICATIONS
90. What is GSM ?
Global System for Mobile (GSM) is a
second generation cellular standard
developed to cater voice services and
data delivery using digital modulation
92. 92
Introduction:
GSM (Global System for Mobile) / GPRS (General Packet Radio Service)
TTL –Modem is SIM900 Quad-band GSM / GPRS device, works on
frequencies 850 MHZ, 900 MHZ, 1800MHZ and 1900 MHZ. It is very
compact in size and easy to use as plug in GSM Modem. The Modem is
designed with 3V3 and 5V DC TTL interfacing circuitry, which allows
User to directly interface with 5V Microcontrollers (PIC, AVR, Arduino,
8051, etc.) as well as 3V3Microcontrollers (ARM, ARM Cortex XX, etc.).
The baud rate can be configurable from 9600-115200 bps through AT
(Attention) commands. This GSM/GPRS TTL Modem has internal TCP/IP
stack to enable User to connect with internet through GPRS feature. It is
suitable for SMS as well as DATA transfer application in mobile phone to
mobile phone interface.
The modem can be interfaced with a Microcontroller using USART
(Universal Synchronous Asynchronous Receiver and Transmitter) feature
(serial communication).
93. 330_09 93
Features:
Quad Band GSM/GPRS : 850 / 900 / 1800 / 1900 MHz
Built in RS232 to TTL or viceversa Logic Converter (MAX232)
Configurable Baud Rate
SMA (SubMiniature version A) connector with GSM L Type
Antenna
Built in SIM (Subscriber Identity Module) Card holder
Built in Network Status LED
Inbuilt Powerful TCP / IP (Transfer Control Protocol / Internet
Protocol) stack for internet data transfer through GPRS (General
Packet Radio Service)
Audio Interface Connectors (Audio in and Audio out)
Most Status and Controlling pins are available
Normal Operation Temperature : -20 °C to +55 °C
Input Voltage : 5V to 12V DC
LDB9 connector (Serial Port) provided for easy interfacing
95. 330_09 95
SIMCom SIM900A GSM Module:
This is actual SIM900 GSM module which is manufactured by SIMCom. Designed
for global market, SIM900 is a quad-band GSM/GPRS engine that works on
frequencies GSM 850MHz, EGSM 900MHz, DCS 1800MHz and PCS 1900MHz.
SIM900 features GPRS multislot class 10/ class 8 (optional) and supports the
GPRS coding schemes CS-1, CS-2, CS-3 and CS-4. With a tiny configuration of
24mm x 24mm x 3mm, SIM900 can meet almost all the space requirements in
User’s applications, such as M2M, smart phone, PDA and other mobile devices.
96. 330_09 96
MAX232 IC:
The MAX232 is an integrated circuit that converts signals from an RS-232 serial
port to signals suitable for use in TTL compatible digital logic circuits, so that
devices works on TTL logic can share the data with devices connected through
Serial port (DB9 Connector).
97. 330_09 97
Serial port / DB9 connector:
User just needs to attach RS232 cable here so that it can be connected to devices
which has Serial port / DB9 Connector.
98. 330_09 98
Power Supply Socket:
This power supply socket which actually named as AC/DC Socket provides the
functionality to user to connect external power supply from Transformer, Battery or
Adapter through DC jack. User can provide maximum of 12V AC/DC power supply
through AC/DC socket. This is power supply designed into maximum protection
consideration so that it can even prevent reverse polarity DC power supply as well
as DC conversion from AC power Supply. It also includes LM317 Voltage Regulator
which provides an output voltage adjustable over a1.2V to 37V.
99. 330_09 99
Power On/Off and GSM On Switch:
Power On/Off switch is type of push-on push-off DPDT switch which is used for
only make power supply on/off provided through AC/DC Socket indicated by
‘Power LED’. GSM On Switch is type of Push on DPST tactile switch which is
used for only to make GSM module ‘On’indicated by ‘Module On/Off LED’while
initiating with Network indicated by ‘Network Indication LED’.
100. 330_09 100
SIM (Subscriber Identity Module) Card Slot:
This onboard SIM card slot provide User functionality of insert a SIM (GSM
only) card of any service provider. Process of inserting and locking SIM card into
SIM card slot is given in this manual. While inserting in and removing out SIM
card from SIM card slot, User needs to take precaution that power supply should
be OFF so that after making Power supply ON it will be easy to reinitialize with
SIM for this module.
101. 330_09 101
Indicator LEDs:
Indicator LEDs just used to indicate status accordingly. These are three LEDs
represents Power On/Off Status, Network Status and Module On/Off Status
respectively. Power LED will keep on until the power supply is enable to this board
by using push-on push-off switch. Network Status LED will show whether inserted
SIM card successfully connected to service provider’s Network or not, in short
signal strength. Module On/Off indicator LED will show status of GSM
module’s power on/off.
102. 330_09 102
RXD, TXD and GND pins (JP2):
These pins are used to connect devices which needs to be connected to GSM
module through USART (Universal Synchronous Asynchronous Receiver and
Transmitter) communication. Devices may be like Desktop or Laptop Computer
System, Microcontrollers, etc. RXD (Receive Data) should be connected to TXD
(Transmit Data) of other device and viceversa, whereas GND (Ground) should be
connected to other device’s GND pin to make ground common for both systems.
103. 330_09 103
Audio Connectors:
Audio Connectors deals with Audio related operations. These pins already shown
in hardware description diagram. These are eight pins in a group of two each
denoted by SV4.
GND (0V Supply) and VCC (+5V Supply) are used to have source for external
device. MIC+ and MICused to connect Microphone (abbr. as Mic) through which
user can give audio input while calling. SP- and SP+ used to connect Speaker (can
be connected to amplifier circuit if necessary) through which User can hear audio
output. LN-L and LN-R used to connect Line in to GSM module.
104. 330_09 104
Debugger (DBG-R and DBG-T) Connectors (J2):
These connectors are 2-wire null modem interface DBG_TXD and DBG_RXD.
These pins can be used for debugging and upgrading firmware. User generally no
need to deal with these pins.
105. 330_09 105
Inserting SIM card into SIM card Slot/Holder:
Here is the process how to insert SIM card into SIM card slot. User just need to
unlock SIM card cover by sliding back. Then user need to open this cover and
insert SIM card according to slot. Put down cover on SIM card and then lock by
sliding forward.
106. 330_09 106
Power On/Off and Module On/Off process:
Here is the process how User should make power supply on/off and module on/off.
First of all User need to connect external power supply by using Battery / Adapter /
Transformer. Now User needs to press Power On/Off switch (It is push-on push-off
switch, thus User need to push it to make power on and push it again to make power
supply off). Two LEDs will glow, one is Power On/Off indicator LED and another
one is Network Status LED (which glows continuous to indicate no network or
searching for network). After this User needs to press Module on switch (denoted as
PWR) for at least 2 seconds. As soon as Module On/Off LED will glow User can
release this switch, Network LED will blink to indicate signal strength.
107. 330_09 107
Connecting GSM module with RS232 (SB9-DB9) Serial Cable:
User can connect GSM interfacing board either through Serial port or
through Serial to USB converter. Here is process to connect RS232 cable to GSM
interfacing board.
108. 330_09 108
Connecting GSM Module with Serial to USB converter through
RXD, TXD and GND:
This module is designed in a way so that User can connect this module without
Serial cable, this module can be connected to any of Serial to USB converter
module or cable. Here we have shown demo how to connect this interfacing board
with CP2102 Serial to USB converter Module through RXD, TXD and GND.
Connect CP2102 Serial to USB converter module to PC through USB cable,
connect one end of USB cable to PC’s USB connector and connect another end of
USB to CP2102 module’s USB connector.
109. 330_09 109
Connect three Single Berg Wires to CP2102 modules’s RXD, TXD and GND pin.
Then connect RXD wire to TXD of GSM module and TXD wire to RXD of GSM
module. Make GND common by connecting GND wire to GND pin of GSM
module.
110. 330_09 110
Various AT commands for GSM modem
Call command:-
•For dialing number
Step 1 – ATD (enter the number)
Step 2 - ;
Step 3 - < Press Enter >
•For answering the call when the RING text appear
continuously on hyper terminal
Step 1 – ATA
Step 2 - <Press Enter>
111. 330_09 111
•For terminating call
Step 1 – ATH
Step 2 - <Press Enter>
•For enables caller number
Step 1 – AT + CLIP = 1
Step 2 - <Press Enter>
CLIP- Calling Line Identification Presentation
112. 330_09 112
SMS Command:-
1. To read SMS automatic to terminal
Step 1 – AT + CMGF = 1 // for text mode operator
Step 2 – AT + CNMI = 1 // automatic sensing
CMGF –Message Format
CNMI - New Message Indication to Terminal Equipment
2. To send SMS
Step 1 – AT + CMGS = Enter mobile number
Step 2 - <Press Enter>
Step 3 – Enter Text
Step 4 – Press ctrl + Z
CMGS – Send Message
3. For acknowledge SMS (if not acknowledge the SMS, SMS server
will resend SMS)
Step 1 – AT + CNMA
CNMA – Message Acknowledge
113. 330_09 113
COM 1
DB9-
Female
data 2
GND-3
GPIO (CN/4) 2-9, 49, 50
(With CNB) 13-22, 47 GND
(with (N/4)
CN 13, 1-,
14 7,8,19,20
CN 13, 1-,
10 19,20
Keypad
(4 × 4)
LCD DISPLAY
GSM
RS – 238
Cable
Null male-male
connector
FRC
Cable
GSM antenna
Power supply
ARM
PROCESSOR
/BOARD
Interfacing GSM with ARM
Board
114. GSM Applications
Mobile telephony
GSM-R
Telemetry System
- Fleet management
- Automatic meter reading
- Toll Collection
- Remote control and fault reporting of DG sets
Value Added Services
116. 330_09 116
FIM:- Fingerprint Identification Module
FIM is a 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 a wide range of applications.
It is a durable and compact device with fingerprint identification module
containing NITGEN® optics – based fingerprint sensor inside.
117. 117
Interface: FBI-compliant scanners often have analogue output and a frame grabber is
necessary to digitize the images. This introduces an extra cost and usually requires an internal
board to be mounted in the host. In non-AFIS devices, the analogue-to-digital conversion is
performed by the scanner itself and the interface to the host is usually through a simple
Parallel Port or USB connection.
Frames per second: This is the number of images the scanner is able to acquire and send to
the host in a second.
Automatic finger detection: Some scanners automatically detect the presence of a finger on
the acquisition surface, without requiring the host to continually grab and process frames; this
allows the acquisition process to be automatically initiated as soon as the user’s finger touches
the sensor.
Encryption: This is the securing of the communication channel between the scanner and the
host.
Supported operating systems: Compatibility with more operating systems is an important
requirement.
Fingerprint Scanners and their Features
118. 118
Resolution: This indicates the number of dots or pixels per inch (dpi).
Area: The size of the rectangular area sensed by a fingerprint scanner is a
fundamental parameter. The larger the area, the more ridges and valleys are
captured and the more distinctive the fingerprint becomes.
Number of Pixels: This can be derived from the resolution and the fingerprint area.
A scanner working at r dpi over an area of height (h) X width (w) inch2 has rh X
rw pixels.
Dynamic range (or depth): This denotes the number of bits used to encode the
intensity value of each pixel.
Geometric accuracy: This is specified by the maximum geometric distortion
introduced by the acquisition device, and expressed as a percentage with respect to
x and y directions.
Image quality: The image quality depends on the quality of scanner and also on
the intrinsic finger status. When the ridge prominence is very low (for manual
workers, elderly people), or fingers are too moist or too dry, most scanners produce
poor quality images.
Characteristics of Fingerprint Images
122. 330_09 122
Communication:-
FIM has RS – serial communication port through that FIM communicates at the
same time.
These ports support 6 baud rate modes such as 9600, 14400, 19200, 38400, 57600
and 115200 bps.
User Data Area:-
FIM provides 64 bytes flash memory. Using this memory, host can save
private data for specific usage.
The caution is needed because the responsibility for reading, writing and
erasing user data area is given to the best.
Key Function:-
FIM supports 3 function key input such as Enroll _ Key, Delete _ Key, and
Identify _ Key.
Using these keys without serial communication, enrollment, deletion, all
deletion and identification operating can be executed.
124. 124
Fingerprint sensing
Based on the mode of acquisition, a fingerprint image is classified
as
Off line image
Live-scan image
There are a number of live-scan sensing mechanisms that can
detect the ridges and valleys present in the fingertip
Examples are
Optical FTIR
Capacitive
Pressure-based
Ultrasound
127. 127
Interface: FBI-compliant scanners often have analogue output and a frame grabber is
necessary to digitize the images. This introduces an extra cost and usually requires an internal
board to be mounted in the host. In non-AFIS devices, the analogue-to-digital conversion is
performed by the scanner itself and the interface to the host is usually through a simple
Parallel Port or USB connection.
Frames per second: This is the number of images the scanner is able to acquire and send to
the host in a second.
Automatic finger detection: Some scanners automatically detect the presence of a finger on
the acquisition surface, without requiring the host to continually grab and process frames; this
allows the acquisition process to be automatically initiated as soon as the user’s finger touches
the sensor.
Encryption: This is the securing of the communication channel between the scanner and the
host.
Supported operating systems: Compatibility with more operating systems is an important
requirement.
Fingerprint Scanners and their Features
128. 128
The most important part of a fingerprint scanner is the sensor.
Sensors belong to one of the three families:
Optical sensors
• Frustrated Total Internal Reflection (FTIR)
• FTIR with a sheet prism
• Optical fibers
• Electro-Optical
Solid-state sensors
• Thermal
• Electric field
• Piezoelectric
Ultrasound sensors
Fingerprint Sensing
129. 129
Frustered Total Internal Reflection (FTIR):
The oldest and most used livescan technique.
The finger touches the top side of a glass
prism, but while the ridges enter in contact
with the prism surface, the valleys remain
at a certain distance. The left side of the
prism is illuminated through a diffused
light which is reflected at the valleys and
randomly scattered (absorbed) at the ridges.
The lack of reflection allows the ridges
(appear dark) to be discriminated from the
valleys (appear bright). The light rays exit
from the right side of the prism and are
focused through a lens onto a CCD or
CMOS image sensor. Because FTIR
devises sense a 3D surface, they cannot be
easily deceived by a photograph or printed
image of a fingerprint.
Fingerprint Sensing: optical FTIR
130. 130
FTIR with a sheet prism: Using a sheet prism made of a number of “prismlets”
adjacent to each other, instead of a single large prism, allows the size of the
mechanical assembly to be reduced to some extent. However, the quality of the
acquired images is generally lower than the traditional FTIR techniques using glass
prisms.
Fingerprint Sensing: FTIR with a sheet prism
131. 131
A significant reduction of the packaging size can be achieved by substituting prism and
lens with a fiber-optic platen. The finger is in direct contact with the upper side of
the platen; on the opposite side, a CCD or CMOS, tightly coupled with the platen,
receives the finger residual light conveyed through the glass fibers. Unlike the FTIR
devices, the CCD/CMOS is in direct contact with the platen and therefore its size
has to cover the whole sensing area. This may result in a high cost for producing
large area sensors.
Optical Fibers
134. 134
Thermal: These sensors are made of pyro-electric material that generates current based
on temperature differentials. The fingerprint ridges, being in contact with the sensor
surface, produce a different temperature differential than the valleys, which are
away from the sensor surface. The sensors are typically maintained at a high
temperatures.
Electric Field: The sensor consists of a drive ring that generates a sinusoidal signal and
a matrix of active antennas that receives a very small amplitude signal transmitted
by the drive ring and modulated by the derma structure (subsurface of the finger
skin). The finger must be simultaneously in contact with the sensor and the drive
ring. To image a fingerprint, the analogue response of each element in the sensor
matrix is amplified and digitized.
Piezoelectric: Pressure-sensitive sensors produce an electrical signal when mechanical
stress is applied to them. The sensor surface is made of a non-conducting dielectric
material which generates a small amount of current. Since ridges and valleys are
present at different distances from the sensor surface, result in different currents.
Solid State Sensing
135. 135
Ultrasound sensing is based on sending acoustic signals toward the fingertip and
capturing the echo signal. The echo signal is used to compute the range
image of the fingerprint and subsequently, the ridge structure itself. This
method images the subsurface of the finger skin (even through thin gloves).
Therefore, it is resilient to dirt and oil accumulations that may visually mar
the fingerprint. However, the scanner is large with mechanical parts and
quite expensive. Moreover, it takes a few seconds to acquire an image.
Ultrasound sensors
137. 137
The touch method is most commonly used with sensors wherein the finger is
simply put on the scanner, without moving it.
To reduce costs, especially in silicon sensors, another sensing method has been
proposed: to sweep the finger over the sensor. Since the sweeping consists
of a vertical movement only, the chip must be as wide as a finger; on the
other hand, in principle, the height could be as low as one pixel. At the end
of the sweep, a single fingerprint image is reconstructed from the slices.
Image reconstruction from slices
138. 138
The sweep method allows the cost of a sensor to be significantly reduced, but requires
reliable reconstruction to be performed. The main stages of the reconstruction are:
Slice quality computation: For each slice, a single global quality measure and several local
measures are compared by using an image contrast estimator.
Slice pair registration: For each pair of consecutive slices, the only possible transformation
is assumed to be a global translation [∆x, ∆y], where the ∆y component is dominant, but a
limited ∆x is also allowed to cope with lateral movements of the finger during sweeping.
Relaxation: When the quality of slices is low, the registration may fail and give incorrect
translation vectors. Assuming a certain continuity of the finger speed during sweeping allows
analogous hypotheses to be generated on the continuity of the translation vectors. The
translation vectors’ continuity may be obtained through a method called relaxation which has
the nice property of smoothing the samples without affecting the correct measurements too
much.
Mosaicking: The enhanced translation vectors produced by the relaxation stage are used to
register and superimpose the slices. Finally, each pixel of the reconstructed output image is
generated by performing a weighted sum of the intensities of the corresponding pixels in the
slices.
Image reconstruction from slices
140. 140
The cost of a sensor increases with increase in size of sensing area.
With smaller areas, the identification accuracy may deteriorate.
Sensing Area vs. Accuracy
144. 144
The Wavelet Scalar Quantization (WSQ) is an effective compression
technique (achieves compression ratio of 10 to 25).
The WSQ encoder performs the following steps:
1. The fingerprint image is decomposed into a number of spatial
frequency sub-bands (typically 64) using a Discrete Wavelet
Transform (DWT).
2. The resulting DWT coefficients are quantized into discrete values;
results in some loss of information.
3. The quantized sub-bands are concatenated into several blocks
(typically three to eight) and compressed using an adaptive Huffman
run-length encoding.
Compressing Fingerprint Images