
102
µPD750008 USER'S MANUAL
5.3.5 Operation of the Watchdog Timer
When WDTM is set to 1, the basic interval timer/watchdog timer functions as a watchdog timer. An internal
reset signal is generated when the basic interval timer (BT) overflows. No reset signal, however, is generated
during the oscillation wait time following the STOP instruction has been released (WDTM cannot be cleared
without using reset). BT is constantly incremented by the clock supplied from the clock generator. It cannot
be stopped from counting.
In the watchdog timer mode, program crashes are detected using the intervals at which BT overflows. The
interval can be selected from among four values depending on bits 2 to 0 of BTM (see Figure 5-24). Select
an interval for detecting crashes according to the user system. A large program should be divided into modules
each of which can be executed within the set interval. Include an instruction which clears BT at the end of
each module. If execution does not reach the instruction which clears BT within the set interval (in which case
a program error leading to a program crash may have occurred), BT overflows and an internal reset signal
is generated to forcibly terminate the program. The occurrence of internal reset possibly means that a program
crash has occurred. A crash can thus be detected.
Set the watchdog timer as follows (<1> and <2> can be performed with the same instruction):
<1> Set the interval in BTM.
<2> Set 1 in bit 3 of BTM. Initial settings
<3> Set 1 in WDTM.
<4> After <1> to <3> are set, set 1 in bit 3 of BTM within each interval.
Example Use the basic interval/watchdog timer as a watchdog timer with 5.46-ms interval (at 6.00 MHz)
A program is divided into several modules each of which can be executed within the interval
set in BTM (5.46 ms). BT is cleared at the end of each module. If a program crash occurs, BT
overflows and an internal reset signal is generated because BT is not cleared within the set
interval.
(From now on, 1 is set in bit 3 of BTM at intervals of 5.46 ms.)
SET1
SEL
MOV
MOV
SET1
MBE
MB15
A, #1101B
BTM, A
WDTM
; Specifies a time interval and
; starts processing.
; Enables the watchdog timer.
···
Initial setting:
*
Summary of Contents for PD750004
Page 8: ... MEMO ...
Page 20: ... xii MEMO ...
Page 234: ...214 µPD750008 USER S MANUAL MEMO ...
Page 244: ...224 µPD750008 USER S MANUAL MEMO ...
Page 248: ...228 µPD750008 USER S MANUAL MEMO ...
Page 254: ...234 µPD75008 USER S MANUAL MEMO ...
Page 328: ...308 µPD750008 USER S MANUAL MEMO ...
Page 330: ...310 µPD750008 USER S MANUAL MEMO ...
Page 342: ...322 µPD750008 USER S MANUAL MEMO ...