ZHCSL05C October 2019 – October 2023 TPS65313-Q1
PRODUCTION DATA
The WD function uses a WD failure counter (WD_FAIL_CNT[3:0]) to track correct and incorrect MCU answers. The WD_FAIL_CNT[3:0] counter increments for each incorrect answer and decrements for each correct answer.
The WD_FAIL_CNT[3:0] counter is updated by the following events when the device is in the DIAGNOSTIC or ACTIVE or SAFE state:
When the value of the WD_FAIL_CNT[3:0] counter is less than the value set by the WD_FC_ENDRV_TH[3:0] bits, the WD function is considered to be in range, and the device keeps the WD-enabled function active (the ENDRV/nIRQ driver can be activated and the ENDRV/nIRQ pin is pulled high). The WD-enabled function is enabled by setting the ENDRV_EN control bit in the SAFETY_CHECK_CTRL register. When the value of the WD_FAIL_CNT[3:0] counter is greater than the value set by the WD_FC_ENDRV_TH[3:0] bits in the SAFETY_CFG4 register, the WD function is considered to be out of range, and the device disables the WD-enabled ENDRV/nIRQ function by driving ENDRV/nIRQ pin low. Figure 11-15 summarizes the settings of the WD status bits depending on the WD_FAIL_CNT[3:0] counter value with respect to the WD_FC_ENDRV_TH[3:0] bits value.
WD STATUS BITS | WD_FAIL_CNT[3:0] = 0b | 0b < WD_FAIL_CNT[3:0] < WD_FC_ENDRV_TH[3:0](2) | WD_FAIL_CNT[3:0] ≥ WD_FC_ENDRV_TH[3:0](3) |
---|---|---|---|
WD_FAIL(1) | 0b | 1b | 1b |
WD_ENDRV_FAIL | 0b | 0b | 1b |
If the WD_RST_EN configuration bit in the SAFETY_CFG3 register is set to 1b, the WD generates a reset to the MCU by driving NRES pin low when the WD_FAIL_CNT[3:0] counter reaches the programmed threshold set by the WD_FC_RST_TH[3:0] bits. Table 11-9 summarizes the WD status bits and device state depending on the WD_FAIL_CNT[3:0] counter value with respect to WD_FC_RST_TH[3:0] bits value.
WD STATUS BITS | WD_FAIL_CNT[3:0] = 0b | 0b < WD_FAIL_CNT[3:0] < WD_FC_RST_TH[3:0](2) | WD_FAIL_CNT[3:0] = WD_FC_RST_TH[3:0] and WD_RST_EN = 1b(3) | WD_FAIL_CNT[3:0] = WD_FC_RST_TH[3:0] and WD_RST_EN = 0b(3) |
---|---|---|---|---|
WD_FAIL(1) | 0b | 1b | 1b | 1b |
WD_RST_FAIL | 0b | 0b | 1b | 1b |
Device State | No change | No change | RESET state (4) | SAFE state |
When a NPOR event occurs, the WD_FAIL_CNT[3:0] counter is initialized to 0x05, which is the initial value of the WD_FC_ENDRV_TH[3:0] bits. While the device is in the DIAGNOSTIC state, the MCU can set the desired WD_FC_ENDRV_TH[3:0] and WD_FC_RST_TH[3:0] values. Setting new WD_FC_ENDRV_TH[3:0] value in DIAGNOSTIC state causes the WD_FAIL_CNT[3:0] counter to be set to the same new value. This WD_FAIL_CNT[3:0] bits update is to make sure that the ENDRV function is initially disabled until correct WD answers are provided by the MCU.
When the WD_FAIL_CNT[3:0] counter reaches a count of 0xF, any new incorrect answer from the MCU does not change the counter value. The counter stays at 0xF. Similarly, when the WD_FAIL_CNT[3:0] counter reaches a count of 0x0, any new correct WD answers do not change the counter value. The counter stays at 0x0.