Chapter 27 Functional Safety
MPC5602P Microcontroller Reference Manual, Rev. 4
758
Freescale Semiconductor
27.3.5.7
SWT Service Key Register (SWT_SK)
The SWT Service Key (SWT_SK) register holds the previous (or initial) service key value. This register
is read only if either the SWT_CR[HLK] or SWT_CR[SLK] bits are set.
27.3.6
Functional description
The SWT is a 32-bit timer designed to enable the system to recover in situations such as software getting
trapped in a loop or if a bus transaction fails to terminate. It includes a a control register (SWT_CR), an
interrupt register (SWT_IR), time-out register (SWT_TO), a window register (SWT_WN), a service
register (SWT_SR) and a counter output register (SWT_CO).
The SWT_CR includes bits to enable the timer, set configuration options and lock configuration of the
module. The watchdog is enabled by setting the SWT_CR.WEN bit. The reset value of the
SWT_CR.WEN bit is device specific1 (enabled). This last bit is cleared when exiting ME RESET mode
in case flash user option bit 31 (WATCHDOG_EN) is 0. If the reset value of this bit is 1, the watchdog
starts operation automatically after reset is released. Some devices can be configured to clear this bit
automatically during the boot process.
Table 27-11. SWT_CO field descriptions
Field
Description
CNT
Watchdog Count
When the watchdog is disabled (SWT_CR.[WEN]=0) this field shows the value of the internal down
counter. When the watchdog is enabled the value of this field is 0x0000_0000. Values in this field can lag
behind the internal counter value for as many as 6 system plus 8 counter clock cycles. Therefore, the
value read from this field immediately after disabling the watchdog may be higher than the actual value
of the internal counter.
Address: Base + 0x0018
Access: User read/write
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
R
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
W
Reset
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
R
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
W
SK
Reset
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
Figure 27-17. SWT Service Register (SWT_SR)
Table 27-12. SWT_SR field descriptions
Field
Description
SK
Service Key.This field is the previous (or initial) service key value used in keyed service mode. If
SWT_CR[KEY] is set, the next key value to be written to the SWT_SR is (17*SK+3) mod 2
16
.