
Mini57
Apr. 06, 2017
Page 296 of 475
Rev.1.00
MINI5
7
S
E
RI
E
S
TECH
NIC
A
L R
E
F
E
RE
N
CE
MA
N
UA
L
6.10.4 Clock Control
The Watchdog Timer clock control and block diagram are shown as follows.
10
HCLK/2048
10 kHz LIRC
WDTSEL (CLK_CLKSEL1[1:0])
WDTCEN (CLK_APBCLK[0])
WDT_CLK
11
Legend:
LIRC = Low-Speed Internal clock signal
00
HXT or LXT
Figure 6.10-2 Watchdog Timer Clock Control Diagram
6.10.5 Basic Configuration
The WDT peripheral clock is enabled in WDTKEN (CLK_APBCLK[0]) and clock source can be
selected in WDTSEL (CLK_CLKSEL1[1:0]).
6.10.6 Functional Description
The Watchdog Timer (WDT) includes an 18-bit free running up counter with programmable time-
out intervals. Figure 6.10-3 shows the WDT time-out interval and reset period timing.
6.10.6.1 WDT Time-out Interrupt
Setting WDTEN (WDTCR[7]) bit to 1 will enable the WDT function and the WDT counter to start
counting up. There are eight time-out interval period can be selected by setting TOUTSEL
(WDT_CTL[10:9]). When the WDT up counter reaches the TOUTSEL ((WDT_CTL[10:9]) settings,
WDT time-out interrupt will occur then IF (WDT_CTL[3]) flag will be set to 1 immediately.
6.10.6.2 WDT Reset Delay Period and Reset System
There is a specified T
RSTD
delay period follows the IF (WDT_CTL[3]) flag is setting to 1. User must
enabled RSTCNT (WDT_CTL[0]) bit to reset the 18-bit WDT up counter value to avoid generate
WDT time-out reset signal before the T
RSTD
delay period expires. If the WDT up counter value has
not been cleared after the specific T
RSTD
delay period expires, the WDT control will set RSTF
(WDT_CTL[2]) flag to 1 if RSTEN(WDT_CTL[1]) bit is enabled, then chip enters to reset state
immediately. Refer to Figure 6.10-3, the T
RST
reset period will keep last 63 WDT clocks then chip
restart executing program from reset vector (0x0000_0000). The RSTF (WDT_CTL[2]) flag will
keep 1 after WDT time-out reset the chip, user can check RSTF(WDT_CTL[2]) flag by software
to recognize the system has been reset by WDT time-out reset or not.