Electronic Voting Machine
Electronic Voting Machine
TABLE OF CONTENTS
Page
Declaration.iii
Acknowledgement .iv
Table of contents ...v
Abstract ..vii
List of Figures.ix
iv
List of Tables
Table 4.1: Pin Configuration of Fingerprint Scanner42
List of Figures
Page
vii
ABSTRACT
Electronic Voting Machine is a system which is designed in considering the current
electoral system of the country. Through this, a voter could vote easily through its
fingerprint. The machine includes one of the best electronics devices. In our project we
have two similar systems designated as male and female polling booth. The project
consist of two stand alone systems (male and female booth) using ARM processing that
were connected to the main server through secured wireless connection .Each system has
a TFT touch screen LCD, Arduino mega 2560, fingerprint scanner and a Wi-Fi module.
Both the systems are connected to raspberry Pi B device which will sort out the result
and show the results on LCD screen via HDMI to VGA converter. Most of the
communication is taking place through serial communication.
This system is designed in an attempt to make the electoral process faster and less
complex. Hence, the process of voting is very easy and one can comfortably vote within
a span of 2 minutes. The system is encrypted to eliminate the threat of hacking. Vote
would only be casted when the fingerprint of the voter is matched with any of the
fingerprint present in the database or present in the polling station.
This system is very dynamic and with some modification it can be turned into other
systems where identification of the person is necessary such as attendance management
system etc.
viii
CHAPTER 1
INTRODUCTION
1.0: Introduction
1.1: Existing Electoral Procedure
1.2: Proposed Electoral Procedure
1.4 Conclusion
ii
CHAPTER ONE
INTRODUCTION
CHAPTER ONE
INTRODUCTION
1.0 Introduction
Our project, the Electronic Voting Machine is a user friendly, to be more precise, voter
friendly system. It would override all the demerits of current electoral process of
Pakistan. The electoral process which is adopted in our project is very simple and straight
that the general public will get the motivation out of this and it could result into increase
in the voting turn-out.
CHAPTER ONE
INTRODUCTION
CHAPTER ONE
INTRODUCTION
in a way, only those real voters whose data is saved in the data base of the system are
eligible to vote, no other person can vote as their fingerprint will not be matched. Apart
from that it will not allow those voters to vote who had already casted their votes.
There is no need of voters list from NADRA as well s no need of the polling agents, the
voter will just have to put his/her finger on the thumbprint scanner and if he/she is a
legitimate voter his/her fingerprint would be matched with the record and another screen
would come into display that includes different symbols of different candidates where
he/she can vote by just tapping the touch screen with their finger. Hence there is no need
of the ballot paper and ballot box and ink either.
Following are the some main tasks that were assigned by dividing the main milestone
because it could be done in parallel that would directly save a lot of time.
1. Searching the best suitable electronic devices for the project. Devices those are not only
technologically advanced but also easy to work with.
2. Knowing the availability of the devices that are selected in the first step from different
markets.
3
CHAPTER ONE
INTRODUCTION
3. Dividing work among different group personnel to search the study material of the
devices selected. These study materials includes tutorials about every devices that were
selected in the first step.
4. Working and programming of the devices. Interfacing the devices, developing a code to
run the devices.
5. Monitoring the progress of the project.
6. Compiling all the work done by the members of the group.
1.4 Conclusion
In chapter one, we have given the introduction and importance of the project The chapter
one aalso includes the overview of the existing electoral process of the Islamic Republic
of Pakistan and the overview of the proposed electoral system which we will try to
achieve in our project and tried to establish the difference between the above stated
systems. The chapter also includes the topic of project planning that represents that how
the project was subdivided into different tasks and importance of dividing the project into
different tasks.
CHAPTER TWO
THEOTRETICAL BACKGROUND
CHAPTER 2
THEORETICALBACKGROUND
CHAPTER TWO
THEOTRETICAL BACKGROUND
CHAPTER TWO
THEORETICAL BACKGROUNDS
Here in Pakistan, elections are the main process of the governing systems, people enjoys
their right to vote every five years as the tenure of every government consists of
maximum five years. But unfortunately the electoral process of the country is always on
the receiving end by the losing candidates because we are still practicing the same old
manual process. Not a single election in the history of Pakistan is termed as free and fair
and some serious allegations were made by the loosing parties or candidates due to nontransparency and zero credibility of the system. It has always been felt a need of
6
CHAPTER TWO
THEOTRETICAL BACKGROUND
changing the system in order to make up all the flaws in the current electoral process and
also to make the people feel satisfied that their most important fundamental right i.e.
right to vote is not a wasted.
CHAPTER TWO
THEOTRETICAL BACKGROUND
2.3 Conclusion
In chapter two, we have discussed the electoral history of the Islamic Republic of
Pakistan, the flaws and limitations of the current electoral system. The importance of the
peoples most important fundamental right i.e. right to vote especially in countries that
practices parliamentary form of government. Flaws and limitations in current electoral
CHAPTER TWO
THEOTRETICAL BACKGROUND
system are also mentioned. We have also discussed why there is a need to improve the
current electoral system by defining the goals and objectives of the proposed electoral
system.
CHAPTER THREE
DETAIL OF DESIGN
CHAPTER 3
Detail of Design
10
CHAPTER THREE
DETAIL OF DESIGN
CHAPTER THREE
DETAIL OF DESIGN
Voters
thumbprint
registration
Voting
Voters
Verification
Result
Compilation
11
Result
Display
CHAPTER THREE
DETAIL OF DESIGN
12
CHAPTER THREE
DETAIL OF DESIGN
13
CHAPTER THREE
DETAIL OF DESIGN
The voter will then tap the screen on the symbol which he likes to vote. The system will
then take at least 5 seconds to cast the vote. After the vote is successfully casted the
result would start to compile and display on the LCD screen on a run time which
obviously no one can see the results before the end of the polling time. These all events
from putting the finger print till the successfully casting of the vote would take maximum
2 minutes.
A person would unable to cast a vote in two conditions, if his/her vote is not registered in
the data base or if he/she has already casted their vote.
CHAPTER THREE
DETAIL OF DESIGN
CHAPTER THREE
DETAIL OF DESIGN
3.3.4 Interfacing TFT Touch Screen LCD with Arduino Mega 2560
First step is the assembling of the TFT touch screen LCD with the LCD shield specially
designed for Arduino Mega 2560. The TFT LCD has 40 pins out which 20 pins were
16
CHAPTER THREE
DETAIL OF DESIGN
grounded when it is mounted on the TFT shield. The second step includes downloading
the libraries of TFT touch screen LCD that were added in the library folder of Arduino
CC software. These include the UTFT Library and Utouch Library. It is programmed
through serial communication so Connections were made by powering the LCD and
connecting the RX (serial port) of LCD with the TX (serial port) of ARduino Mega 2560
and vice versa. Before programming the LCD, calibration of the LCD is required, so
calibration is done by running the built in program. The instructions for calibrations were
mentioned on the TFT screen. Calibrating the LCD refers to setting the sensitivity level
of touch and also setting different parameters etc. After calibrating the LCD,
programming phase starts that include the following steps.
CHAPTER THREE
DETAIL OF DESIGN
commands and receiving the response on the serial monitor to make sure that its
working correctly. If the required response is not received then it means that it is not
working normal. Add user command is used to save the fingerprint of a person into the
data base of the fingerprint reader; the fingerprint sensor will take three readings of the
voters fingerprint back to back and take the average value of the pattern and save it in
the database of the fingerprint sensor. Delete user command is used to delete the specific
fingerprint that is stored in the database. And compare command is used to match the
fingerprint of the voter with the already saved fingerprints in the database of the
fingerprint sensor. Comparing is of two types, comparing with all the fingerprints stored
in all the locations in the fingerprint sensor and comparing by providing the location on
which that particular vote is registered.
18
CHAPTER THREE
DETAIL OF DESIGN
easily available but also one can easy get guidelines from internet or from other fellows
as it is in use extensively now a days.
The raspberry Pi is used as a main server in the project. Its function is to receive the data
from both male and female booth, compile and arrange the results or data and then
display these results or data on the LCD screen on run time. A socket is created which
acts as the link between the two sections of the project. An IP is assigned to both the
male/female booth and the main server. Connection will not be established if they dont
have the same IP. The main server is made host and the male and female booth has been
made client so that main server will listen from these clients. Apart from that, the IP is
assigned in order to make the raspberry Pi to listen or to receive data only from these two
clients and not from the other sources.
19
CHAPTER THREE
DETAIL OF DESIGN
20
CHAPTER THREE
DETAIL OF DESIGN
3.4 Conclusion
In this chapter we have mentioned the basic block diagram of the project, the registration
process of the voters fingerprint. The brief description about the operation of the project.
We have also covered all the aspects of designing phase, from selection of the devices to
the programming of the devices. All the devices are serially communicated. Female
booth and male booth contains TFT Touch screen LCD, Arduino Mega 2560, Fingerprin
sensor. ESP8266 Wi-Fi modules are connected to each Arduino Mega 2560.
21
CHAPTER FOUR
SYSTEM HARDWARE
CHAPTER
4
System Hardware
4.3: Conclusion
22
CHAPTER FOUR
SYSTEM HARDWARE
CHAPTER FOUR
SYSTEM HARDWARE
4.0 Block Diagram
23
CHAPTER FOUR
SYSTEM HARDWARE
CHAPTER FOUR
SYSTEM HARDWARE
RASPBERRY PI B * 1.
POWERSUPPLY
HDMI CABLE.
25
CHAPTER FOUR
SYSTEM HARDWARE
world, and it has been used in a wide range of digital projects, from parent detectors to
the music machines and to weather stations. And with infra-red cameras.
4.2.2.3 Raspberry Pi B:
It is 2nd generation of Raspberry Pi. It is now replaced by the it next model which is B+
in February 2015. The Raspberry Pi 2 has an ARM processor through which it can run
the full range of ARM GUI0 / LINUX distributions. The Raspberry Pi is of about a
credit-card sized computer that can plugs into TV or any sort of LCD. And it also
capable to connect keyboard and mouse through the two available USB ports. It can do
almost everything that the normal PC could do like word-processing, spreadsheets, and
playing games. It also plays HD (high-definition) video. Its design is based on a
Broadcom BCM2835 SoC, which includes an ARM1176JZF-S 700 MHz processor. The
design does not consist of a built in hard disk or any other solid state drives, but it relies
on an SD card for booting & for storage. This board is designed to run Linux based
26
CHAPTER FOUR
SYSTEM HARDWARE
operating systems. This Raspberry Pi Model B has 512MB RAM and with 2 USB
(Universal Serial Bus) ports and an also with Ethernet controller port.
27
CHAPTER FOUR
SYSTEM HARDWARE
4.2.2.4 Specifications
Standard Speed
700Mhz
RAM `
512MB
Storage
Full SD
Ethernet
Yes
Yes
Yes
Expansion header
26
17
Yes
Power source
Power ratings
Operating System
Linux
4.2.2.5 Features:
The Raspberry Model B video output is via a HDMI (rev 1.3 & 1.4) port with 14
HDM0.I resolutions from 640350 to 19201200 with digital audio.
The Raspberry Model B is one of the best, single board computers available and, given
the huge popularity of the Raspberry Pi family
The Pi is just like the size of a credit card. It is only 20mm thicker as compared to the
credit card.
The Raspberry Pi market is saturated because of these useful additional features -on
boards and several accessories.
28
CHAPTER FOUR
SYSTEM HARDWARE
29
CHAPTER FOUR
SYSTEM HARDWARE
Board (which are both the names of the companies and their main devices). Beagle
Board is geared toward adult hardware tinkerers and Panda Board missions is to create a
mobile software-programming platform which is easily available at a reasonable price.
Like Raspberry Pi, they are both having boards with ARM processors and are capable of
HD video. But Beagle and Panda Boards have more connection headers and connectors
which we do not have need of this because our project do requires more GPIOs.
The Raspberry Pi has two main advantages over the others boards.
It was accept to be act as a complete working computer. We just require inserting an SD
card which contain the Operating System, then connect the peripherals and power supply,
and then it's ready to go. While Beagle and Panda Boards require hookup to a host
computer for initialization, and although they have almost similar processing capabilities.
CHAPTER FOUR
SYSTEM HARDWARE
project[2]. Thin Film Transistor Touch Screen LCD is a powerful module that is like
plug and play. This display shield has a controller named ILI9486 that built into it with
RAM buffering, so that almost no work is done by the microcontroller. The LCD is
equipped with touch, SD and flash. It is almost compatible with many microcontrollers
specially AVR, STM32, 89C51 etc.
What is thin film transistor? It is due to TFT technology (Active matrix technology) that
these devices are now being used in every electronics devices as in smart phones, LCDs,
computer, tablets. It uses semiconductor material that is applied over glass plating. The
pixels of LCD are in the form of transistors including liquid crystals. Thatd make the
LCD to switch on and off the pixels quickly. They have very small response time.
31
CHAPTER FOUR
SYSTEM HARDWARE
.
Fig: 4.5: Working of touch screen.[13]
4.2.2.3 TFT LCD Pin configuration:
4.2.2.4Specifications:
Data pins and control pins.
32
CHAPTER FOUR
SYSTEM HARDWARE
Size:
3.5 inches.
Resolution:
Applicability:
4.2.2.5 Justification:
Its more like plug and play, easy to handle, enhanced color scheme, requires less
power,The LCD has a wide viewing angle; the contrast is also very suitable. The main
reason to use touch LCD is due to its compatible features, it is compatible with Arduino
as we can easily star doing work with them. As there is no need to interface the LCD
with Arduino.
33
CHAPTER FOUR
SYSTEM HARDWARE
34
CHAPTER FOUR
SYSTEM HARDWARE
5V.
35
CHAPTER FOUR
SYSTEM HARDWARE
Microcontroller
Operating Voltage.
ATmega2560
5v.
36
CHAPTER FOUR
SYSTEM HARDWARE
7-12V
6-20V
16
20mA
50mA
Flash RAM
256KB
SRAM
8 KB
EEPROM
4KB
Length
101.52mm
Width
0.53.3mm
Weight
370.g
Serial ports
Clock Speed
16MHZ
37
CHAPTER FOUR
SYSTEM HARDWARE
CHAPTER FOUR
SYSTEM HARDWARE
The ATmega2560 on the Mega 2560 comes preprogrammed with a bootloader that
allows you to upload new code to it without the use of an external hardware programmer.
4.2.4.5 Power
The Arduino Mega can be powered by means of the USB (Universal Serial Bus )
association or with an outside power supply through adapter. The board can work on an
outer supply of 6 to 20 volts. In the event that supplied with under 7V, in any case, the
5V pin may supply fewer than five volts and the board may be insecure. In the event that
utilizing more than 12V, the voltage controller may overheat and harm the board. The
prescribed extent is 7 to 12 volts.
4.2.4.6 Features:
The Arduino Mega 2560 is the 2nd most commonly used version of the Arduino family.
The Arduino Mega is just like the Arduino Uno's but its has some sort of increments like
GPOs, RAM etc. The most important features of Arduino Mega is that it has four Serial
ports. By Using Arduino We do not have to buy its burner, development board by which
all of the added Functionality comes at the cost a larger circuit board. By using Arduino
all of these are packed in a single board which makes Arduino a power full tool.
4.2.4.7 Justification:
We are using Arduino Mega 2560 because it has 4 serial ports and we require 3 serial
ports for oour project that are fingerprint sensor, wifi, TFT touch LCD. It has large
memory and comparatively cheaper than other devices.
requirement by speed, cost and simplification.
39
CHAPTER FOUR
SYSTEM HARDWARE
The power supply is designed to supply their respective voltages to each component.
This power supply can be able to provide two voltages levels that are
3.3V
5V
40
CHAPTER FOUR
SYSTEM HARDWARE
41
CHAPTER FOUR
SYSTEM HARDWARE
placed your finger on to the scanner, this blink of led show that the data is0. transferring
or the scanner is reading the data of your finger.
42
CHAPTER FOUR
SYSTEM HARDWARE
Pin
Color
Name
Type
Function
Red
Vin
In
Number
1
supply
2
Yellow
TD
Out
White
RD
In
Serially data in
Black
GND
Ground
4.2.6.4 Working
.
Fig: 4.14: Working of Fingerprint Scanner [7]
43
CHAPTER FOUR
SYSTEM HARDWARE
44
CHAPTER FIVE
SYSTEM SOFTWARE
CHAPTER
5
System Software
5.0: SYSTEM FLOWCHART
5.2: Conclusion
45
CHAPTER FIVE
SYSTEM SOFTWARE
CHAPTER FIVE
SYSTEM SOFTWARE
5.0 SYSTEM FLOWCHART
Our system has two process, one addition of the fingerprint in the databade of the sensor
and second, polling process.
46
CHAPTER FIVE
SYSTEM SOFTWARE
Polling:
47
CHAPTER FIVE
SYSTEM SOFTWARE
CHAPTER FIVE
SYSTEM SOFTWARE
your written code in to the binary code. Or to convert the source code into the object
code.
5.1.15 Serial Monitor
It is used to open the serial monitor.
49
CHAPTER FIVE
SYSTEM SOFTWARE
CHAPTER FIVE
SYSTEM SOFTWARE
51
CHAPTER FIVE
SYSTEM SOFTWARE
52
CHAPTER FIVE
SYSTEM SOFTWARE
53
CHAPTER FIVE
SYSTEM SOFTWARE
on
the
internet.
CHAPTER FIVE
SYSTEM SOFTWARE
efficient high-le el data structures ith the s ta that is er co ple . P tho s elega t s ta
and dynamic typing, together with its interpreted nature, make it an ideal language for scripting
and rapid application development in many areas on most platforms. Almost all the libraries are
automatically built in with the programming software.
55
CHAPTER FIVE
SYSTEM SOFTWARE
4.2 Conclusion:
In this chapter we have discussed different softwares that were used to develop the
program. The software for arduino as well as for Raspberry Pi model B. C language is
used for programming the arduinos and python language is used for programming the
Raspberry Pi model B.
56
CHAPTER SIX
SYSTEM ANALYSIS
CHAPTER
6
System Analysis
6.0 CONCLUSION
6.1 ADVANTAGES
6.2 APPLICATIONS
57
CHAPTER SIX
SYSTEM ANALYSIS
CHAPTER SIX
SYSTEM ANALYSIS
In this last part, there are four areas. In first area, we depict the consequences of the
undertaking took after by different areas in which we portray conclusion, points of
interest, applications and future upgrades separately.
58
CHAPTER SIX
SYSTEM ANALYSIS
encrypted data. Which help the election commission to organize the Election in a secure
manner and generate result with complete transparency?
Our system provides many features that can make easier interaction among the voters,
elections, polling officer and Election commission. The feature included in our system is
Verification
Encryption
The overall Analysis of our system proves to be a better and more enhanced system as
compared to the current one. i.e Manual paper balloting System .
Advantages
It ensures Transparency
It is environment friendly because there is no need of ballot papers which was used in
a previous system.
It is Reliable.
Portable
59
CHAPTER SIX
SYSTEM ANALYSIS
6.2 Applications
It also is used to conduct opinion polls during annual share holders meetings.
It could be used in different places where electricity is not available because the
things are operated with the help of a simple 5 Volt battery
A print function can also be embedded to satisfy the voters that their votes are casted.
For which allowing the user to print a receipt of their vote. Which do not include the
information about to whom he has casted a vote due to privacy matters.
It would also possible to convert this voting machine to different voting system like
collages school attendance system with some enhancement.
Database can be created in an encrypted form and have a secure Data Base.
60
CHAPTER SIX
SYSTEM ANALYSIS
3400/=
6000/=
4500/=
5200/=
5000/=
Raspberry pi =
4000/=
Total=
28,100/=
61
APPENDICES
APPENDICES
References
[1] Library: UTOUCH. http://www.rinkydinkelectronics.com/library.php?id=55.
[2] UTFT LCD user guide http://www.elecfreaks.com/7619.html.
[3] Tutorial on Arduino Mega2560 https://www.arduino.cc/ en/Main/
ArduinoBoardMega2560.
[4] Tutorial on using Python editor-Notepad++ .http://csc.ucdavis.edu//cour
/nlp/Software/Windows/npp.html.
[5] Existing Electoral Process, www.pakistanhotline.com
[6] Fig 4.3 Internal Structure of TFT touch screen LCD
from http://pubs.rsc.org//co/articlelanding/2012/jm/c2jm30635b
[7] File: UART-Fingerprint-Reader-UserManual.pdf.
http://www.waveshare.com/wiki/File:UART-Fingerprint-Reader-UserManual.pdf
[8] Setup Kali Linux In Raspberry Pi And Android Device As Screen & Input.
http://www.picateshackz.com/2015/05/setup-kali-linux-in-raspberry-pi-and.html
[9] Functional block schematic of the Raspberry-Pi. en.wikipedia.org/wiki/
Raspberry_Pi#/media/File:Raspberrypi_block_function_v01.svg
[10] Learn About LCD TV and TFT LCD Displays. http://serdis.dis.ulpgc.es/~itisbyp/NotasDeClase/informacion/Material%20 Complementary
[11] Raspberry Pi Model B revision 2.0 schematics #raspberrypi @Raspberry_Pi.
https://blog.adafruit.com/2012/10/22/raspberry-pi-model-b-revision-2-0-schematicsraspberrypi-raspberry_pi/
[12]Touchscreen. https://www.tititudorancea.com/z/touchscreen.htm
[13] File:Color TFT-LCD Cells-Schematic.png. https://commons.wikimedia.org/
wiki/File:Color_TFT-LCD_Cells-Schematic.png
62