Watchdog Timer
19-4 Élan™SC520 Microcontroller User’s Manual
Each individual write of these keyed sequences is not required to be written back-to-back
as an atomic sequence. Any number of processor cycles, including memory and I/O reads
and writes, can be inserted between the key and the writing of data, as long as they do not
access the Watchdog Timer Control (WDTMRCTL) register.
19.4.1.2 Interrupt Request Generation
To configure interrupt request generation on the watchdog timer, software must set the ENB
bit in the Watchdog Timer Control (WDTMRCTL) register to enable access of the register.
The WRST_ENB bit in this register must be cleared. Once the watchdog timer times out,
the interrupt request is generated.
The watchdog timer interrupt request can be programmed as maskable or non-maskable.
See Chapter 15, “Programmable Interrupt Controller”, for details on selecting a maskable
or non-maskable watchdog timer interrupt request.
If a second time-out event occurs and software has not cleared the IRQ_FLG bit asserted
by the first time-out, the watchdog timer causes a system reset instead of an interrupt
request, regardless of the setting of the WRST_ENB bit.
19.4.1.3 System Reset Generation
To configure the watchdog timer for system reset generation, software must set the ENB
bit to enable access of the register. The WRST_ENB bit must also be set. Once the
watchdog timer times out, the system reset is generated.
19.4.1.4 Time-Out Duration
The Exponent Select (EXP_SEL) bit field in the Watchdog Timer Control (WDTMRCTL)
register indicates the exponent value used to calculate the time-out duration in the following
formula:
Duration = 2
Exponent
/ (33 MHz crystal frequency)
where:
frequency is based on a 33-MHz incoming clock, as shown in Table 19-2.
Notes:
Only the least significant bit set in the EXP_SEL field determines the time-out duration. For example,
setting the field to F0h results in an exponent of 27.
Table 19-2 Watchdog Timer Time-Out Duration
EXP_SEL Field Exponent 33.000 MHz 33.333 MHz
00h invalid value infinity infinity
01h 14 496 µs 492 µs
02h 24 508 ms 503 ms
04h 25 1.02 s 1.01 s
08h 26 2.03 s 2.01 s
10h 27 4.07 s 4.03 s
20h 28 8.13 s 8.05 s
40h 29 16.27 s 16.11 s
80h 30 32.54 s 32.21 s