0% found this document useful (0 votes)
10 views8 pages

Two Wheel Deal: Design & Operation Guide

The document describes the hardware design and theory of operation for an autonomous two-wheeled vehicle called The Two Wheel Deal. It has high-power batteries and motor controllers to power brushless DC motors, and sensors including accelerometers, gyroscopes, and infrared detection to provide input to an ATmega32 microcontroller. The microcontroller computes torque demands and interfaces to components including motor controllers using PWM, sensors using analog inputs, and a LCD for the user interface. Optoisolators separate the motor controllers from the microcontroller circuit for safety.

Uploaded by

McQuack Ávila
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views8 pages

Two Wheel Deal: Design & Operation Guide

The document describes the hardware design and theory of operation for an autonomous two-wheeled vehicle called The Two Wheel Deal. It has high-power batteries and motor controllers to power brushless DC motors, and sensors including accelerometers, gyroscopes, and infrared detection to provide input to an ATmega32 microcontroller. The microcontroller computes torque demands and interfaces to components including motor controllers using PWM, sensors using analog inputs, and a LCD for the user interface. Optoisolators separate the motor controllers from the microcontroller circuit for safety.

Uploaded by

McQuack Ávila
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd

ECE 477 Digital Systems Senior Design Project Spring 2008

Homework 5: Theory of Operation and Hardware Design Narrative


Due: Friday, February 15, at NOON
Team Code Name: The Two Wheel Deal Group No !"
Team #em$er Completing This Homework: Greg %akins
e&mail 'ddress of Team #em$er: geakins ( purdueedu
NOTE: This is the second in a series of four design component homeor! assignments"
each of hich is to #e comp$eted #% one team mem#er& The comp$eted homeor! i$$ count
for 20' of the indi(idua$ component of the team mem#er)s grade& The #od% of the report
shou$d #e *+, pages" not inc$uding this co(er page" references" attachments or appendices&
%valuation:
)CO*% -ESC./0T/ON
10
Excellent among the best papers submitted for this assignment. Very few
corrections needed for version submitted in Final Report.
2
Very good all reuirements aptly met. !inor additions"corrections needed for
version submitted in Final Report.
8
Good all reuirements considered and addressed. Several noteworthy
additions"corrections needed for version submitted in Final Report.
7
Average all reuirements basically met# but some revisions in content should be
made for the version submitted in the Final Report.
3
Marginal all reuirements met at a nominal level. Significant revisions in
content should be made for the version submitted in the Final Report.
4
Belo t!e "a##ing t!re#!old major revisions reuired to meet report
reuirements at a nominal level. $evi#e and re#ub%it&
4 Resubmissions are due within one ee' of the date of return# and will be awarded a score of
$%& provided all report reuirements have been met at a nominal level.
Comments:
+0+
ECE 477 Digital Systems Senior Design Project Spring 2008
!+ ,ntrodu-tion
-ue to its duties as an upright #a$ancing transportation de(ice" The To 5hee$ -ea$
re6uires a uni6ue mi7ture of high sensiti(it% and high poer circuitr% in order to proper$%
#a$ance and transport a person& On the sensor side" it needs a precise sensor and microcontro$$er
circuit to fine tune the demanded motor tor6ue #ased on readings from mu$tip$e sensors and user
inputs& On the poer side" this (ehic$e needs high current motor contro$$ers to #ridge the gap
#eteen the microcontro$$er and the poerfu$ -C motors on #oard" a$ong ith high capacit%
#atteries to supp$% the re6uired current&
"+ Theory of Operation
.ower )upply
8$$ of the poer for The To 5hee$ -ea$ comes from a pair of 129 sea$ed $ead acid
hee$ chair #atteries ired in series to pro(ide the circuit ith 249& The #atteries are used to
supp$% current primari$% to the motor contro$$ers" hich direct the current through the N0C+T74
motors& The 249 from the #atteries is stepped don to 129 using a $inear (o$tage regu$ator&
Though this is an inefficient means of regu$ating a $arge (o$tage difference" the simp$icit% of the
circuit and the resi$ience to (o$tage ripp$e caused #% the motor contro$$ers far outeigh the
additiona$ current consumption hich" hen compared to the current consumption of the motors"
is miniscu$e& The 129 from these regu$ators is used for poering the :ET dri(ers on each motor
contro$$er& The (o$tage is again stepped don from 129 to ,9 using a $inear (o$tage regu$ator to
ensure that the microcontro$$er and sensor circuit recei(e a sta#$e (o$tage& The constanc% of the
,9 $ine is critica$ for the proper interaction of the sensors and the microcontro$$er& :$uctuations
in the input (o$tage of the sensors i$$ resu$t in undesira#$e changes on the output of the sensors&
The microcontro$$er" sensors" 0;-s" ;C-" and (arious other support de(ices are poered #% the
,9 regu$ator& 8$$ components outside of the motor contro$$ers are ,9 de(ices to simp$if% the
poer supp$% circuit" as e$$ as e$iminate an% need for $e(e$ trans$ators or amp$ification
hardare&
#i-ro-ontroller
The 8Tmega*2 microcontro$$er interfaces to a$$ of the ma<or components of the (ehic$e&
/t runs off of an e7terna$ cr%sta$ osci$$ator at the microcontro$$er)s ma7imum c$oc! speed of 13
=>? to ma7imi?e the a(ai$a#$e computing poer& /t uses the 8T- modu$e to read an ana$og
+1+
ECE 477 Digital Systems Senior Design Project Spring 2008
signa$ from the acce$erometers" the g%roscopic angu$ar rate sensor" the steering <o%stic!" and the
#atter% $e(e$ meter& @ased on the incoming data" it computes the dut% c%c$e of to outgoing
05= signa$s that are used to command tor6ue from the motors& 8t the same time" the
microcontro$$er interfaces to an ;C- screen to gi(e the dri(er feed#ac! on the state of the
(ehic$e&
)ensors
8 dua$ a7is acce$erometer and a sing$e a7is angu$ar rate sensor are used to determine the
angu$ar position and angu$ar (e$ocit% of the (ehic$e a#out its dri(e a7is& @oth sensors ha(e
ana$og outputs that are fed direct$% to the microcontro$$er)s 8T- channe$s& @oth sensors ha(e
interna$ signa$ conditioning circuitr%" reducing or e$iminating the need for fi$tering circuitr%&
0h%sica$ orientation of each sensor is e7treme$% important for o#taining the correct information
on the (ehic$e)s mo(ements A1BA2B& To faci$itate proper mounting of the sensors ithout
resorting to e7traneous mounting of each sensor" the entire microcontro$$er and sensor 0C@ is
mounted perpendicu$ar to the ground a$ong the center$ine of the (ehic$e&
@atter% $e(e$ monitoring is performed #% using a simp$e high resistance (o$tage di(ider
connected direct$% to the #atter%& The 249 #atter% (o$tage is di(ided don to ,9 to a$$o the
8T- con(erters to read changes in the (o$tage of the #atter%& Cnoing the state of the #atter%)s
charge i$$ a$$o the contro$$er to compensate for a $o #atter% #% increasing the dut% c%c$e of
the 05= signa$ going to the motor contro$$ers" !eeping the (ehic$e)s performance constant o(er
the $ife of the #atter%&
8n infrared rider detection sitch in the hand$e#ar of the (ehic$e $ets the s%stem !no
hen the rider has dismounted Deither i$$ing$% or uni$$ing$%E& ;ogic in the softare a$gorithm
i$$ insert a de$a% #efore an% action is ta!en upon detecting a missing rider& This a$$os the rider
to temporari$% remo(e their hands from the hand$e#ars if need #e ithout the (ehic$e coming to
an undesired ha$t&
#otor Controller
Each motor contro$$er is contro$$ed using a 05= signa$ from the microcontro$$er running
at a fre6uenc% of appro7imate$% 2 !>?& Fsing this $o fre6uenc% signa$ can cause an audi#$e
hine from the motors" #ut it increases the poer hand$ing of the circuit #% reducing the $osses
generated #% sitching the :ETs& The 05= signa$ is not fed direct$% to the =OS:ETs" #ut
instead it is fed to a :ET dri(er that ta!es care of man% of the important detai$s of dri(ing an >+
+2+
ECE 477 Digital Systems Senior Design Project Spring 2008
#ridge" such as app$%ing the right (o$tages to the =OS:ET gates and inserting a s$ight de$a%
#efore sitching from forard and re(erse to pre(ent a circuit destro%ing shoot+through
situation&
The :ET contro$$er contro$s a simp$e =OS:ET >+#ridge& Each $eg of the #ridge ho$ds *
=OS:ETs rated at 1008 continuous$%& This gi(es each one of The To 5hee$ -ea$)s motor
contro$$ers a theoretica$ current capacit% of a#out *00 amps" though gi(en the passi(e coo$ing
s%stem" 1,08 is a more rea$istic (a$ue A*B&
E(en though the :ET dri(ers he$p pre(ent shoot+through #% inserting a s$ight de$a%
#efore changing directions A4B" specia$ circuitr% has #een added to the >+#ridges to compensate
for the $arge =OS:ETs used in this design& The $arge gate capacitances Don the order of a fe
G:E cause a si?a#$e de$a% in the turn+off time of each :ET" and if the opposing set of :ETs turn
on #efore the first set turns off" shoot through i$$ occur& .esistors ha(e #een added in series
ith the gate of each transistor to s$o don the turn on time" and a Schott!% diode ired in
para$$e$ ith the resistor aid in speeding up the turn off time of each :ET #% pu$$ing the charge
off of the transistor)s gate&
Each motor contro$$er re6uires that the incoming 05= signa$ #e sitched #eteen to
separate pins to sitch the motor contro$$er #eteen forard and re(erse& Since the
microcontro$$er on$% has enough 05= channe$s to supp$% 1 05= signa$ to each motor
contro$$er" additiona$ $ogic must #e added to a$$o for a sing$e 05= signa$ to command #oth
forard and re(erse& Though this $ogic can #e imp$emented using a fe discreet $ogic gates" a
sing$e 0;- is used to simp$if% this circuit and a$$o for future e7pansion&
The rapid sitching of high current inducti(e $oads ma!es the motor contro$$er an
e$ectrica$$% chaotic part of the circuit& To pro(ide a measure of safet% to the microcontro$$er and
$ogic circuits" the motor contro$$er circuits are separated from the microcontro$$er circuit #%
running each 05= signa$ through an optica$ iso$ator&
Human ,nterfa-e
8n ;C- screen is used to pro(ide the user ith (ehic$e information such as appro7imate
(ehic$e speed and #atter% $ife& The microcontro$$er interfaces to the ;C- screen direct$% using a
para$$e$ interface& Steering of the (ehic$e is imp$emented #% reading the (o$tage output from a
(aria#$e resistance <o%stic! circuit& This (a$ue is sent direct$% to an 8T- channe$ on the
microcontro$$er&
+*+
ECE 477 Digital Systems Senior Design Project Spring 2008
/+ Hardware Design Narrative
The 05= modu$e of the 8Tmega*2 is used to send a tor6ue demand to the motors& The
microcontro$$er has on$% to 13+#it 05= outputs" and #oth i$$ #e uti$i?ed& These outputs
correspond to pins OC18 and OC1@& Henera$ /IO pins 0-0 and 0-1 ha(e #een chosen to
contro$ the direction of the motors primari$% due to their c$ose pro7imit% to the 05= output
pins&
The 8T- modu$e is used e7tensi(e$% for reading the (a$ues coming from the sensors& 8$$ of
the sensors ha(e a 0+,9 output range" so the% can #e direct$% connected to the 8T- pins& The
dua$ a7is acce$erometer)s to outputs uses 8T- pins 081 and 082" the output of the angu$ar rate
sensor uses 08*" the 2&,9 reference (o$tage of the angu$ar rate sensor uses 084" the steering
<o%stic! uses 08," and the #atter% $e(e$ circuit is connected to 080&
The ;C- screen i$$ ta!e up the most /IO pins& 5hi$e the para$$e$ interface of the ;C-
cou$d #e using the S0/ and a shift register to sa(e microcontro$$er pins" a high num#er of free /IO
pins ma!e this an unnecessar% addition to the circuit& The ;C- screen re6uires 10 pins to
operate& The 8 data #its i$$ use pins 0C0+0C7& These pins are contro$$ed interna$$% #% a sing$e
data register& 0utting a$$ of the ;C- data pins together simp$ifies the softare a$gorithm for
riting data to the ;C-& The screen needs a register se$ect [Link] and a c$oc! signa$ DEE as e$$"
and these are assigned to pins 087 and 0-7 respecti(e$%& 0$acing these signa$s in c$ose
pro7imit% simp$ifies the ph%sica$ routing on the 0C@&
The signa$s from the passenger detection sensors i$$ #e reduced to a sing$e signa$ #% using
a 0;-& That signa$ i$$ #e read #% pin 083 on the microcontro$$er& 8 summar% of the
microcontro$$er pin assignments can #e found in Ta#$e *&1&
+4+
ECE 477 Digital Systems Senior Design Project Spring 2008
)ignal .in Name .in Num$er
05= =otor Contro$$er Tor6ue -emand OC18" OC1@ 12" 18
=otor Contro$$er -irection Contro$ 0-0" 0-1 14" 1,
2+a7is 8cce$erometer 081" 082 *2" *8
8ngu$ar .ate Sensor 08*"084 *7"*3
Steering Jo%stic! 08, *,
@atter% ;e(e$ =onitor 080 40
;C- -ata 0C0+0C7 22+22
;C- .egister Se$ect [Link] 087 **
;C- C$oc! DEE 0-7 21
0assenger -etection 083 *4
Ta$le /! K Summar% of =icrocontro$$er 0in Fsage
0+ )ummary
The To 5hee$ -ea$)s circuitr% has #een carefu$$% designed around creating a circuit that is
#oth sensiti(e enough to proper$% detect and react to sma$$ changes in the (ehic$e)s d%namics" %et
poerfu$ enough to mo(e a person& The $ead acid #atteries supp$% amp$e current to the motors"
hi$e the $inear (o$tage regu$ators pro(ide a sta#$e poer supp$% to the (o$tage sensiti(e digita$
components& 8 microcontro$$er sits at the center of the design" interfacing direct$% to a$$ of the
sensors and user inputs hi$e interfacing through iso$ation circuits to the motor contro$$ers to
pre(ent damage to the de$icate circuitr% surrounding the microcontro$$er& The end resu$t is
simp$e %et effecti(e rea$i?ation of a circuit that performs a$$ of the ca$cu$ations" sensing" and
poer de$i(er% re6uired for The To 5hee$ -ea$&
+,+
ECE 477 Digital Systems Senior Design Project Spring 2008
1ist of *eferen-es
A1B 8na$og -e(ices" 8na$og -e(ices 8-L;10*I8-L;20* -ata Sheet" AOn$ine -ocumentB"
Acited 2 :e#ruar% 2008B"
http:22wwwanalog-om23ploaded4iles2Data5)heets2'D61!+/5"+/pdf
A2B =e$e7is" =;L20302+E2 8ngu$ar .ate Sensor -ata Sheet" AOn$ine -ocumentB" Acited 2
:e#ruar% 2008B"
http:22wwwmele7is-om2prodfiles2+++5+855#168+9+8%"5we$5datasheetpdf
A*B :airchi$d Semiconductor" >.:*20, 0oer =OS:ET -ata Sheet" AOn$ine -ocumentB"
Acited 2 :e#ruar% 2008B" http:22wwwfair-hildsemi-om2ds2H*2H*4/"+5pdf
A4B /ntersi$" >/040818 809 >igh :re6uenc% >+@ridge -ri(er" AOn$ine -ocumentB" Acited 2
:e#ruar% 2008B" http:22wwwintersil-om2data2an2an80+5pdf
A,B 8tme$" 8Tmega*2 -atasheet" AOn$ine -ocumentB" Acited 2 :e#ruar% 2008B"
http:22wwwatmel-om2dyn2resour-es2prod5do-uments2do-"5+/pdf
+3+
ECE 477 Digital Systems Senior Design Project Spring 2008
'ppendi7 ': )ystem :lo-k Diagram
+7+

You might also like