You are on page 1of 28

ELECTRONIC VOTING

MACHINE

ABSTRACT

India is world’s largest democracy. It is perceived to be charismatic one as


it accommodates cultural, regional, economical, social disparities and still
is able to stand on its own. Fundamental right to vote or simply voting in
elections forms the basis of Indian democracy.

In India all earlier elections be it state elections or centre elections a


voter used to cast his/her vote to his/her favorite candidate by putting the
stamp against his/her name and then folding the ballot paper as per a
prescribed method before putting it in the Ballot box. This is a long, time-
consuming process and very much prone to errors. This situation
continued till election scene was completely changed by electronic voting
machine. No more ballot paper, ballot boxes, stamping, etc. all this
condensed into a simple box called ballot unit of the electronic voting
machine.
T
HEORY

Electronic Voting Machine is widely used Application Now a days. This


Application has two main Units

1) Balloting Unit
2) Controlling Unit
Balloting Consists of Matrix of switches which has 16 different switches.
Each one correspondence to the Candidate of the different Party. On
each switch different Symbols are shown, so each switch represents the
different and unique Candidate. When user enters Balloting Unit, He/She
is allowed to vote to any of the 16 candidate. If user tries to give vote to
more than one candidate then one candidate then only first vote is
recorded.

At controlling unit, counting is done and results are declared.

How the Vote is cast with this EVM?

The entire process is very easy to understand:

 Like in earlier system, your name is called and you are asked to sign
or put your thumb impression in a register.
 After your identification is done by Election Officer, an ink mark is
put on your finger, same as earlier.
 Then the Election Officer gives you a slip that bears the Voter
register number where you signed or put your thumb impression.
 You hand over this slip to the presiding officer who confirms the
serial number and permits you to vote by pressing the button of the
Control Unit of EVM.
 You are not given any ballot thereafter, and are sent to the EV
Machine placed behind a card board in a corner. The machine is
placed in such a way that your polled vote will be a secret.
 On the Balloting Unit of EVM, you press the blue button placed in
front of your favorite candidate and release.
 As soon as the button is pressed, the red LED indicator lights up and
a whistle sound comes from the machine. This signifies that your
vote has been casted rightly. Now you can come out.
 In case of red LED not working, press the Blue button firmly again. If
finding it difficult, consult the Presiding Officer.
 Your vote is complete safe and secret and there is no room for error
as well. You can rest assured that your vote is not going to be
invalid in any case.
 The Voting Machine is attached to the 'Control Unit'. When the user
presses the button, his vote is registered in the control unit and the
number of votes for the respective candidates is calculated
automatically.

BLOCK DIAGRAM
CIRCUIT DIAGRAM
LAYOUT
WORKING

The Electronic voting machine builds around Microcontroller Atmel


AT89C51. The power supply from 9V is down converted and regulated 5V
to the circuit.

Reset switch is used to manually reset in microcontroller, while


power on reset signal for microcontroller is derived from combination of
resistors. Pin 31 (EA/Vcc) is connected to the Vcc to enable internal
program executive. Pin 18 and 19 are input and output pins of the build in
inverting amplifier, respectively, which can be use as an on-chip
oscillator. An 11.592 MHz crystal is used to generate clock frequency to
the microcontroller

Port 3 is used to drive the segment common-cathod display. Pins


17 down through 10 are connected to the input pins of 8-bit 3-state
non inverting bus transceiver IC 74LS245

output IC 74LS245 via resistor of 82 IC 74LS245 is used to as non


inverting bus transceiver to increase the current level Resistors of 82
are used to the limit the current through 7-segment displays. Each
display compromises of light emitting diodes (LEDs) with their common
cathode connected together, hence

Port 1 acts as multiplex to select a particulars 7 segment display


using octal Darlington transistor array JLN 2803 transistor. Pin 5 through
8 of port 1 are pulled up by resistor bank of 10K and also connected to
the pin 4 to 1 of ULN 2803 outputs a low signal to light up the segment of
7-segment display selected by port 1 data.
Port 1 and Port 3 provides the segment data and enable signal
simultaneously for displaying a particular number on 7-segment display.
Port 2 detects pressing of the switches (Start, Display, Count and Clear)
by pulling the port pins to ground. The software detects the pressing of
the switches and reacts as per program and uzzer is turn on along with
LED.

Port 2 is connected to the switches (Matrix 4 x 4).

Connection Should Be as follows for Matrix:-

Pin 21-Pin 28 of IC89C51 should be connected to the Light Blue,


brown, Black, Red, Orange, Yellow, Green wires of Marix Respectively

OPERATION

1 Connect 9V battery
PCB RULES/SOLDERING AND
TROUBLESHOOTING
PCB RULES

1. No sharp right angle bends or conductors when spacing is closer than 0.012 in.
2. Use circular pads for all pad/vias except pin one (1) on through hole components, which
should be square.
3. All signal traces must originate or end at a pad or via (no `T' connections
permitted).
4. T's are permitted on power and ground wiring.
5. All power and ground traces must be a minimum of 0.050 in. wide except for tie upsand
tie downs.
6. Maintain consistent orientation of similar components on the card.
7. The component location screen must indicate the following on the component side:
(a) Component outline.
(b) Component identification code from schematics (i.e. U1, R1, ....)
(c) Orientation of component (notch or pin 1).
(d) Diodes must have anode/cathode marked.
(e) "+" indicating polarity of polarized capacitors.
(f) Card name.
(g) Bright white indelible ink is to be used for the marking.
8. Refer to board outline drawing for required component placement.
9. Number components to read like book (upper left to lower right). Provide updated
information in Protel format.
10. Decoupling capacitors have a 1206 spacing. Place at roughly 1 capacitor for every
I.C.equivalent.
11. Provide 2 .040 holes .1" apart for ground at 1 place on the PCB.
12. Put "100000 Rev. X" in copper.13. PCB is to be X Layers SMOBC .062 thick.

SOLDERING

• Take care not to press TOO HEAVILY on the pads, otherwise the pads will lift up and
will be very difficult to repair.
• Moving components BEFORE the solder has solidified may again either LIFT the copper
tracks or cause a DRY JOINT explained previously.
• Apply the soldering iron tip and solder to the joint SIMULTANEOUSLY and keep there
until the solder flows correctly over the joint.
• Remove the soldering iron tip IMMEDIATELY after the smoke from the flux within the
solder disappears approximately 2 seconds after the solder melts.
• Only use SILVER-LOADED SOLDER for SMT joints (2% Silver)

TROUBLESHOOTING

After making the project we had gone through the following steps.

1) We check the continuity of the layout using DMM.


2) We check whether any dry soldering is there in circuit or not.
3) We connected the disconnected path of copper using the soldering material.
4) We check the voltages at different pins of IC 556 using DMM.

FLOWCHART

FLOWCHART REPRESENTING THE WORKING OF THE SYSTEM:

Start

Press ‘Restart’
switch

No

Press ‘279’

Is seven segment display=’E’?


Press switch for desired
PressPress
countstart
switch
candidate
switch
Yes

Stop

CODE

ORG OOH DELAY2M SWP1: MOV

CLR O1.5 A,#OFFH

LCALL MOV P2,A


DELAY2M

MOV A,#00H LCALL CLR P2.0


DELAY2M
MOV P1,A CLR P2.1

MOV P2,A SWP: CLR P2.2

MOV P3,A CLR P2.3


MOV
A,#OFFH

MOV P2,A

SETB P0.0 MOV P2,A

SETB P0.1 CLR P2.0

SETB P0.2 CLR P2.1 ANL A,#0F0H

SETB P1.0 CLR P2.2 ORL A


A,#0F0H
SETB P1.1 CLR P2.3 OPL A

SETB P1.2 ADD A,#0F0H

SETB P1.3 MOV A,P2 JZ SWP1

ANL A,#0F0H

ORL, LCALL
A,#0F0H
SCANKEY
CPL A

CLR P0.0 ADD A,#00H MOV 31H,A

LCALL DELAy

SEPTB P0.0 JZ DISPEP WR1: MOV P2,A

A,#0FFH

MOV A,#00H

MOV P3,A

L1: MOV CLR P2.0


P3,#3DH
CLR P2.1
SETB P1.4
SCANKEY LCALL CLR P2.2
LCALL
CLR P2.3
DELAY2M

CLR MOV 30H,A MOV A,P2


P.14
ANL, A#0F0H
LCALLD
ELAY2M

LCALL SWR: MOV, ORL, A#0FH


DELAY2M A#0FFH
CPL A
MOV P2,A

LCALL ADD, A#0OH

CLR 20 JNZ SWR1


DELAY2M MOV CLR P2.0
C,P1.0
CLR P2.1
JC L1
CLR P2.2

CLR P2.3

DISPEP: MOV MOV A,P2

A,#504 ANL A#0FH

ORL A#0FH

MOV P3,A CPL A

SETB P1.4 ADD A#0OH SWP2: MOV

LCALL JNZ SWR A#0FH

DELAY2M MOV P2,A

CLR
P1.4
CLR P2.0
MOV A, A#0FH
CLR P2.1
MOV P3,A
CLR P2.2
SETB P.15
CLR P2.3
LCALL

OV A,P2 DELAY2M MOV 69H,A

ANL A,#0F0H LJMP DISPE MOV 6AH,A

ORL A,#0F0H MOV 6AH,A

CPL A, MOV 6AH,A

ADD A,#00H MOV 6AH,A

JZ SWP2 MAIN: CLR P0.2 MOV 6AH,A

MOV 6AH,A

SCANKEY MOV 70H,A

MOV 32H.A MOV A,#00H MOV 71H,A

CLEAR MOV 72H,A


COUNTERS

SWR2: MOV 41H,A MOV 73H,A


MOV
MOV 42H,A MOV 74H,A
A,#FFH
MOV 43H,A MOV 75H,A

MOV 44H,A MOV 76H,A

MOV 45H,A MOV 77H,A

CLR P2.0 MOV 46H,A MOV 78H,A

CLR P2.1 MOV 47H,A MOV 79H,A

CLR P2.2 MOV 48H,A MOV 7AH,A

CLR P2.3 MOV 49H,A MOV 7BH,A

MOV 4AH,A MOV 7CH,A

NOV A,P2 MOV 4BH,A

ANL A,#0FOH MOV 4CH,A

ORL A,#0FH MOV 4DH,A

CPL A MOV 4EH,A

AD A,#0OH MOV 4FH,A

JNZ SWR2

MOV 50H,A

MOV 51H,A XXX:

MOV 52H,A

MOV A,30H MOV 53H,A

SUBB A,#1H MOV 54H,A

JNZ DISPE MOV 55H,A

MOV AM31H MOV 56H,A

SUBB A,#6H MOV 57H,A

JNZ DISPE MOV 58H,A

MOV A,32H MOV 59H,A

SUBB A,#8H MOV 5AH,A

JNZ DISPE MOV 5BH,A


MOV 5CH,A SJMP

OVER:l

LJMP MAIN MOV 5DH,A OVER

MOV 5EH,A

DISPE:
MOV

P3,#5DH
MOV 60H,A
SETB P1.4
MOV 61H,A BBB: LJMP BBBB
LCALL

DELAY2M MOV 62H,A CCC: LJMP CCCC

CLR P.14 MOV 63H,A

LCALL MOV 64H,A AAA: MOV C.P.2

DELAY2M MOV 65H,A

LCALL MOV 66H,A JNC AAA

DELAY2M MOV 67H,A CLR P0.1

LCALL MOV 68H,A

A1 MOV P3,# MOV A@R0 CLR P.20


OD C H
MOV 38H,A CLR P2.1
SETB P.14
CLR P2.2
LCALL
CLR P2.3

2M

CLR P1.4 MOV A@R1 MOV A.P2

LCALL MOV 39H,A ANL A,#0F0H

AY2M ORL A,#0FH

LCALL CPL A

DELAY2M ADD A,#00H

LCALL MOV B,RO JNZ SWR3


DELAY2M MOV A,R2

MOV R0,A

MOV A,@RO

MOV 3AH,A CLR P0.0

MOV RO,B MOV A,#0FH

SWP3: MOV B,RO MOV 30H,A


MOV
MOV A,R3
A,#OFFH
MOV RO,A AAA2: MOV P3,#01H
MOV P2,A
MOV A,@RO SETBP1.4
CLR P2.0
MOV 3BH,A DELAT2M LCALL
CLR P2.1
MOV R0,B CLR P1.4

CLR P2.2 INTEM

CLR P.23 LCALL LCALL DELAY2M

MOV A,P2 MOV A,38H LCALL

ANL A,#0F0H MOV @R0,A DELAY2M

ORL A,#0FH LCALL

CPL A MOV A,39H DELAY2M

ADD A,#001 MOV @R1,A DJNZ


30H,AAA2
JZ AAA1

MOV A,#0FFH

MOV P2,A MOV B,R0


SETB P0.0S

LCALL MOV A,R2 INCREMENT TOTAL


COUNTER
SCANKEY MOV R0,A

ANL A,#0FH MOV A,3AH

MOV @R0,A

MOV R0,B
RL A MOV B,R0

RL A MOV A,R3 MOV 38H,3CH

AD A,#40H MOV R0,A MOV 39H,3DH

MOV A,3BH MOV 3AH,3EH

MOV @R0,A MOV 3BH,3FH

MOV R0,B

MOV R1,A LCALL

ADD A,#01H INTEM

MOV R2,A SWR3: MOV

A,#0FFH

ADD A,#01H

MOV R3,A

MOV 3CH, 38H

MOV 3DH, 39H MOV 66H,A

MOV 3EH, 3AH MOV 67H,A

MOV 3FH, 3BH MOV 68H,A

MOV 69H,A

LJMP XXX MOV 6AH,A

MOV 6BH,A

BBBB: MOV MOV 6CH,A


C,P1.3
MOV 6DH,A
JNC BBBB
MOV 6EH,A

MOV 6FH,A
MOV, A#00H

MOV 70H,A
MOV 40H,A MOV 71,HA

CLEAR MOV 72H,A


COUNTERS
MOV 73H,A MOV A,3VCH
MOV 41H,A
MOV 74H,A LCALL
MOV 42H,A
MOV 75H,A SEGVAL
MOV 43H,A
MOV 76H,A MOV ,38H,A
MOV 44H,A
MOV 77H,A
MOV 45H,A
MOV 78H,A MOV A,3DH
MOV 46H,A
MOV 79H,A LCALL
MOV 47H,A
MOV 7AH,A SEGVAL
MOV 48H,A
MOV 7BH,A MOV ,39H,A
MOV 49H,A
MOV 7CH,A MOVA ,3EH
MOV 4AH,A
MOV 7DH,A LCALL
MOV 4BH,A
MOV 7EH,A SEGVAL
MOV 4CH,A
MOV 7FH,A MOV ,3AH,A
MOV 4DH,A

MOV 4EH,A
MOV 38H,A MOV ,A3FH
MOV 4FH,A
MOV 39H,A LCALL

MOV, 3AH,A
MOV 50H,A
MOV, 3BH,A
MOV 51H,A
MOV, 3CH,A
MOV 52H,A
MOV, 3DH,A
MOV 53H,A
MOV, 3EH,A
MOV 54H,A
MOV, 3FH,A
MOV 55H,A

MOV 56H,A

MOV 57H,A
MOV, A,#0FH CCCC1: MOV
MOV 58H,A
MOV, 30H,A P3,38H
MOV 59H,A
SETB P1.4
MOV 5AH,A LCALL

MOV 5BH,A BBB1: MOV DELAY2M


P3,#70H
MOV 5CH,A CLR P1.4
SETB P1.4
MOV 5DH,A
LCALL
MOV 5EH,A DELAY2M MOV P3,39H

MOV 5FH,A STB P1.5


CLR P.14
LCALL
LCALL
MOV 60H,A DELAY2M

MOV 61H,A DELAY2M


LCALL
MOV 62H,A DELAY2M

MOV 63H,A CLR P1.5


LCALL
MOV 64H,A DELAY2M

MOV 65H,A

MOV P3,3AH MOV MOV A,34H


A,@R0
SETB P1.6 MOV 38H,A LCALL

LCALL SEGVAL

DELAY2M MOV 38H,A

CLR P1.6 MOV @R0,A

MOV 39H,A MOV A,35H

SEGVAL LCALL

MOV P3,3BH

SETB P1.7

LCALL MOV B,R0 MOV 39H,A

DELAY2M MOV A,R2 MOV 36H,H

CLR P.17 MOV R0,A LCALL

MOV A@R0 SEGVAL


MOV 3AH,A
MOV 3AH,A
MOV R0,B
MOV B,R0 MOV A,37H

MOV A,R3 LCALL

SWP4 SEGVAL
MOV

A,#0FFH MOV R0,A MOV 3BH,A

MOV P2,A MOV A@R0


MOV 3BH,A
MOV A,#3FH
MOV R0,B
CLR P2.0 MOV 30H,A

CLR P2.1

CLR P2.2 SWR4 MOV CCCC2: MOV

CLR P2.3 A,#0FFH: P3,38H SETB P1.4

MOV A,P2 MOV P2,A LCALL

ANL A,#0F0H DELAY2M

ORL A,#0FH CLR P2.0 CLR P1.4

CPL A CLR P2.1 MOV P3,39H

ADD A,#00H CLR P2.2 SETB P1.5

JZ CCCC1 CLR P2.3 LCALL

MOV A,#0FFH MOV A,P2 DELAY2M

MOV P2,A ANL A,#0F0H CLR P.156

ORL A,#0FH MOV


P3.3AH
LCALL CPL A SETB P.16

SCANKEY ADD A#00H LCALL

JNZ SWR4
DELAY2M

ANL A,#0FH MOV CLR P1/6


A,#0FFH
RL A
MOV P2,A
RL A

ADD A,#40H MOV P.3.3BH

MOV R0,A SETB P.17

MOVING C MOV DELAY2M LCALL


VALUE TO TEM 34H,38H

ADD A,#01H
CLR P.17
MOV R1,A MOV
35H,38H
ADD A,#01H
DJNZ
MOV
MOV R2,A
36H,38H 30H,CCCC2
MOV
ADD A,#01H 37H,38H

MOV R3,A
LJMP XXX

SEGVAL: Z11 MOV A,3AH ONE: MOV


CJNE A,#0U
ADD
A,#0U,NO RET

MOV A,#7RH MOV ,3AH TWO: MOV


A,#1H
RET Z111 RET
RET
MOV A,39H THREE:
M
OV

NO: ADD A,#1H A,#2H


CJNE
MOV 39H,A RET
A,#01
RET FOUR: MOV
H,N1
A,#3H
MOV
A,#22H

RET

N1: Z1111 MOV A,38H RET


CJNE
ADD A,#1H FIVE: MOV
A,#02 A,#4H
MOV 38H,A
H,N2
RET
MOV
A,#57H
RET RET SIX:

N2: SCANKEY: MOV


CJNE A,#5H

A,#03 RET
MOV SEVEN
H,N3
A,#0FFH
MOV
MOV
A,#37H

RET

N3: MOV P2,A A,#6H RET


CJNE
MOV
A,#04 A,#7H
CLR P2.0 EIGHT:
H,N4
RET
MOV
MOV
C,P2.4
A,#2BH

RET

N4: JNC NINE: MOV


CJNE ONE A,#8H

A,#05 MOV RET


TEN:
H,N5 C,P2.5
MOV
MOV JNC TWO A,#9H
A,#3DH
MOV RET
RET C,P2.6

N5: CJNE
A,#06H,N6

MOV A,#7DH JNC MOV


THREE
RET ELEVEN:
MOV
A,#0AH
C,P2.7
RET
JNC
FOUR

SETB P.20

N6: MOV
CJNE
TWELVE:
A,#07
H,N7 CLR P2.1 A,#0BH

MOV MOV C,P2.4 RET


A,#26H

RET

N7: MOV C,P2.4 THIRTEEN: RET


CJNE
JNC FIVE MOV
A,#08 A,#0CH
MOV C,P2.5
H,N8
JNC SIX FOURTEEN:
MOV
RET
A,#7FH
MOV
RET
A,#0DH

N8: MOV C,P2.6 RET


CJNE
JNC SEVEN FIFTEEN: MOV
A,#09 A,#0EH
MOV C,P2.7
H,N9
RET
MOV
A,#2FH

RET

N9: JNC EIGHT SIXTEEN: MOV


RET A,#0FH
SETB P.2.1
RET

MOV
CLR P2.2 DELAY2M

INTEM: MOV MOV C,P2.4 R3,#4


A,3BH
JNC NINE MOV
CJNE A,#09H,Z1 R4#145
MOV C,P2.5 DJNZ R4,TT1
MOV A,#00H TTI:
JNC TEN DJNZ R3,TT1
MOV 3BH,A
MOV C,P2.6 NOP
MOV A,3AH
RET
CJNE
JNC ELEVEN MOV R3,.#4
A,#09H,Z11
DELAYPS:
MOV
MOV C,P2.7 R3,.#132

MOV A,#OOH JNC TWELVE MOV


R1,.#116
MOV ,3AH,A SETB P.2.2 TTU1:
DJNZ
MOV, 39H CLR P2.3
R1TTU1
CJNE MOV C.P.24
DJNZ
A,#90H,Z111 R2TTU1

MOV A,#OOH JNC DJNZ


THIRTEEN R3TTU1
MOV A,39H
MOV C.P.25 RED
MOV A,38H
JNCFOURTEE ORG 700H
CJNE
N
DB 7EH

DB 22H
A,#90H,Z1111
MOV C.P.26
DB 57H
LJMP OVER
JNC FIFTEEN
DB 37H
MOV C.P.27
DB 2BH
Z1 MOV SETB P2.3
JNC SIXTEEN
A,3BH DB 3DH

ADD DB 7DH
A,#1H LJMP
DB 26H
SCANKEY
MOV
DB 7FH
3BH,A
DB 2FH
RET
END

END
RESULT AND CONCLUSION

The EVM consists of a control unit (CU) and ballot unit (BU), both the units
are working independently and in collaboration with each other as well.
The CU is accepting password in voting mode and is responding
accordingly.
In voting mode, CU communicates with BU in order to exchange various
signals.
CU is counting the votes for individual candidate (8 in number) and total
number of votes cast can be checked at anytime.
In total, the complete system (including all the hardware components and
software routines) is working as per the initial specifications and
requirements of our project. Because of the creative nature of the design,
and due to lack of time, some features could not be fine-tuned and are
not working properly. So certain aspects of the system can be modified as
operational experience is gained with it. As the users work with the
system, they develop various new ideas for the development and
enhancement of the project.

COMPONENTS

U1 - 7805 5V Voltage Regulator


U2 - ULN 2803 Octal Transistor Array
U3 - 74LS245 non inverting bus transceiver
U4 - AT89C51 – Microcontroller
DS1-DS4 - LTS 543 seven segment common cathode display
LD1, - Red LED (5mm)
LD2 - Green LED (5mm)
RN1, RN2 - 10k*9 pin (1/4 watts)-Resistor Bank
XTAL - 11.0592 MHz 10k (1/4 watts)
R1-R7 - 82
R8 - 100
R9-R10 - 470
R11 - 10k
C1 - 1000uF, 25 V electrolytic
C2, C3 - Not Required
S1-S6 - Push-to-on switch (2-Legs) Tack switch
Socket - 18 Pin IC Base
Socket - 20 Pin IC Base
Socket - 14 Pin IC Base
J1-J4 - Jumpers
Battery - 9V-Battery
Switch Matrix - 4 * 4 Switch PCB
Switch - 12mm 4 PIN Tack Switch 16 Pec

REFERENCE

 Muhammad Ali Mazidi , Janice Gillispie Mazidi, Rolin D. Mckinlay.


Second edition, “THE 8051 MICROCONTROLLER AND EMBEDDED
SYSTEM”
 K. J. Ayala. Third edition, “The 8051 MICROCONTROLLER”

 General information about electronic voting machine


www.eci.gov.in

www.eci.gov.in/faq/evm.asp

www.eci.gov.in/Audio_VideoClips/presentation/EVM.ppt

www.rajasthan.net/election/guide/evm.htm

www.indian-
elections.com/electoralsystem/electricvotingmachine.html

 Tutorial on microcontroller:
www.8051projects.net/microcontroller_tutorials/

You might also like