ETIC 2230 Guide de l'utilisateur Page 43

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 148
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 42
Rev. 1.10 42 November 14, 2014 Rev. 1.10 43 November 14, 2014
HT66FW2230
Wireless Charger A/D Flash 8-Bit MCU
Bit0 WRF:resetcausedbyWE[4:0]setting
0:Notoccur
1:Occurred
Thisbitissetto1bytheWDTControlregistersoftwareresetandclearedbythe
applicationprogram.Notethatthisbitcanonlybeclearedto0bytheapplication
program.
Watchdog Timer Operation
TheWatchdogTimeroperatesbyprovidingadeviceresetwhenitstimeroverows.Thismeans
thatintheapplicationprogramandduringnormaloperationtheuserhastostrategicallyclearthe
WatchdogTimerbeforeitoverowstopreventtheWatchdogTimerfromexecutingareset.Thisis
doneusingtheclearwatchdoginstruction.Iftheprogrammalfunctionsforwhateverreason,jumps
toanunknownlocation,orentersanendlessloop,thisclearinstructionwillnotbeexecutedinthe
correctmanner,inwhichcasetheWatchdogTimerwilloverowandresetthedevice.Withregardto
theWatchdogTimerenablefunction,therearevebits,WE4~WE0,intheWDTCregistertooffer
theenablecontrolandresetcontroloftheWatchdogTimer.TheWDTfunctionwillbeenabledif
theWE4~WE0bitsareequalto10101or01010B.IftheWE4~WE0bitsaresettoanyothervalues,
otherthan01010Band10101B,itwillresetthedeviceafter2~3LIRCclockcycles.Afterpoweron
thesebitswillhaveavalueof01010B.
WE4 ~ WE0 Bits WDT Function
01010B or 10101B Enable
Any other value Reset MCU
Watchdog Timer Enable/Disable Control
Undernormalprogramoperation,aWatchdogTimertime-outwillinitialiseadeviceresetandset
thestatusbitTO.However,ifthesystemisintheSLEEPorIDLEMode,whenaWatchdogTimer
time-outoccurs,theTObitinthestatusregisterwillbesetandonlytheProgramCounterandStack
Pointerwillbereset.ThreemethodscanbeadoptedtoclearthecontentsoftheWatchdogTimer.
TherstisaWDTsoftwarereset,whichmeansacertainvalueexcept01010Band10101Bwritten
intotheWE4~WE0eld.ThesecondisusingtheWatchdogTimersoftwareclearinstruction.The
thirdisviaaHALTinstruction.
ThereisonlyonemethodofusingsoftwareinstructiontocleartheWatchdogTimer.Thatistouse
thesingle“CLRWDT”instructiontocleartheWDTcontents.
Themaximumtimeoutperiodiswhenthe2
18
divisionratioisselected.Asanexample,witha32
KHzLIRCoscillatorasitssourceclock,thiswillgiveamaximumwatchdogperiodofaround8
secondforthe2
18
divisionratio,andaminimumtimeoutof7.8msforthe2
8
divisionration.
Vue de la page 42
1 2 ... 38 39 40 41 42 43 44 45 46 47 48 ... 147 148

Commentaires sur ces manuels

Pas de commentaire