major project report on automatic petrol pump system
TRANSCRIPT
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
1/88
Automatic Smart
Petrol Pump System
PROJECT REPORT
Submitted in the partial fulllment of the requirement for the award of the
deree of
!AC"E#OR O$ TEC"%O#O&'
(%
E#ECTRO%(CS A%) CO**+%(CAT(O% E%&(%EER(%&
S+!*(TTE) TO , S+!*(TTE) !',
*r- RA.(/A%T S"AR*A Amit Patha0
1234567
!anish &upta
1!T#3482397
"imanshu %ei
1232367 Jyoti Sharma
1!T#3482357
/alyani 1232397
1
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
2/88
&reen "ills &roup of (nstitutes /umarhatti:
Solan 1"-P-7
CO*PA%' PRO$(#E
INFOWIZ is leading strategic IT Company ofering integrated IT
solution. INFOWIZ is having rich experience managing gloal clients
across various usiness verticals and align IT strategies to achieve
usiness goals. The various accreditations that !e achieved "or every
service# !e ofer re$ect our commitment to!ards the %uality
assurance.
(%$O;(< is a & years young organi'ation !hich has !on the
%AT(O%A# A;AR) "or = consecuti>e years =42?@=426 =426@28
"or !EST (ndustrial Trainin "rom "onB able &O.ER%ER of Punab
"aryana Sh- /aptan Sinh Solan0i- (e is also the Chancellor of
PT+ Punabi +ni>ersity. INFOWIZ is a memer o" Con"ederation o"
Indian Industry ) C(( membership number D %?86?P * + also
!ith an(SO Certication. We have a gloal "oot prints in providing the of
shore companies o" ,-# ,# France# Ireland# Canada and /ustralia !ith
%uality and timely We and -0O services.
INFOWIZ is an organization which is established in the field of Web Development (PHP
!N"#$% &'' ()ore as well as 'dvance$% I*phone 'ndroid 'pplications% "mbedded
s+stems (',% PI) ',-$%'.tomation% ,O/O#I)0% Networ1ing (-)0"% ))N'
,H0"$ in -echanical!
O.r s1illed team of professionals ma1e s.re that the prod.ct is developed as per thec.stomer2s needs and 1eeping the c.stomer informed abo.t the development of their
pro3ect from time to time! We do not onl+ emphasize on form.lating an attractive sol.tion
to o.r clients b.t also believe in providing a wor1able sol.tion! INFOWIZ offers research
based 0earch "ngine -ar1eting prod.cts that help achieve greater insights to c.stomer2s
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
3/88
online b.siness! O.r ,esearch Development arm offers 0"O tools for 0"-
professionals!
INFOWIZ also provides Technical Support & Consultancy to 0oftware )ompanies li1e
&I' 4ro.p% Newzealand% 0agitech sol.tions Panch1.la% &arc infotech -ohali% Infonet0ol.tion% Delhi etc!
Our Hottest Clients & Projects:-
PROJECTS URL’s COUTR!
5 iva 0ales www!infowiz!in6vivasales 78
9 -ds)reative www!mdscreative!com 4erman+
: ;iddle # www!filmon!com 78
< Paradigms('ndroid$ r.nning '.stralia
= Printcost www!popgraphics!net 78
> P0#DO/ootstrap www!bootstrap!achieversperfect!com 70'
? "ssencesoftwares www!essencesoftwares!com '.stralia
@ Dashboard(Wordpress$ r.nning 70'
A$ ,ealstate www!realestate!infowiz!in ,.ssia
5B$Dealpartners(WordPress$2
http://infowiz.in/vivasaleshttp://www.mdscreative.com/http://www.filmon.com/http://www.popgraphics.net/http://www.essencesoftwares.com/http://www.realestate.infowiz.in/http://www.mdscreative.com/http://www.filmon.com/http://www.popgraphics.net/http://www.essencesoftwares.com/http://www.realestate.infowiz.in/http://infowiz.in/vivasales
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
4/88
www!dealpartners!co!.1!gridhosted!co!.1 78
55$ ;ittletonvine+ard www!littletonvine+ard!net 70'
59$ 4pa1offshore www!gpa1offshore!com 78
3
http://www.littletonvineyard.net/http://www.littletonvineyard.net/
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
5/88
OUR TE"#:-
$" Ship is as %oo as the cre' 'ho sail her!(
O.r #echnical team of professionals handing% designing delivering of pro3ects has astrong presence in the North India the 70! O.r engineers are alread+ wor1ing on the
latest technologies li1e )-Phone & "nroi 'pplications% Ro*otics% +LS)-+H,L%
"mbedded 0+stem% Networ1ing and Clou coputin%.
5$ Dr! 0eema
(#ana%in% ,irector$
0he is the bac1bone of INFOWIZ and a woman with more than A +ear rich practical
eCperience
who believes in ta1ing .p new vent.res and pro3ects!
9$ -r! ,a3eev Na++ar
(,eputy ,irector$
' man who strongl+ feel that Nothing is ImpossibleE! ' ver+ committed team
leader who has
4
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
6/88
been professionall+ attached with -.ltinational companies for more than 5@ +ears
and has lead
the mar1eting teams in all states of North India!
:$ -r! Deepa1 8as+ap
/0ranch #ana%er1
' man who believes that Hono.r #ime Place% then +o. will be hono.red!E he has
more
than < +ears solid ind.strial eCperience in a software companies is ver+ dashingand innovative
in his technical approach!
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
7/88
ma1e them great!E 0he has more than < +ears eCperience in mar1eting field!
>$ "r! ishal 4o+al
(Hea & Technical "2isor at US 0ranch$
-ore than 5B +ears ind.strial eCperience in 70 and smooth handling of the entire 70
b.siness!
?$ "r! .1ti &indal
(Center Hea- US 0ranch$
' woman who firml+ believes that In life% where +o. reach largel+ depends .pon
where +o.
start!E 0he 3oined this branch in the +ear 9BB? and has given her immense inp.ts in
bringing the
compan+ to its present stat.s!
COURSES O33ere :-
4or CSE5)T5#C" Pro3essionals:-
5$ Web Development in PHP with ;I" Pro3ects
9$ Web Development in !N"# with ;I" Pro3ects
:$ &'' ()ore as well as 'dvance $ with ;I" Pro3ects
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
8/88
>$ )G% )onsole 'pplications% /!N"#% '0P!N"#
?$ -+0;% 0;% O,');"
@$ Networ1ing (-)0"% ))N'% ,H0"$
A$ 0"O (0earch "ngine Optimization$
4or ECE5EE5E)E5#E5C)+)L Pro3essionals:-
5$ ,obotics With ;ive Pro3ect9$ ;0I*HD; with ;ive Pro3ect:$ "mbedded 0+stem Design with ;ive Pro3ect$ P)/ Designing?$ ', PI) Famil+@$ P)/ and la+o.t designingA$ '7#O-'#ION with ;ive Pro3ect5B$ Pro3ect development with ',- processors55$ )'#I'% P,O*"% '7#O)'D% 0O;ID WO,80!
O.r core strength is o.r timel+% technicall+ and cost effective pro3ect deliver+! We also providec.stomers with designs as per their demands! INFOWIZ also provide JO0 Oriente )nustrial
Trainin% o3 6 year an 75859 #onths in )0"% I#% ")"% ""% -"% )ivil% //'%/)'%-/'% -)'
also for Non*technical st.dents ! We help st.dents in b.ilding their career!
For INFOWIZ
&
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
9/88
"ress:-
7
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
10/88
SCO 66-66;-69<
0aseent Su* City Centre
Sector =8-" Chani%arh /67
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
11/88
=!9 )ON)"P# OF )O-PI;",
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
12/88
A!9 POW", ON #"0# @:
55! ,"07;#0 'ND DI0)700ION0 @<
59! )ON);70ION @=
5:! /I/;IO4,'PH @>
L)ST O4 4)URES P"E O.
9!5!5 00#"- D"0I4N )';;0 5
9!5!9 "-/"DD"D 00#"- D"0I4N )';;0 9
:!5!5 /;O)8 DI'4,'- :
>!5!5 POW", 07PP; )I,)7I# =:
>!5!9 )I,)7I# DI'4,'- =:
>!5!: ,";' )ONN")#ION0 #O -I),O)ON#,O;;", =>
1
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
13/88
"0STR"CT
Owing to the critical sit.ations which ma+ eCist in different locations% it becomes ver+
diffic.lt to wor1 at these places! One of the sit.ation is filling of oil in vehicles d.ring bitter cold
and sarcastic climate! #his led to the idea to a.tomate the petrol p.mp! Often wor1ing at late
night with hard cash has the ris1 of being robbed and ma+ lead to life threatening sit.ation! #he
goal of the pro3ect is to aid the trade*person and cons.mer in s.ch adverse circ.mstances!
#he demands for a.tomated prod.cts with programmabilit+ are growing da+ b+ da+!
'.tomation has been achieved b+ vario.s means incl.ding mechanical% h+dra.lic% pne.matic%
electrical and electronic and comp.ters% .s.all+ in combination! In toda+2s fast growing world
there is a need to find distinct wa+s for providing facilities to the .sers so as to meet the
growing standards! 4enerall+ the familiar method of filling vehicle tan1 is done man.all+ b+
wor1er present at the spot which often .se different .nfair means to fill their poc1ets! #he
p.rpose of the pro3ect is the realization of a compact% low cost .ser demanded facilit+!
'.tomation of a machine increases the acc.rac+ of the wor1!
12
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
14/88
)TRO,UCT)O TO E#0E,,E, S!STE#S
Dhat is e*ee systeF
'n "mbedded 0+stem is a combination of comp.ter hardware and software% and perhaps
additional mechanical or other parts% designed to perform a specific f.nction! 'n embedded
s+stem is a microcontroller*based% software driven% reliable% real*time control s+stem%
a.tonomo.s% or h.man or networ1 interactive% operating on diverse ph+sical variables and indiverse environments and sold into a competitive and cost conscio.s mar1et!
'n embedded s+stem is not a comp.ter s+stem that is .sed primaril+ for processing% not a
software s+stem on P) or 7NIK% not a traditional b.siness or scientific application! High*end
embedded lower end embedded s+stems! High*end embedded s+stem * 4enerall+ :9% >< /it
)ontrollers .sed with O0! "Camples Personal Digital 'ssistant and -obile phones etc! !;ower
end embedded s+stems * 4enerall+ @%5> /it )ontrollers .sed with an minimal operating s+stems
and hardware la+o.t designed for the specific p.rpose! "Camples 0mall controllers and devices
in o.r ever+da+ life li1e Washing -achine% -icrowave Ovens% where the+ are embedded in!
13
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
15/88
E*eeSystes
)omp.ter 'rchitect.re
0oftware"ngineering
Data)omm.nication
)ontr ol"ngineering
"lectric motorsand act.ators
0ensors andmeas.rements
'nalog"lectronic design
Digital"lectronic design
Integrated circ.itdesign
E*ee syste esi%n calls on any isciplines
Operating Systems
BuildDownloadDebugTools
S!STE# ,ES) C"LLS:
FigL9!5!5 00#"- D"0I4N )';;0
14
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
16/88
SystemTesting
SystemDefinition
Targeting
RapidPrototypi
ng
Hardware-in-the-Lo
opTesting
E#0E,,E, S!STE# ,ES) C!CLE
Fig.ren 9!5!9 DiagramE
Characteristics o3 E*ee Syste
M 'n embedded s+stem is an+ comp.ter s+stem hidden inside a prod.ct other than a
comp.ter!
M #he+ will enco.nter a n.mber of diffic.lties when writing embedded s+stem software in
addition to those we enco.nter when we write applications
15
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
17/88
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
18/88
CL"SS)4)C"T)O
• ,eal #ime 0+stems!
• ,#0 is one which has to respond to events within a specified deadline!
• ' right answer after the dead line is a wrong answer
RTS CL"SS)4)C"T)O
• Hard ,eal #ime 0+stems
• 0oft ,eal #ime 0+stem
H"R, RE"L T)#E S!STE#
• QHardQ real*time s+stems have ver+ narrow response time!
• "CampleL N.clear power s+stem% )ardiac pacema1er!
SO4T RE"L T)#E S!STE#
• Q0oftQ real*time s+stems have red.ced constrains on QlatenessQ b.t still m.st operate ver+
.ic1l+ and repeatable!
• "CampleL ,ailwa+ reservation s+stem ta1es a few eCtra seconds the data remains valid
=. 0LOC@ ,)"R"#
1&
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
19/88
8. H"R,D"RE REGU)RE#ETS
H"R,D"RE CO#POETS
5! #,'N0FO,-", (9:B 59 ')$
9! O;#'4" ,"47;'#O, (;- ?@B=$
:! ,")#IFI",
>! /)=
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
20/88
55! ,FID ,eader
59! ,ela+
5:! ;)D 5>9
8.6 - TR"S4OR#ER
#ransformers convert ') electricit+ from one voltage to another with a little loss of power! 0tep*
.p transformers increase voltage% step*down transformers red.ce voltage! -ost power s.pplies
.se a step*down transformer to red.ce the dangero.sl+ high voltage to a safer low voltage!
FI4
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
21/88
#he ratio of the n.mber of t.rns on each coil% called the t.rn2s ratio% determines the ratio
of the voltages! ' step*down transformer has a large n.mber of t.rns on its primar+ (inp.t$ coil
which is connected to the high voltage mains s.ppl+% and a small n.mber of t.rns on its
secondar+ (o.tp.t$ coil to give a low o.tp.t voltage!
#7,N0 ,'#IO R (p 6 s$ R ( Np 6 Ns $
Where%
p R primar+ (inp.t$ voltage!
s R secondar+ (o.tp.t$ voltage
Np R n.mber of t.rns on primar+ coil
Ns R n.mber of t.rns on secondar+ coil
Ip R primar+ (inp.t$ c.rrent
Is R secondar+ (o.tp.t$ c.rrent!
)eal po'er euation
#he ideal transformer as a circ.it element
If the secondar+ coil is attached to a load that allows c.rrent to flow% electrical power is
transmitted from the primar+ circ.it to the secondar+ circ.it! Ideall+% the transformer is perfectl+
efficient all the incoming energ+ is transformed from the primar+ circ.it to the magnetic fieldand into the secondar+ circ.it! If this condition is met% the incoming electric power m.st e.al
the o.tgoing powerL
1
http://en.wikipedia.org/wiki/Magnetic_fieldhttp://en.wikipedia.org/wiki/Electric_powerhttp://en.wikipedia.org/wiki/Magnetic_fieldhttp://en.wikipedia.org/wiki/Electric_power
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
22/88
4iving the ideal transformer e.ation
#ransformers normall+ have high efficienc+% so this form.la is a reasonable approCimation!
If the voltage is increased% then the c.rrent is decreased b+ the same factor! #he impedance in
one circ.it is transformed b+ the square of the t.rns ratio! For eCample% if an impedance Z s is
attached across the terminals of the secondar+ coil% it appears to the primar+ circ.it to have an
impedance of ( N p6 N s$9 Z s! #his relationship is reciprocal% so that the impedance Z p of the primar+
circ.it appears to the secondar+ to be ( N s6 N p$9 Z p!
8.9 - +OLT"E REUL"TOR >
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
23/88
,escription
#he ;-?@KK6;-?@KK' series of three*terminal positive reg.lators are available in the
#O*99B6D*P'8 pac1age and with several fiCed o.tp.t voltages% ma1ing them .sef.l in a Wide
range of applications! "ach t+pe emplo+s internal c.rrent limiting% thermal sh.tdown and safe
operating area protection% ma1ing it essentiall+ indestr.ctible! If ade.ate heat sin1ing is
provided% the+ can deliver over 5' o.tp.t ).rrent! 'ltho.gh designed primaril+ as fiCed voltage
reg.lators% these devices can be .sed with eCternal components to obtain ad3.stable voltages and
c.rrents!
)nternal 0locI ,ia%ra
2
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
24/88
FI4
"*solute #aiu Ratin%s
#'/;"
rectifier! In this pro3ect% a bridge rectifier is .sed beca.se of its merits li1e good stabilit+ and f.ll
3
http://en.wikipedia.org/wiki/Alternating_currenthttp://en.wikipedia.org/wiki/Direct_currenthttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/Detector_(radio)http://en.wikipedia.org/wiki/Detector_(radio)http://en.wikipedia.org/wiki/Radiohttp://en.wikipedia.org/wiki/Solid_state_(electronics)http://en.wikipedia.org/wiki/Solid_state_(electronics)http://en.wikipedia.org/wiki/Diodehttp://en.wikipedia.org/wiki/Diodehttp://en.wikipedia.org/wiki/Vacuum_tubehttp://en.wikipedia.org/wiki/Vacuum_tubehttp://en.wikipedia.org/wiki/Mercury_arc_valvehttp://en.wikipedia.org/wiki/Alternating_currenthttp://en.wikipedia.org/wiki/Direct_currenthttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/Detector_(radio)http://en.wikipedia.org/wiki/Radiohttp://en.wikipedia.org/wiki/Solid_state_(electronics)http://en.wikipedia.org/wiki/Diodehttp://en.wikipedia.org/wiki/Vacuum_tubehttp://en.wikipedia.org/wiki/Vacuum_tubehttp://en.wikipedia.org/wiki/Mercury_arc_valve
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
25/88
wave rectification! In positive half c+cle onl+ two diodes( 5 set of parallel diodes$ will cond.ct%
in negative half c+cle remaining two diodes will cond.ct and the+ will cond.ct onl+ in forward
bias onl+!
8.8 - 4)LTER
4
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
26/88
)apacitive filter is .sed in this pro3ect! It removes the ripples from the o.tp.t of rectifier and
smoothens the D!)! O.tp.t received from this filter is constant .ntil the mains voltage and load
is maintained constant! However% if either of the two is varied% D!)! voltage received at this point
changes! #herefore a reg.lator is applied at the o.tp.t stage!
#he simple capacitor filter is the most basic t+pe of power s.ppl+ filter! #he .se of this
filter is ver+ limited! It is sometimes .sed on eCtremel+ high*voltage% low*c.rrent power s.pplies
for cathode*ra+ and similar electron t.bes that re.ire ver+ little load c.rrent from the s.ppl+!
#his filter is also .sed in circ.its where the power*s.ppl+ ripple fre.enc+ is not critical and can
be relativel+ high! /elow fig.re can show how the capacitor changes and discharges!
8.? - #)CROCOTROLLER "T;S?9
5
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
27/88
)ntrouction:
#he '#@A0=9 is a low*power% high*performance )-O0 @*bit microcontroller with @8
b+tes of in*s+stem programmable Flash memor+! #he device is man.fact.red .sing 'tmel2s
high*densit+ non volatile memor+ technolog+ and is compatible with the ind.str+ standard
@B)=5 instr.ction set and pin o.t! #he on*chip Flash allows the program memor+ to be
reprogrammed in*s+stem or b+ a conventional non volatile memor+ programmer! /+ combining
a versatile @*bit )P7 with in*s+stem programmable Flash on a monolithic chip% the 'tmel
'#@A0=9 is a powerf.l microcontroller which provides a highl+*fleCible and cost*effective
sol.tion to man+ embedded control applications! #he '#@A0=9 provides the following standard
feat.resL @8 b+tes of Flash% 9=> b+tes of ,'-% :9 I6O lines% Watchdog timer% two data pointers%
three 5>*bit timer6co.nters% a siC*vector two*level interr.pt architect.re% a f.ll d.pleC serial port%
on*chip oscillator% and cloc1 circ.itr+! In addition% the '#@A0=9 is designed with static logic for
operation down to zero fre.enc+ and s.pports two software selectable power saving modes! #he
Idle -ode stops the )P7 while allowing the ,'-% timer6co.nters% serial port% and interr.pt
s+stem to contin.e f.nctioning! #he Power*down mode saves the ,'- contents b.t freezes the
oscillator% disabling all other chip f.nctions .ntil the neCt interr.pt or hardware reset!
4eatures:
M )ompatible with -)0S*=5 Prod.cts
M @8 /+tes of In*0+stem Programmable (I0P$ Flash -emor+
"nd.ranceL 5B%BBB Write6"rase )+cles
M
M F.ll+ 0tatic OperationL B Hz to :: -Hz
M #hree*level Program -emor+ ;oc1
M 9=> C @*bit Internal ,'-
M :9 Programmable I6O ;ines
M #hree 5>*bit #imer6)o.nters
M "ight Interr.pt 0o.rces
M F.ll D.pleC 7',# 0erial )hannel
6
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
28/88
M ;ow*power Idle and Power*down -odes
M Interr.pt ,ecover+ from Power*down -ode
M Watchdog #imer
M D.al Data Pointer
M Power*off Flag
M Fast Programming #ime
M FleCible I0P Programming (/+te and Page -ode$
M 4reen (Pb6Halide*free$ Pac1aging Option
0locI ,ia%ra o3 "T;S?9:
FI4
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
29/88
Pin Con3i%urations o3 "T;S?9
FI4
eight ##; inp.ts! When 5s are written to port B pins% the pins can be .sed as high*impedance
inp.ts! Port B can also be config.red to be the m.ltipleCed low*order address6data b.s d.ring7
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
30/88
accesses to eCternal program and data memor+! In this mode% PB has internal p.ll*.ps! Port B also
receives the code b+tes d.ring Flash programming and o.tp.ts the code b+tes d.ring program
verification! "Cternal p.ll*.ps are re.ired d.ring program verification!
Port 6:
Port 5 is an @*bit bidirectional I6O port with internal p.ll*.ps! #he Port 5 o.tp.t b.ffers
can sin16so.rce fo.r ##; inp.ts! When 5s are written to Port 5 pins% the+ are p.lled high b+ the
internal p.ll*.ps and can be .sed as inp.ts! 's inp.ts% Port 5 pins that are eCternall+ being p.lled
low will so.rce c.rrent (II;$ beca.se of the internal p.ll*.ps! In addition% P5!B and P5!5 can be
config.red to be the timer6co.nter 9 eCternal co.nt inp.t (P5!B6#9$ and the timer6co.nter 9
trigger inp.t (P5!56#9"K$!
Port 9:
Port 9 is an @*bit bidirectional I6O port with internal p.ll*.ps! #he Port 9 o.tp.t b.ffers
can sin16so.rce fo.r ##; inp.ts! When 5s are written to Port 9 pins% the+ are p.lled high b+ the
internal p.ll*.ps and can be .sed as inp.ts! 's inp.ts% Port 9 pins that are eCternall+ being p.lled
low will so.rce c.rrent (II;$ beca.se of the internal p.ll*.ps! Port 9 emits the high*order address
b+te d.ring fetches from eCternal program memor+ and d.ring accesses to eCternal data memor+
that .se 5>*bit addresses (-OK T DP#,$! In this application% Port 9 .ses strong internal p.ll*.ps when emitting 5s! D.ring accesses to eCternal data memor+ that .se @*bit addresses (-OK
T ,I$% Port 9 emits the contents of the P9 0pecial F.nction ,egister!
Port =:
Port : is an @*bit bidirectional I6O port with internal p.ll*.ps! #he Port : o.tp.t b.ffers
can sin16so.rce fo.r ##; inp.ts! When 5s are written to Port : pins% the+ are p.lled high b+ the
internal p.ll*.ps and can be .sed as inp.ts! 's inp.ts% Port : pins that are eCternall+ being p.lled
low will so.rce c.rrent (II;$ beca.se of the p.ll*.ps!
RST:
28
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
31/88
,eset inp.t! ' high on this pin for two machine c+cles while the oscillator is r.nning
resets the device! #his pin drives high for A@ oscillator periods after the Watchdog times o.t! #he
DI0,#O bit in 0F, '7K, (address @"H$ can be .sed to disable this feat.re! In the defa.lt state
of bit DI0,#O% the ,"0"# HI4H o.t feat.re is enabled!
"LE5PRO:
'ddress ;atch "nable (';"$ is an o.tp.t p.lse for latching the low b+te of the address
d.ring accesses to eCternal memor+! #his pin is also the program p.lse inp.t (P,O4$ d.ring
Flash programming!
In normal operation% ';" is emitted at a constant rate of 56> the oscillator fre.enc+ and ma+ be
.sed for eCternal timing or cloc1ing p.rposes! Note% however% that one ';" p.lse is s1ipped
d.ring each access to eCternal data memor+!
PSE:
Program 0tore "nable (P0"N$ is the read strobe to eCternal program memor+! When the
'#@A0=9 is eCec.ting code from eCternal program memor+% P0"N is activated twice each
machine c+cle% eCcept that two P0"N activations are s1ipped d.ring each access to eCternal data
memor+!
E"5+PP:
"Cternal 'ccess "nable! "' m.st be strapped to 4ND in order to enable the device to
fetch code from eCternal program memor+ locations starting at BBBBH .p to FFFFH! Note%
however% that if loc1 bit 5 is programmed% "' will be internall+ latched on reset! "' sho.ld be
strapped to )) for internal program eCec.tions! #his pin also receives the 59*volt
programming enable voltage (PP$ d.ring Flash programming!
KT"L6:
Inp.t to the inverting oscillator amplifier and inp.t to the internal cloc1 operating circ.it!
KT"L9:
O.tp.t from the inverting oscillator amplifier!
21
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
32/88
Oscillator Characteristics:
K#';5 and K#';9 are the inp.t and o.tp.t% respectivel+% of an inverting amplifier
which can be config.red for .se as an on*chip oscillator% as shown in Fig.re 5! "ither a .artz
cr+stal or ceramic resonator ma+ be .sed! #o drive the device from an eCternal cloc1 so.rce%
K#';9 sho.ld be left .nconnected while K#';5 is driven as shown in Fig.re >!9! #here are no
re.irements on the d.t+ c+cle of the eCternal cloc1 signal% since the inp.t to the internal
cloc1ing circ.itr+ is thro.gh a divide*b+*two flip*flop% b.t minim.m and maCim.m voltage high
and low time specifications m.st be observed!
FI4
FI4
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
33/88
)le #oe
In idle mode% the )P7 p.ts itself to sleep while all the on chip peripherals remain active! #he
mode is invo1ed b+ software! #he content of the on*chip ,'- and all the special f.nctionsregisters remain .nchanged d.ring this mode! #he idle mode can be terminated b+ an+ enabled
interr.pt or b+ a hardware reset!
Po'er o'n #oe
In the power down mode the oscillator is stopped% and the instr.ction that invo1es power
down is the last instr.ction eCec.ted! #he on*chip ,'- and 0pecial F.nction ,egisters retain
their val.es .ntil the power down mode is terminated! #he onl+ eCit from power down is a
hardware reset! ,eset redefines the 0F,s b.t does not change the on*chip ,'-! #he reset sho.ld
not be activated before )) is restored to its normal operating level and m.st be held active
long eno.gh to allow the oscillator to restart and stabilize!
8.7 - LE,’S
;"Ds are semicond.ctor devices! ;i1e transistors% and other diodes% ;"Ds are made o.t of
silicon! What ma1es an ;"D give off light are the small amo.nts of chemical imp.rities that areadded to the silicon% s.ch as galli.m% arsenide% indi.m% and nitride!
When c.rrent passes thro.gh the ;"D% it emits photons as a b+prod.ct! Normal light
b.lbs prod.ce light b+ heating a metal filament .ntil it is white hot! ;"Ds prod.ce photons
directl+ and not via heat% the+ are far more efficient than incandescent b.lbs!
Fig
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
34/88
Not long ago ;"Ds were onl+ bright eno.gh to be .sed as indicators on dashboards or
electronic e.ipment! /.t recent advances have made ;"Ds bright eno.gh to rival traditional
lighting technologies! -odern ;"Ds can replace incandescent b.lbs in almost an+ application!
Types o3 LE,’S
;"Ds are prod.ced in an arra+ of shapes and sizes! #he = mm c+lindrical pac1age is the most
common% estimated at @BU of world prod.ction! #he color of the plastic lens is often the same as the
act.al color of light emitted% b.t not alwa+s! For instance% p.rple plastic is often .sed for infrared
;"Ds% and most bl.e devices have clear ho.sings! #here are also ;"Ds in eCtremel+ tin+ pac1ages%
s.ch as those fo.nd on blin1ers and on cell phone 1e+pads! #he main t+pes of ;"Ds are miniat.re%
high power devices and c.stom designs s.ch as alphan.meric or m.lti*color!
Fig
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
35/88
still prett+ eCpensive as compared to a 4OW lamp b.t draw m.ch less c.rrent and pro3ect a
fairl+ well foc.sed beam!
#he diode in the photo came with a neat little reflector that tends to sharpen the beam a
little b.t doesnVt seem to add m.ch to the overall intensit+!
When r.n within their ratings% the+ are more reliable than lamps as well! ,ed ;"Ds are
now being .sed in a.tomotive and tr.c1 tail lights and in red traffic signal lights! o. will be
able to detect them beca.se the+ loo1 li1e an arra+ of point so.rces and the+ go on and off
instantl+ as compared to conventional incandescent lamps!
24
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
36/88
;"Ds are monochromatic (one color$ devices! #he color is determined b+ the band gap of
the semicond.ctor .sed to ma1e them! ,ed% green% +ellow and bl.e ;"Ds are fairl+ common!
White light contains all colors and cannot be directl+ created b+ a single ;"D! #he most
common form of QwhiteQ ;"D reall+ isnVt white! It is a 4alli.m Nitride bl.e ;"D coated with a
phosphor that% when eCcited b+ the bl.e ;"D light% emits a broad range spectr.m that in addition
to the bl.e emission% ma1es a fairl+ white light!
#here is a claim that these white ;"DVs have a limited life! 'fter 5BBB ho.rs or so of
operation% the+ tend to +ellow and dim to some eCtent! ,.nning the ;"Ds at more than their
rated c.rrent will certainl+ accelerate this process!
#here are two primar+ wa+s of prod.cing high intensit+ white*light .sing ;"D20! One is
to .se individ.al ;"D20 that emit three primar+ colo.rs red% green% and bl.eand then miC all
the colo.rs to form white light! #he other is to .se a phosphor material to convert
monochromatic light from a bl.e or 7 ;"D to broad*spectr.m white light% m.ch in the same
wa+ a fl.orescent light b.lb wor1s! D.e to metamerism% it is possible to have .ite different
spectra that appear white!
"2anta%es o3 usin% LE,s
E33iciency:
;"Ds prod.ce more light per watt than incandescent b.lbs this is .sef.l in
batter+ powered or energ+*saving devices!
Sie:
25
http://www.bivar.com/bullethtml/bull-nov2.htmhttp://en.wikipedia.org/wiki/Primary_colorhttp://en.wikipedia.org/wiki/Metamerism_(color)http://www.bivar.com/bullethtml/bull-nov2.htmhttp://en.wikipedia.org/wiki/Primary_colorhttp://en.wikipedia.org/wiki/Metamerism_(color)
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
37/88
;"Ds can be ver+ small (smaller than 9 mm9$ and are easil+ pop.lated onto
printed circ.it boards!
On5O33 tie:
;"Ds light .p ver+ .ic1l+! ' t+pical red indicator ;"D will achieve f.ll
brightness in microseconds! ;"Ds .sed in comm.nications devices can have even
faster response times!
Cyclin%:
;"Ds are ideal for .se in applications that are s.b3ect to fre.ent on*off c+cling%
.nli1e fl.orescent lamps that b.rn o.t more .ic1l+ when c+cled fre.entl+% or
HID lamps that re.ire a long time before restarting!
Cool li%ht:
In contrast to most light so.rces% ;"Ds radiate ver+ little heat in the form of I,
that can ca.se damage to sensitive ob3ects or fabrics! Wasted energ+ is dispersed
as heat thro.gh the base of the ;"D!
Li3etie:
;"Ds can have a relativel+ long .sef.l life! One report estimates :=%BBB to =B%BBB
ho.rs of .sef.l life% tho.gh time to complete fail.re ma+ be longer!
o Toicity:
;"Ds do not contain merc.r+% .nli1e fl.orescent lamps!
,isa2anta%es o3 usin% LE,s
26
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
38/88
Hi%h price:
;"Ds are c.rrentl+ more eCpensive% price per l.men% on an initial capital cost
basis% than most conventional lighting technologies!
Teperature epenence:
;"D performance largel+ depends on the ambient temperat.re of the operating
environment! Over*driving the ;"D in high ambient temperat.res ma+ res.lt in
overheating of the ;"D pac1age% event.all+ leading to device fail.re!
+olta%e sensiti2ity:
;"Ds m.st be s.pplied with the voltage above the threshold and a c.rrent below
the rating! #his can involve series resistors or c.rrent*reg.lated power s.pplies!
"rea li%ht source:
;"Ds do not approCimate a point so.rceE of light% b.t rather a lambertian
distrib.tion! 0o ;"Ds are diffic.lt to .se in applications re.iring a spherical light
field! ;"Ds are not capable of providing divergence below a few degrees! #his is
contrasted with lasers% which can prod.ce beams with divergences of B!9 degrees
or less!
0lue Haar:
#here is increasing concern that bl.e ;"Ds and cool*white ;"Ds are now capable
of eCceeding safe limits of the so*called bl.e*light hazard as defined in e+e safet+!
8.> - 0C?8>
TECH)C"L SPEC)4)C"T)OS:
2&
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
39/88
#he /)=
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
40/88
8. - 68
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
41/88
• Diodes of n.mber IN
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
42/88
3.st as c.rrent wo.ld flow in a copper wire! #his is shown in fig.re 5*5=! #he positive potential
of the batter+ will attract the free electrons in the cr+stal! #hese electrons will leave the cr+stal
and flow into the positive terminal of the batter+! 's an electron leaves the cr+stal% an electron
from the negative terminal of the batter+ will enter the cr+stal% th.s completing the c.rrent path!
#herefore% the ma3orit+ c.rrent carriers in the N*t+pe material (electrons$ are repelled b+ the
negative side of the batter+ and move thro.gh the cr+stal toward the positive side of the batter+!
Current 4lo' in the P-Type #aterial
).rrent flow thro.gh the P*t+pe material is ill.strated! )ond.ction in the P material is b+
positive holes% instead of negative electrons! ' hole moves from the positive terminal of the P
material to the negative terminal! "lectrons from the eCternal circ.it enter the negative terminal
of the material and fill holes in the vicinit+ of this terminal! 't the positive terminal% electrons are
removed from the covalent bonds% th.s creating new holes! #his process contin.es as the stead+
stream of holes (hole c.rrent$ moves toward the negative terminal
8.; - RES)STORS
' resistor is a two*terminal electronic component designed to oppose an electric c.rrent b+ prod.cing a voltage drop between its terminals in proportion to the c.rrent% that is% in accordance
with OhmVs lawL
V R IR
,esistors are .sed as part of electrical networ1s and electronic circ.its! #he+ are eCtremel+
commonplace in most electronic e.ipment! Practical resistors can be made of vario.s
compo.nds and films% as well as resistance wire (wire made of a high*resistivit+ allo+% s.ch as
nic1el6chrome$!
#he primar+ characteristics of resistors are their resistance and the power the+ can
dissipate! Other characteristics incl.de temperat.re coefficient% noise% and ind.ctance! ;ess well*
1nown is critical resistance% the val.e below which power dissipation limits the maCim.m
permitted c.rrent flow% and above which the limit is applied voltage! )ritical resistance depends
3
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
43/88
.pon the materials constit.ting the resistor as well as its ph+sical dimensions itVs determined b+
design!
,esistors can be integrated into h+brid and printed circ.its% as well as integrated
circ.its! 0ize% and position of leads (or terminals$ are relevant to e.ipment designers resistors
m.st be ph+sicall+ large eno.gh not to overheat when dissipating their power!
' resistor is a two*terminal passive electronic component which implements electrical
resistance as a circ.it element! When a voltage is applied across the terminals of a resistor% a
c.rrent I will flow thro.gh the resistor in direct proportion to that voltage! #he reciprocal of the
constant of proportionalit+ is 1nown as the resistance ,% since% with a given voltage % a larger
val.e of , f.rther QresistsQ the flow of c.rrent I as given b+ OhmVs lawL
,esistors are common elements of electrical networ1s and electronic circ.its and are
.bi.ito.s in most electronic e.ipment! Practical resistors can be made of vario.s compo.nds
and films% as well as resistance wire (wire made of a high*resistivit+ allo+% s.ch as nic1el*
chrome$! ,esistors are also implemented within integrated circ.its% partic.larl+ analog devices%
and can also be integrated into h+brid and printed circ.its!
32
http://en.wikipedia.org/wiki/Terminal_(electronics)http://en.wikipedia.org/wiki/Passivity_(engineering)http://en.wikipedia.org/wiki/Electronic_componenthttp://en.wikipedia.org/wiki/Electronic_componenthttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Direct_proportionhttp://en.wikipedia.org/wiki/Resistancehttp://en.wikipedia.org/wiki/Resistancehttp://en.wikipedia.org/wiki/Ohm's_lawhttp://en.wikipedia.org/wiki/Electrical_networkshttp://en.wikipedia.org/wiki/Resistance_wirehttp://en.wikipedia.org/wiki/Integrated_circuitshttp://en.wikipedia.org/wiki/Hybrid_circuithttp://en.wikipedia.org/wiki/Printed_circuit_boardhttp://en.wikipedia.org/wiki/Printed_circuit_boardhttp://en.wikipedia.org/wiki/Terminal_(electronics)http://en.wikipedia.org/wiki/Passivity_(engineering)http://en.wikipedia.org/wiki/Electronic_componenthttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Direct_proportionhttp://en.wikipedia.org/wiki/Resistancehttp://en.wikipedia.org/wiki/Ohm's_lawhttp://en.wikipedia.org/wiki/Electrical_networkshttp://en.wikipedia.org/wiki/Resistance_wirehttp://en.wikipedia.org/wiki/Integrated_circuitshttp://en.wikipedia.org/wiki/Hybrid_circuithttp://en.wikipedia.org/wiki/Printed_circuit_board
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
44/88
#he electrical f.nctionalit+ of a resistor is specified b+ its resistanceL common
commercial resistors are man.fact.red over a range of more than A orders of magnit.de! When
specif+ing that resistance in an electronic design% the re.ired precision of the resistance ma+
re.ire attention to the man.fact.ring tolerance of the chosen resistor% according to its specific
application! #he temperat.re coefficient of the resistance ma+ also be of concern in some
precision applications! Practical resistors are also specified as having a maCim.m power rating
which m.st eCceed the anticipated power dissipation of that resistor in a partic.lar circ.itL this is
mainl+ of concern in power electronics applications! ,esistors with higher power ratings are
ph+sicall+ larger and ma+ re.ire heat sin1ing! In a high voltage circ.it% attention m.st
sometimes be paid to the rated maCim.m wor1ing voltage of the resistor!
#he series ind.ctance of a practical resistor ca.ses its behavior to depart from ohms lawthis specification can be important in some high*fre.enc+ applications for smaller val.es of
resistance! In a low*noise amplifier or pre*amp the noise characteristics of a resistor ma+ be an
iss.e! #he .nwanted ind.ctance% eCcess noise% and temperat.re coefficient are mainl+ dependent
on the technolog+ .sed in man.fact.ring the resistor! #he+ are not normall+ specified
individ.all+ for a partic.lar famil+ of resistors man.fact.red .sing a partic.lar technolog+! '
famil+ of discrete resistors is also characterized according to its form factor% that is% the size of
the device and position of its leads (or terminals$ which is relevant in the practical man.fact.ring
of circ.its .sing them!
Units
#he ohm (s+mbolL $ is the 0I .nit of electrical resistance% named after 4eorg 0imon
Ohm! 'n ohm is e.ivalent to a volt per ampere! 0ince resistors are specified and man.fact.red
over a ver+ large range of val.es% the derived .nits of milliohm (5 m R 5B[: $% 1ilohm (5 1 R
5B: $% and megohm (5 - R 5B> $ are also in common .sage!
#he reciprocal of resistance , is called cond.ctance 4 R 56, and is meas.red in 0iemens
(0I .nit$% sometimes referred to as a mho! #h.s a 0iemens is the reciprocal of an ohmL S R [ 5!
'ltho.gh the concept of cond.ctance is often .sed in circ.it anal+sis% practical resistors are
alwa+s specified in terms of their resistance (ohms$ rather than cond.ctance!
33
http://en.wikipedia.org/wiki/Orders_of_magnitudehttp://en.wikipedia.org/wiki/Engineering_tolerance#Electrical_component_tolerancehttp://en.wikipedia.org/wiki/Engineering_tolerance#Electrical_component_tolerancehttp://en.wikipedia.org/wiki/Temperature_coefficienthttp://en.wikipedia.org/wiki/Power_(physics)http://en.wikipedia.org/wiki/Heat_sinkhttp://en.wikipedia.org/wiki/Heat_sinkhttp://en.wikipedia.org/wiki/Inductancehttp://en.wikipedia.org/wiki/Low-noise_amplifierhttp://en.wikipedia.org/wiki/Pre-amphttp://en.wikipedia.org/wiki/Ohm_(unit)http://en.wikipedia.org/wiki/%CE%A9http://en.wikipedia.org/wiki/%CE%A9http://en.wikipedia.org/wiki/SIhttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Georg_Simon_Ohmhttp://en.wikipedia.org/wiki/Georg_Simon_Ohmhttp://en.wikipedia.org/wiki/Volthttp://en.wikipedia.org/wiki/Volthttp://en.wikipedia.org/wiki/Amperehttp://en.wikipedia.org/wiki/Conductancehttp://en.wikipedia.org/wiki/Siemens_(unit)http://en.wikipedia.org/wiki/SIhttp://en.wikipedia.org/wiki/Mhohttp://en.wikipedia.org/wiki/Orders_of_magnitudehttp://en.wikipedia.org/wiki/Engineering_tolerance#Electrical_component_tolerancehttp://en.wikipedia.org/wiki/Temperature_coefficienthttp://en.wikipedia.org/wiki/Power_(physics)http://en.wikipedia.org/wiki/Heat_sinkhttp://en.wikipedia.org/wiki/Inductancehttp://en.wikipedia.org/wiki/Low-noise_amplifierhttp://en.wikipedia.org/wiki/Pre-amphttp://en.wikipedia.org/wiki/Ohm_(unit)http://en.wikipedia.org/wiki/%CE%A9http://en.wikipedia.org/wiki/SIhttp://en.wikipedia.org/wiki/Electrical_resistancehttp://en.wikipedia.org/wiki/Georg_Simon_Ohmhttp://en.wikipedia.org/wiki/Georg_Simon_Ohmhttp://en.wikipedia.org/wiki/Volthttp://en.wikipedia.org/wiki/Amperehttp://en.wikipedia.org/wiki/Conductancehttp://en.wikipedia.org/wiki/Siemens_(unit)http://en.wikipedia.org/wiki/SIhttp://en.wikipedia.org/wiki/Mho
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
45/88
+"R)"0LE RES)STORS
"justa*le resistors
' resistor ma+ have one or more fiCed tapping points so that the resistance can be
changed b+ moving the connecting wires to different terminals! 0ome wire wo.nd power
resistors have a tapping point that can slide along the resistance element% allowing a larger or
smaller part of the resistance to be .sed!
Where contin.o.s ad3.stment of the resistance val.e d.ring operation of e.ipment is
re.ired% the sliding resistance tap can be connected to a 1nob accessible to an operator! 0.ch a
device is called a rheostat and has two terminals!
Potentioeter
' potentiometer is a man.all+ ad3.stable resistor! #he wa+ this device wor1s is relativel+ simple!
One terminal of the potentiometer is connected to a power so.rce! 'nother is hoo1ed .p to gro.nd (a
point with no voltage or resistance and which serves as a ne.tral reference point$% while the third
terminal r.ns across a strip of resistive material! #his resistive strip generall+ has a low resistance at
one end its resistance grad.all+ increases to a maCim.m resistance at the other end! #he third terminal
serves as the connection between the power so.rce and gro.nd% and is .s.all+ interfaced to the .ser b+means of a 1nob or lever! #he .ser can ad3.st the position of the third terminal along the resistive strip
in order to man.all+ increase or decrease resistance! /+ controlling resistance% a potentiometer can
determine how m.ch c.rrent flow thro.gh a circ.it! When .sed to reg.late c.rrent% the potentiometer
is limited b+ the maCim.m resistivit+ of the strip!
#he power of this simple device is not to be .nderestimated! In most analog devices% a
potentiometer is what establishes the levels of o.tp.t! In a lo.d spea1er% for eCample% a potentiometer
directl+ ad3.sts vol.me in a television monitor% it controls brightness!
34
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
46/88
' potentiometer can also be .sed to control the potential difference% or voltage% across a circ.it!
#he set.p involved in .tilizing a potentiometer for this p.rpose is a little bit more complicated! It
involves two circ.itsL the first circ.it consists of a cell and a resistor! 't one end% the cell is connected
in series to the second circ.it% and at the other end it is connected to a potentiometer in parallel withthe second circ.it! #he potentiometer in this arrangement drops the voltage b+ an amo.nt e.al to the
ratio between the resistance allowed b+ the position of the third terminal and the highest possible
resistivit+ of the strip! In other words% if the 1nob controlling the resistance is positioned at the eCact
halfwa+ point on the resistive strip% then the o.tp.t voltage will drop b+ eCactl+ fift+ percent% no
matter how high the potentiometerVs inp.t voltage! 7nli1e with c.rrent reg.lation% voltage reg.lation is
not limited b+ the maCim.m resistivit+ of the strip
8.6< - C"P"C)TORS
' capacitor or condenser is a passive electronic component consisting of a pair of cond.ctors
separated b+ a dielectric! When a voltage potential difference eCists between the cond.ctors% an
electric field is present in the dielectric! #his field stores energ+ and prod.ces a mechanical force
between the plates! #he effect is greatest between wide% flat% parallel% narrowl+ separated
cond.ctors!
'n ideal capacitor is characterized b+ a single constant val.e% capacitance% which is
meas.red in farads! #his is the ratio of the electric charge on each cond.ctor to the potential
35
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
47/88
difference between them! In practice% the dielectric between the plates passes a small amo.nt of
lea1age c.rrent! #he cond.ctors and leads introd.ce an e.ivalent series resistance and the
dielectric has an electric field strength limit res.lting in a brea1down voltage!
#he properties of capacitors in a circ.it ma+ determine the resonant fre.enc+ and .alit+ factor
of a resonant circ.it% power dissipation and operating fre.enc+ in a digital logic circ.it% energ+
capacit+ in a high*power s+stem% and man+ other important aspects!
' capacitor (formerl+ 1nown as condenser$ is a device for storing electric charge! #he
forms of practical capacitors var+ widel+% b.t all contain at least two cond.ctors separated b+ a
non*cond.ctor! )apacitors .sed as parts of electrical s+stems% for eCample% consist of metal foils
separated b+ a la+er of ins.lating film!
)apacitors are widel+ .sed in electronic circ.its for bloc1ing direct c.rrent while
allowing alternating c.rrent to pass% in filter networ1s% for smoothing the o.tp.t of power
s.pplies% in the resonant circ.its that t.ne radios to partic.lar fre.encies and for man+ other
p.rposes!
' capacitor is a passive electronic component consisting of a pair of cond.ctors separated
b+ a dielectric (ins.lator$! When there is a potential difference (voltage$ across the cond.ctors% a
static electric field develops in the dielectric that stores energ+ and prod.ces a mechanical force36
http://en.wikipedia.org/wiki/Direct_currenthttp://en.wikipedia.org/wiki/Alternating_currenthttp://en.wikipedia.org/wiki/Alternating_currenthttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/LC_circuithttp://en.wikipedia.org/wiki/Frequencyhttp://en.wikipedia.org/wiki/Frequencyhttp://en.wikipedia.org/wiki/Passivity_(engineering)http://en.wikipedia.org/wiki/Electronic_componenthttp://en.wikipedia.org/wiki/Electrical_conductorhttp://en.wikipedia.org/wiki/Dielectrichttp://en.wikipedia.org/wiki/Potential_differencehttp://en.wikipedia.org/wiki/Electric_fieldhttp://en.wikipedia.org/wiki/Energyhttp://en.wikipedia.org/wiki/Direct_currenthttp://en.wikipedia.org/wiki/Alternating_currenthttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/Power_supplyhttp://en.wikipedia.org/wiki/LC_circuithttp://en.wikipedia.org/wiki/Frequencyhttp://en.wikipedia.org/wiki/Passivity_(engineering)http://en.wikipedia.org/wiki/Electronic_componenthttp://en.wikipedia.org/wiki/Electrical_conductorhttp://en.wikipedia.org/wiki/Dielectrichttp://en.wikipedia.org/wiki/Potential_differencehttp://en.wikipedia.org/wiki/Electric_fieldhttp://en.wikipedia.org/wiki/Energy
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
48/88
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
49/88
' capacitor consists of two cond.ctors separated b+ a non*cond.ctive region! #he non*
cond.ctive region is called the dielectric or sometimes the dielectric medi.m! In simpler terms%
the dielectric is 3.st an electrical ins.lator ! "Camples of dielectric medi.ms are glass% air% paper%
vac..m% and even a semicond.ctor depletion region chemicall+ identical to the cond.ctors! '
capacitor is ass.med to be self*contained and isolated% with no net electric charge and no
infl.ence from an+ eCternal electric field! #he cond.ctors th.s hold e.al and opposite charges
on their facing s.rfaces% and the dielectric develops an electric field! In 0I .nits% a capacitance of
one farad means that one co.lomb of charge on each cond.ctor ca.ses a voltage of one volt
across the device!
#he capacitor is a reasonabl+ general model for electric fields within electric circ.its! 'n ideal
capacitor is wholl+ characterized b+ a constant capacitance )% defined as the ratio of charge \on each cond.ctor to the voltage between themL
0ometimes charge b.ild*.p affects the capacitor mechanicall+% ca.sing its capacitance to var+! In
this case% capacitance is defined in terms of incremental changesL
Ener%y stora%e
Wor1 m.st be done b+ an eCternal infl.ence to QmoveQ charge between the cond.ctors in a
capacitor! When the eCternal infl.ence is removed the charge separation persists in the electric
field and energ+ is stored to be released when the charge is allowed to ret.rn to its e.ilibri.m
position! #he wor1 done in establishing the electric field% and hence the amo.nt of energ+ stored%
is given b+L
37
http://en.wikipedia.org/wiki/Electrical_conductorhttp://en.wikipedia.org/wiki/Dielectric_mediumhttp://en.wikipedia.org/wiki/Insulator_(electrical)http://en.wikipedia.org/wiki/Vacuumhttp://en.wikipedia.org/wiki/Semiconductorhttp://en.wikipedia.org/wiki/Depletion_regionhttp://en.wikipedia.org/wiki/Depletion_regionhttp://en.wikipedia.org/wiki/Electric_chargehttp://en.wikipedia.org/wiki/SIhttp://en.wikipedia.org/wiki/SIhttp://en.wikipedia.org/wiki/Faradhttp://en.wikipedia.org/wiki/Coulombhttp://en.wikipedia.org/wiki/Volthttp://en.wikipedia.org/wiki/Work_(thermodynamics)http://en.wikipedia.org/wiki/Equilibriumhttp://en.wikipedia.org/wiki/Electrical_conductorhttp://en.wikipedia.org/wiki/Dielectric_mediumhttp://en.wikipedia.org/wiki/Insulator_(electrical)http://en.wikipedia.org/wiki/Vacuumhttp://en.wikipedia.org/wiki/Semiconductorhttp://en.wikipedia.org/wiki/Depletion_regionhttp://en.wikipedia.org/wiki/Electric_chargehttp://en.wikipedia.org/wiki/SIhttp://en.wikipedia.org/wiki/Faradhttp://en.wikipedia.org/wiki/Coulombhttp://en.wikipedia.org/wiki/Volthttp://en.wikipedia.org/wiki/Work_(thermodynamics)http://en.wikipedia.org/wiki/Equilibrium
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
50/88
Current-2olta%e relation
#he c.rrent i(t$ thro.gh an+ component in an electric circ.it is defined as the rate of flow of a
charge (t$ passing thro.gh it% b.t act.al charges% electrons% cannot pass thro.gh the dielectric
la+er of a capacitor% rather an electron acc.m.lates on the negative plate for each one that leaves
the positive plate% res.lting in an electron depletion and conse.ent positive charge on one
electrode that is e.al and opposite to the acc.m.lated negative charge on the other! #h.s the
charge on the electrodes is e.al to the integral of the c.rrent as well as proportional to the
voltage as disc.ssed above! 's with an+ antiderivative% a constant of integration is added to
represent the initial voltage v (tB$! #his is the integral form of the capacitor e.ation%
!
#a1ing the derivative of this% and m.ltipl+ing b+ )% +ields the derivative form%
!
#he d.al of the capacitor is the ind.ctor % which stores energ+ in the magnetic field rather than the
electric field! Its c.rrent*voltage relation is obtained b+ eCchanging c.rrent and voltage in the
capacitor e.ations and replacing ) with the ind.ctance ;!
8.66 - R4), RE",ER & T"S
,adio*fre.enc+ identification (,FID$ is the wireless .se of electromagnetic fields to transfer
data% for the p.rposes of a.tomaticall+ identif+ing and trac1ing tags attached to ob3ects! #he tags
contain electronicall+ stored information! 0ome tags are powered b+ electromagnetic ind.ction
from magnetic fields prod.ced near the reader! 0ome t+pes collect energ+ from the interrogating
radio waves and act as a passive transponder! Other t+pes have a local power so.rce s.ch as a
batter+ and ma+ operate at h.ndreds of meters from the reader! 7nli1e a barcode% the tag does
48
http://en.wikipedia.org/wiki/Integralhttp://en.wikipedia.org/wiki/Antiderivativehttp://en.wikipedia.org/wiki/Constant_of_integrationhttp://en.wikipedia.org/wiki/Constant_of_integrationhttp://en.wikipedia.org/wiki/Duality_(electrical_circuits)http://en.wikipedia.org/wiki/Duality_(electrical_circuits)http://en.wikipedia.org/wiki/Inductorhttp://en.wikipedia.org/wiki/Magnetic_fieldhttp://en.wikipedia.org/wiki/Integralhttp://en.wikipedia.org/wiki/Antiderivativehttp://en.wikipedia.org/wiki/Constant_of_integrationhttp://en.wikipedia.org/wiki/Duality_(electrical_circuits)http://en.wikipedia.org/wiki/Inductorhttp://en.wikipedia.org/wiki/Magnetic_field
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
51/88
not necessaril+ need to be within line of sight of the reader and ma+ be embedded in the trac1ed
ob3ect! ,FID is one method for '.tomatic Identification and Data )apt.re ('ID)$!
'n ,FID readerVs f.nction is to interrogate ,FID tags! #he means of interrogation is wireless
and beca.se the distance is relativel+ short line of sight between the reader and tags is not
necessar+! ' reader contains an ,F mod.le% which acts as both a transmitter and receiver of radio
fre.enc+ signals! #he transmitter consists of an oscillator to create the carrier fre.enc+ a
mod.lator to impinge data commands .pon this carrier signal and an amplifier to boost the signal
eno.gh to awa1en the tag! #he receiver has a demod.lator to eCtract the ret.rned data and also
contains an amplifier to strengthen the signal for processing! ' microprocessor forms the control
.nit% which emplo+s an operating s+stem and memor+ to filter and store the data! #he data is now
read+ to be sent to the networ1!
41
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
52/88
8.69 - REL"!
' relay is an electricall+ operated switch! -an+ rela+s .se an electromagnet to
mechanicall+ operate a switch% b.t other operating principles are also .sed% s.ch as solid*state
rela+s! ,ela+s are .sed where it is necessar+ to control a circ.it b+ a low*power signal (with
complete electrical isolation between control and controlled circ.its$% or where several circ.its
m.st be controlled b+ one signal! #he first rela+s were .sed in long distance telegraph circ.its as
amplifiersL the+ repeated the signal coming in from one circ.it and re*transmitted it on another
circ.it! ,ela+s were .sed eCtensivel+ in telephone eCchanges and earl+ comp.ters to perform
logical operations
8.6= - LC, 679
4
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
53/88
;cd is a displa+ device .sed to displa+ alphan.meric characters! 5>]9 ;)D mod.le is a
ver+ common t+pe of ;)D mod.le that is .sed in @B=5 based embedded pro3ects! It consists of
5> rows and 9 col.mns of =]? or =]@ ;)D dot matrices! #he mod.le were are tal1ing abo.t here
is t+pe n.mber &HD5>9' which is a ver+ pop.lar one! It is available in a 5> pin pac1age with
bac1 light% contrast ad3.stment f.nction and each dot matriC has =]@ dot resol.tion! #he pin
n.mbers% their name and corresponding f.nctions are shown in the table below!
?. SO4TD"RE REGU)RE#ETS
?.6 - )TRO,UCT)O TO @E)L #)CRO +)S)O /),E1
8eil an ',- )ompan+ ma1es ) compilers% macro assemblers% real*time 1ernels% deb.ggers%
sim.lators% integrated environments% eval.ation boards% and em.lators for ',-?6',-A6)orteC*
-:% K)5>C6)5>C60#5B% 9=5% and @B=5 -)7 families!
8eil development tools for the @B=5 -icrocontroller 'rchitect.re s.pport ever+ level of
software developer from the professional applications engineer to the st.dent 3.st learning abo.t
embedded software development! When starting a new pro3ect% simpl+ select the microcontroller
+o. .se from the Device Database and the ^ision ID" sets all compiler% assembler% lin1er% and
memor+ options for +o.!
42
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
54/88
8eil is a cross compiler! 0o first we have to .nderstand the concept of compilers and
cross compilers! 'fter then we shall learn how to wor1 with 1eil!
?.9 - COCEPT O4 CO#P)LER
)ompilers are programs .sed to convert a High ;evel ;ang.age to ob3ect code! Des1top
compilers prod.ce an o.tp.t ob3ect code for the .nderl+ing microprocessor% b.t not for other
microprocessors! I!" the programs written in one of the H;; li1e _)2 will compile the code to
r.n on the s+stem for a partic.lar processor li1e C@> (.nderl+ing microprocessor in the
comp.ter$! For eCample compilers for Dos platform is different from the )ompilers for 7niC
platform 0o if one wants to define a compiler then compiler is a program that translates so.rce
code into ob3ect code!
#he compiler derives its name from the wa+ it wor1s% loo1ing at the entire piece of
so.rce code and collecting and reorganizing the instr.ction! 0ee there is a bit little difference
between compiler and an interpreter! Interpreter 3.st interprets whole program at a time while
compiler anal+ses and eCec.te each line of so.rce code in s.ccession% witho.t loo1ing at the
entire program!
#he advantage of interpreters is that the+ can eCec.te a program immediatel+! 0econdl+
programs prod.ced b+ compilers r.n m.ch faster than the same programs eCec.ted b+ an
interpreter! However compilers re.ire some time before an eCec.table program emerges! Now
as compilers translate so.rce code into ob3ect code% which is .ni.e for each t+pe of comp.ter%
man+ compilers are available for the same lang.age!
?.= - COCEPT O4 CROSS CO#P)LER
43
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
55/88
' cross compiler is similar to the compilers b.t we write a program for the target processor (li1e
@B=5 and its derivatives$ on the host processors (li1e comp.ter of C@>$! It means being in one
environment +o. are writing a code for another environment is called cross development! 'nd
the compiler .sed for cross development is called cross compiler! 0o the definition of cross
compiler is a compiler that r.ns on one comp.ter b.t prod.ces ob3ect code for a different t+pe of
comp.ter!
?.8 - @E)L C CROSS CO#P)LER
8eil is a 4erman based 0oftware development compan+! It provides several development
tools li1e
M ID" (Integrated Development environment$
M Pro3ect -anager
M 0im.lator
M Deb.gger
M ) )ross )ompiler% )ross 'ssembler% ;ocator6;in1er
#he 8eil ',- tool 1it incl.des three main tools% assembler% compiler and lin1er! 'n
assembler is .sed to assemble the ',- assembl+ program! ' compiler is .sed to compile the )
so.rce code into an ob3ect file! ' lin1er is .sed to create an absol.te ob3ect mod.le s.itable for
o.r in*circ.it em.lator!
?.? - 0uilin% an "pplication in M+ision8
#o b.ild (compile% assemble% and lin1$ an application in ^ision9% +o. m.stL
44
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
56/88
5 0elect Pro3ect *(foreCample%5>>`"K'-P;"0`H";;O`H";;O!7 0elect Pro3ect * Options and set the tool options! Note when +o. select the target device
from the Device Database all special options are set a.tomaticall+! o. t+picall+ onl+
need to config.re the memor+ map of +o.r target hardware! Defa.lt memor+ model
settings are optimal for most applications!
? 0elect Pro3ect * ,eb.ild all target files or /.ild target!
?.> - ,e*u%%in% an "pplication in M+ision9
#o deb.g an application created .sing ^ision9% +o. m.stL
5 0elect Deb.g * 0tart60top Deb.g 0ession!
9 7se the 0tep toolbar b.ttons to single*step thro.gh +o.r program! o. ma+ enter 4% main
in the O.tp.t Window to eCec.te to the main ) f.nction!
: Open the 0erial Window .sing the 0erial G5 b.tton on the toolbar!
Deb.g +o.r program .sing standard options li1e 0tep% 4o% /rea1% and so on!
?. - Startin% M+ision8 an Creatin% a Project
^ision< is a standard Windows application and started b+ clic1ing on the program icon!
#o create a new pro3ect file select from the ^ision9 men. Pro3ect New Pro3ect! #his opens
45
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
57/88
a standard Windows dialog that as1s +o. for the new pro3ect file name! We s.ggest that +o. .se a
separate folder for each pro3ect! o. can simpl+ .se the icon )reate New Folder in this dialog to
get a new empt+ folder! #hen select this folder and enter the file name for the new pro3ect% i!e!
Pro3ect5! ^ision9 creates a new pro3ect file with the name P,O&")#5!79 which contains a
defa.lt target and file gro.p name! o. can see these names in the Pro3ect!
?.; - Dino' A 4iles.
Now .se from the men. Pro3ect 0elect Device for #arget and select a )P7 for +o.r
pro3ect! #he 0elect Device dialog boC shows the ^ision9 device data base! &.st select the
microcontroller +o. .se! We are .sing for o.r eCamples the Philips @B)=5,D )P7! #his
selection sets necessar+ tool Options for the @B)=5,D device and simplifies in this wa+ the
tool )onfig.ration!
=!5B * 0uilin% Projects an Creatin% a HEK 4iles
#+pical% the tool settings .nder Options #arget are all +o. need to start a new
application! o. ma+ translate all so.rce files and line the application with a clic1 on the /.ild
#arget toolbar icon! When +o. b.ild an application with s+ntaC errors% ^ision9 will displa+
errors and warning messages in the O.tp.t Window /.ild page! ' do.ble clic1 on a message
line opens the so.rce file on the correct location in a ^ision9 editor window! Once +o. haves.ccessf.ll+ generated +o.r application +o. can start deb.gging!
'fter +o. have tested +o.r application% it is re.ired to create an Intel H"K file to
download the software into an "P,O- programmer or sim.lator! ^ision9 creates H"K files
with each b.ild process when )reate H"K files .nder Options for #arget O.tp.t is enabled!
o. ma+ start +o.r P,O- programming .tilit+ after the ma1e process when +o. specif+ the
program .nder the option ,.n 7ser Program G5!
?.66 - CPU Siulation
^ision9 sim.lates .p to 5> -b+tes of memor+ from which areas can be mapped for
read% write% or code eCec.tion access! #he ^ision9 sim.lator traps
46
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
58/88
and reports illegal memor+ accesses! In addition to memor+ mapping% the sim.lator also provides
s.pport for the integrated peripherals of the vario.s @B=5 derivatives! #he on*chip peripherals of
the )P7 +o. have selected are config.red from the Device!
?.69 - ,ata*ase selection
o. have made when +o. create +o.r pro3ect target! ,efer to page =@ for more
Information abo.t selecting a device! o. ma+ select and displa+ the on*chip peripheral
components .sing the Deb.g men.! o. can also change the aspects of each peripheral .sing the
controls in the dialog boCes!
?.6= - Start ,e*u%%in%
o. start the deb.g mode of ^ision9 with the Deb.g 0tart60top Deb.g
0ession )ommand! Depending on the Options for #arget Deb.g )onfig.ration% ^ision9 will
load the application program and r.n the start.p code ^ision9 saves the editor screen la+o.t
and restores the screen la+o.t of the last deb.g session! If the program eCec.tion stops% ^ision9
opens an editor window with the so.rce teCt or shows )P7 instr.ctions in the disassembl+
window! #he neCt eCec.table statement is mar1ed with a +ellow arrow! D.ring deb.gging% most
editor feat.res are still available!
For eCample% +o. can .se the find command or correct program errors! Program so.rce
teCt of +o.r application is shown in the same windows! #he ^ision9 deb.g mode differs from
the edit mode in the following aspectsL
J #he Deb.g -en. and Deb.g )ommandsE described on page 9@ are available! #he additional
deb.g windows are disc.ssed in the following!
J #he pro3ect str.ct.re or tool parameters cannot be modified! 'll b.ild commands are disabled!
?.68 - ,isasse*ly Dino'
#he Disassembl+ window shows +o.r target program as miCed so.rce and assembl+
program or 3.st assembl+ code! ' trace histor+ of previo.sl+ eCec.ted instr.ctions ma+ be
4&
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
59/88
displa+ed with Deb.g iew #race ,ecords! #o enable the trace histor+% set Deb.g
"nable6Disable #race ,ecording!
If +o. select the Disassembl+ Window as the active window all program step commands
wor1 on )P7 instr.ction level rather than program so.rce lines! o. can select a teCt line and set
or modif+ code brea1points .sing toolbar b.ttons or the conteCt men. commands!
o. ma+ .se the dialog Deb.g Inline 'ssembl+ to modif+ the )P7 instr.ctions! #hat
allows +o. to correct mista1es or to ma1e temporar+ changes to the target program +o. are
deb.gging! N.mero.s eCample programs are incl.ded to help +o. get started with the most
pop.lar embedded @B=5 devices!
#he 8eil ^ision Deb.gger acc.ratel+ sim.lates on*chip peripherals (I)% )'N% 7',#%
0PI% Interr.pts% I6O Ports% '6D )onverter% D6' )onverter% and PW- -od.les$ of +o.r @B=5
device! 0im.lation helps +o. .nderstand hardware config.rations and avoids time wasted on
set.p problems! 'dditionall+% with sim.lation% +o. can write and test applications before target
hardware is available!
=!5= * E#0E,,E, C 7se of embedded processors in passenger cars% mobile phones% medical e.ipment%
aerospace s+stems and defense s+stems is widespread% and even ever+da+ domestic appliances
s.ch as dish washers% televisions% washing machines and video recorders now incl.de at least one
s.ch device!
/eca.se most embedded pro3ects have severe cost constraints% the+ tend to .se low*cost
processors li1e the @B=5 famil+ of devices considered in this boo1! #hese pop.lar chips have
ver+ limited reso.rces available most s.ch devices have aro.nd 9=> b+tes (not megab+tes$ of
,'-% and the available processor power is aro.nd 5BBB times less than that of a des1top
processor! 's a res.lt% developing embedded software presents significant new challenges% even
for eCperienced des1top programmers! If +o. have some programming eCperience * in )% )
47
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
60/88
or &ava * then this boo1 and its accompan+ing )D will help ma1e +o.r move to the embedded
world as .ic1 and painless as possible!
7. SCHE#"T)C ,)"R"#
58
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
61/88
7.6 - SCHE#"T)C EKPL""T)O
PODER SUPPL!
#he circ.it .ses standard power s.ppl+ comprising of a step*down transformer from
9:Bto 59 and < diodes forming a bridge rectifier that delivers p.lsating dc which is then
filtered b+ an electrol+tic capacitor of abo.t
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
62/88
#he reg.lated = D) is f.rther filtered b+ a small electrol+tic capacitor of 5B^F for an+
noise so generated b+ the circ.it! One ;"D is connected of this = point in series with a c.rrent
limiting resistor of ::B to the gro.nd i!e!% negative voltage to indicate = power s.ppl+
availabilit+! #he .nreg.lated 59 point is .sed for other applications as and when re.ired!
ST","R, COECT)OS TO
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
63/88
this the program eCec.tion co.ld have ta1en place arbitraril+ an+where from the program c+cle!
' p.shb.tton switch is connected across the capacitor so that at an+ given time as desired it can
be pressed s.ch that it discharges the capacitor and while released the capacitor starts charging
again and then pin n.mber A goes to high and then bac1 to low% to enable the program eCec.tion
from the beginning! #his operation of high to low of the reset pin ta1es place in fraction of a
second as decided b+ the time constant , and )!
For eCampleL ' 5B^F capacitor and a 5B1 resistor wo.ld render a 5BBms time to pin n.mber A
from logic high to low% there after the pin n.mber A remains low!
Eternal "ccess/E"1:
Pin no :5 of
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
64/88
0R)E4 ,ESCR)PT)O O4 REL"! SD)TCH
Fig! 5 )nter3acin% REL"! to #icrocontrollerHere in above circ.it% the transistor is .sed to act li1e switch to drive the rela+! Now when the
logic 5 is applied at the inp.t of the base of transistor% the transistor gets its biasing and will start
acting li1e a closed switch! 's a res.lt the c.rrent will start flowing thro.gh the coil of the rela+!
#he coil gets magnetized and the movable iron plate gets attracted to the coil magnetic field and
hence a connection is established at the o.tp.t pins of the rela+!
7.9 - OPER"T)O EKPL""T)O
#icrocontroller an connections:
53
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
65/88
#he microcontroller .sed is '#@A0=9! #he
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
66/88
When the petrol for a given amo.nt is filled% the rela+ will get t.rn off and so is the
p.mp! 'fter that microcontroller will show the remaining balance of the .ser! 'nd the whole
process is started again!
>. 0)LL O4 #"TER)"LS
0ill O3 #aterial-#oel o.=7
Coponent ae Guantity ChecIe
Resistors 5B8 <
58 = 5B8 0IP resistor 9
Capacitors 5BB.f6>:v 95B.F6>: 9::pF )eramic 9
55
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
67/88
)nte%rate Circuits ?@B= 5'#@A0=9 5
)C 0ases
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
68/88
Gdefine lcd PB
sbit ledJrRP5j>9AQ 666card n.mber
idata char .ser9k55RQBBBBA@A9A@Q 666card n.mber
.nsigned int blnck=R=BBB%:=BB%B%B%B
char cnvrtedk>
bit a
void serial(void$ interr.pt <
,IRB
if((55 storekBRRV0V$ (0/7FRRVV RRB$$
storekR0/7F
if(RR55$
RB
aR5
void main($
.nsigned int i%ff%3
.nsigned long pRB%ccRB%iiiRB
char hhh
#-ODRBK9B 666666666666timer 5 mode 966 timer B mode 566666666666
5&
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
69/88
0)ONRBK=B
I"RBKAB
#H5R*:
#,5R5
I#BR5
lcdJinitialize($
while(5$
I"RBKA5
ledJrRrela+RB
ledJgR5
lcdJstring(Q '.tomatic 0martQ%Q Petrol P.mp Q$
aRB
while(5$
if(aRR5$
while(5$
aRB
RB
lcdJstring(.ser($%Q /alL ,s! Q$
cmd(BCc>$
inttostring(blnck.sr$
for(iR9i>i$
dataa(cnvrtedki$
dela+(9BBB$
if(.srRR
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
70/88
else if(iRRB$
cmd(BC@A$
inttostring(iii$
for(iR9i>i$
dataa(cnvrtedki$cmd(BCc@$
inttostring(cc$
for(iRBi>i$
if(iRR:$
cmd(BCcc$
dataa(cnvrtedki$
68
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
71/88
else
3rela+RB
ledJgR5
rela+RB
dela+(9=BB$
while(swRRB$
ledJrRB
lcdJstring(Q #han1 o. Q%Q /alL ,s! Q$
cmd(BCc>$
inttostring(blnck.sr$
for(iR9i>i$
dataa(cnvrtedki$
dela+(9=BB$
inttostring(B$
pRhhhRccRB brea1
else
lcdJstring(Q '.tomatic 0martQ%Q Petrol P.mp Q$
void inttostring(.nsigned long dsp$
int i
for(iR>iBi**$
cnvrtedki*5R(((dspU5B$
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
72/88
if(storekhhRR.ser5khh$
ll
else
llRB
if(storekhhRR.ser9khh$
mm
else
mmRB
if(llA$
.srRBret.rn Q 7ser 5 Q
else if(mmA$
.srR5ret.rn Q 7ser 9 Q
else
.srR
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
73/88
66rwR5
cmd(BC:@$
cmd(BCBc$
cmd(BCB5$
void lcdJstring(.nsigned char stringval%.nsigned char stringval9$
.nsigned int dRB
cmd(BC@B$
while(stringvalkdRB$
dataa(stringvalkd$
d
cmd(BCcB$
dRB
while(stringval9kdRB$
dataa(stringval9kd$
d
char 1e+($
while(5$
matriCRBCe?
if(matriCRRBCe:$while(matriCRRBCe:$ret.rn 5
if(matriCRRBCe=$while(matriCRRBCe=$ret.rn 9
if(matriCRRBCe>$while(matriCRRBCe>$ret.rn :
matriCRBCd?
if(matriCRRBCd:$while(matriCRRBCd:$ret.rn $while(matriCRRBCd>$ret.rn >
matriCRBCb?
if(matriCRRBCb:$while(matriCRRBCb:$ret.rn ?
if(matriCRRBCb=$while(matriCRRBCb=$ret.rn @
if(matriCRRBCb>$while(matriCRRBCb>$ret.rn A
matriCRBC??if(matriCRRBC?:$while(matriCRRBC?:$ret.rn BCfa
if(matriCRRBC?=$while(matriCRRBC?=$ret.rn B
if(matriCRRBC?>$while(matriCRRBC?>$ret.rn BCf:
62
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
74/88
.9. PROR"# 4LOD
#he code at the at@As=9 microcontroller can be s.mmarized as follows b+ the pse.do code! 'll
code is written .sing 8eil .vision
5! Idle mode! Wait for a serial interr.pt or hardware interr.pt!
9! If serial interr.pt is realized it means a card is scanned b+ ,FID reader!
:! Wait for the whole card n.mber is to be received one b+ one! 0ave it in some random
memor+!
respective .ser details (balance% name etc!$!
=! 's1 for the amo.nt for the petrol!
>! ,ead .ser inp.t b+ 1e+pad matriC!
?! If amo.nt entered is less than =B or more than =BBB than show invalid amo.ntE!
@! 'gain as1 for amo.nt! If valid amo.nt entered% show the petrol .antit+ for the amo.nt
entered!
A! If cancel b.tton pressed! 4o to main else if o1 b.tton pressed switch on the control to
filling machine!
5B! When the filing switch is pressed switch the motor p.mp on and ded.ct the amo.nt as the
63
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
75/88
petrol is filling!
55! 'fter 'll is done show the available balance!
59! ,et.rn to start position!
.=. CO#P)LER
6. )lic1 on the 8eil ision Icon on Des1top
9. #he following fig will appear
=. )lic1 on the Pro3ect men. from the title bar
64
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
76/88
8. #hen )lic1 on New Pro3ect
?. 0ave the Pro3ect b+ t+ping s.itable pro3ect name with no eCtension in . r own foldersited in either )L` or DL`
7. #hen )lic1 on 0ave b.tton above!
>. 0elect the component for . r pro3ect! i!e! 'tmel
65
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
77/88
. )lic1 on the 0+mbol beside of 'tmel
;. 0elect '#@A)=5 as shown below
6
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
78/88
69. #hen )lic1 either "0 or NOmostl+ NOE!
6=. Now +o.r pro3ect is read+ to 70"!
68. Now do.ble clic1 on the #arget5% +o. wo.ld get another option 0o.rce gro.p 5E as
shown in neCt page!
6?. )lic1 on the file option from men. bar and select newE!
6&
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
79/88
67. #he neCt screen will be as shown in neCt page% and 3.st maCimize it b+ do.ble
clic1ing on its bl.e boarder!
6>. Now start writing program in either in "-/"DD"D )E or '0-E!
6. For a program written in 'ssembl+% then save it with eCtension ! asmE and for
"-/"DD"D )E based program save it with eCtension !)E
67
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
80/88
6;. Now right clic1 on 0o.rce gro.p 5 and clic1 on 'dd files to 4ro.p 0o.rceE!
9
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
81/88
96. Now select as per +o.r file eCtension given while saving the file!
99. )lic1 onl+ one time on option ",,E!
9=. Now Press f.nction 1e+ F? to compile! 'n+ error will appear if so happen!
98. If the file contains no error% then press )ontrolF= sim.ltaneo.sl+!
9?. #he new window is as follows
&1
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
82/88
97. #hen )lic1 O8E!
9>. Now clic1 on the Peripherals from men. bar% and chec1 +o.r re.ired port as shown
in fig below!
9. Drag the port a side and clic1 in the program file!
&
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
83/88
9;. Now 1eep Pressing f.nction 1e+ F55E slowl+ and observe!
=
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
84/88
Devices that can be .sed to perform contin.it+ tests incl.de m.lti meters which meas.re
c.rrent and specialized contin.it+ testers which are cheaper% more basic devices% generall+ with a
simple light b.lb that lights .p when c.rrent flows!
'n important application is the contin.it+ test of a b.ndle of wires so as to find the two
ends belonging to a partic.lar one of these wires there will be a negligible resistance between
the QrightQ ends% and onl+ between the QrightQ ends!
#his test is the performed 3.st after the hardware soldering and config.ration has beencompleted! #his test aims at finding an+ electrical open paths in the circ.it after the soldering!
-an+ a times% the electrical contin.it+ in the circ.it is lost d.e to improper soldering% wrong and
ro.gh handling of the P)/% improper .sage of the soldering iron% component fail.res and
presence of b.gs in the circ.it diagram! We .se a m.lti meter to perform this test! We 1eep the
m.lti meter in b.zzer mode and connect the gro.nd terminal of the m.lti meter to the gro.nd!
We connect both the terminals across the path that needs to be chec1ed! If there is contin.ation
then +o. will hear the beep so.nd!
;.9. PODER O TEST:
#his test is performed to chec1 whether the voltage at different terminals is according to
the re.irement or not! We ta1e a m.lti meter and p.t it in voltage mode! ,emember that this testis performed witho.t microcontroller! Firstl+% we chec1 the o.tp.t of the transformer% whether we
get the re.ired 59 v ') voltage!
#hen we appl+ this voltage to the power s.ppl+ circ.it! Note that we do this test witho.t
microcontroller beca.se if there is an+ eCcessive voltage% this ma+ lead to damaging the
&3
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
85/88
controller! We chec1 for the inp.t to the voltage reg.lator i!e!% are we getting an inp.t of 59v and
an o.tp.t of =v! #his =v o.tp.t is given to the microcontrollers2
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
86/88
that it can store! We have .sed an ,FID identification s+stem for the .ser a.thorization! /.t for
practical considerations we will have to .se a more sec.re identification s+stem!
COCLUS)O
#his pro3ect of "UTO#"T)C PETROL PU#P S!TE# is practical% .ser friendl+ and
a good idea to red.ce the fra.d cases at petrol p.mps! #he people have to s.ffer from the
problems at a petrol filling station li1e no service% fra.d or cheating and ,is1 of ,obber+% #his
pro3ect is the complete sol.tion to all these problems! 'nd as the people are going techie% there
will not be an+ problem in adopting this technolog+!
#he pro3ect can be made more f.nctional b+ adding some sec.rit+ feat.res li1e fire
sensor% smo1e sensor and other safet+ e.ipment2s!
&5
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
87/88
0)0L)OR"PH!
TEKT 0OO@S RE4ERE,:
5! #he @B=5 -icrocontroller and "mbedded s+stemsE b+ -.hammad 'li -azidi and &anice
4illispie -azidi % Pearson "d.cation!
9! '#-"; @A0=9 Data 0heets!
0)0L)OR"PH!
&6
-
8/18/2019 Major Project Report on Automatic Petrol Pump System
88/88
• www!atmel!com
• www!be+ondlogic!org
• www!wi1ipedia!org
• www!howst.ffwor1s!com
• www!alldatasheets!com