Rev. 1.71 46 April 11, 2017 Rev. 1.71 47 April 11, 2017
HT66F002/HT66F0025/HT66F003/HT66F004
Cost-Effective A/D Flash MCU with EEPROM
HT66F002/HT66F0025/HT66F003/HT66F004
Cost-Effective A/D Flash MCU with EEPROM
Watchdog Timer
TheWatchdogTimerisprovidedtopreventprogrammalfunctionsorsequencesfromjumpingto
unknownlocations,duetocertainuncontrollableexternaleventssuchaselectricalnoise.
Watchdog Timer Clock Source
TheWatchdogTimerclocksourceisprovidedbytheinternalf
LIRC
clockwhichissuppliedbythe
LIRCoscillator.TheWatchdogTimersourceclockisthensubdividedbyaratioof2
8
to2
15
togive
longertimeouts,theactualvaluebeingchosenusingtheWS2~WS0bitsintheWDTCregister.The
LIRCinternaloscillatorhasanapproximateperiodof32kHzatasupplyvoltageof5V.However,it
shouldbenotedthatthisspeciedinternalclockperiodcanvarywithV
DD
,temperatureandprocess
variations.TheWDTcanbeenabled/disabledusingtheWDTCregister.
Watchdog Timer Control Register
Asingleregister,WDTC,controlstherequiredtimeoutperiodaswellastheenable/disable
operation.TheWRFsoftwareresetagwillbeindicatedintheSMOD1register.Theseregisters
controltheoveralloperationoftheWatchdogTimer.
WDTC Register
Bit 7 6 5 4 3 2 1 0
Name WE4 WE3 WE2 WE1 WE0 WS2 WS1 WS0
R/W R/W R/W R/W R/W R/W R/W R/W R/W
POR 0 1 0 1 0 0 1 1
B
it7~3 WE4 ~ WE0:WDTfunctionsoftwarecontrol
10101:WDTdisable
01010:WDTenable
Othervalues:ResetMCU
Whenthesebitsarechangedtoanyothervaluesbytheenvironmentalnoisetoresetthe
microcontroller,theresetoperationwillbeactivatedafter2~3LIRCclockcyclesandtheWRF
bitwillbesetto1toindicatetheresetsource.
B
it2~0 WS2 ~ WS0:WDTTime-outperiodselection
000:2
8
/f
LIRC
001:2
9
/f
LIRC
010:2
10
/f
LIRC
011:2
11
/f
LIRC
(default)
100:2
12
/f
LIRC
101:2
13
/f
LIRC
110:2
14
/f
LIRC
111:2
15
/f
LIRC
ThesethreebitsdeterminethedivisionratiooftheWatchdogTimersourececlock,whichinturn
determinesthetimeoutperiod.