UM11029
All information provided in this document is subject to legal disclaimers.
© NXP Semiconductors N.V. 2017. All rights reserved.
User manual
Rev. 1.0 — 16 June 2017
415 of 515
NXP Semiconductors
UM11029
Chapter 22: LPC84x Windowed Watchdog Timer (WWDT)
22.4 Pin description
The WWDT has no external pins.
22.5 General description
The purpose of the Watchdog Timer is to reset or interrupt the microcontroller within a
programmable time if it enters an erroneous state. When enabled, a watchdog reset is
generated if the user program fails to feed (reload) the Watchdog within a predetermined
amount of time.
When a watchdog window is programmed, an early watchdog feed is also treated as a
watchdog event. This allows preventing situations where a system failure may still feed
the watchdog. For example, application code could be stuck in an interrupt service that
contains a watchdog feed. Setting the window such that this would result in an early feed
will generate a watchdog event, allowing for system recovery.
The Watchdog consists of a fixed (divide by 4) pre-scaler and a 24-bit counter which
decrements when clocked. The minimum value from which the counter decrements is
0xFF. Setting a value lower than 0xFF causes 0xFF to be loaded in the counter. Hence the
minimum Watchdog interval is (T
WDCLK
256
4) and the maximum Watchdog interval is
(T
WDCLK
2
24
4) in multiples of (T
WDCLK
4). The Watchdog should be used in the
following manner:
•
Set the Watchdog timer constant reload value in the TC register.
•
Set the Watchdog timer operating mode in the MOD register.
•
Set a value for the watchdog window time in the WINDOW register if windowed
operation is desired.
•
Set a value for the watchdog warning interrupt in the WARNINT register if a warning
interrupt is desired.
•
Enable the Watchdog by writing 0xAA followed by 0x55 to the FEED register.
•
The Watchdog must be fed again before the Watchdog counter reaches zero in order
to prevent a watchdog event. If a window value is programmed, the feed must also
occur after the watchdog counter passes that value.
Fig 51. WWDT clocking
WWDT
SYSCON
system clock
SYSAHBCLKCTRL
(WWDT clock enable)
watchdog oscillator
PDRUNCFG
(enable watchdog oscillator
WDTOSC_PD)
WWDT registers
503 kHz
24-bit timer
TV