SPRUIM2H May 2020 – October 2023 AM2431 , AM2432 , AM2434 , AM6411 , AM6412 , AM6421 , AM6422 , AM6441 , AM6442
The device supports MCU_HFOSC0 clock loss circuitry to detect when MCU_HFOSC0_CLK stops toggling. If CTRLMMR_MCU_PLL_CLKSEL[8] CLKLOSS_SWTCH_EN is set and MCU_HFOSC0_CLK stops toggling condition is detected, the reference clock is switched from MCU_HFOSC0_CLKOUT to MCU_CLK_12M_RC to allow the device to operate with a slower clock. The MCU_HFOSC0_CLK stops toggling condition is reported as an error to MCU_ESM0 regardless of the value of CTRLMMR_MCU_PLL_CLKSEL[8] CLKLOSS_SWTCH_EN. Integration diagram of MCU_HFOSC0 clock loss detection is presented in Figure 5-491.
MCU_ESM0 can optionally generate an interrupt to R5FSS0/1 and MCU_M4FSS0 so they can save some critical contents such as error logging to scratch pad memory or external flash. ESM must also be configured to report this error on the MCU_SAFETY_ERRORn pin.
MCU_HFOSC0 clock loss is a catastrophic failure since this clock is the most critical system clock. During the clock loss condition an external system intervention is required.
The clock loss mux is not a glitch free mux. The mux control is synchronized to the MCU_CLK_12M_RC clock. Since MCU_HFOSC0_CLK has stopped switching the mux should transition to RC Clock without producing glitches.
Hence it is important to ensure that MCU_SAFETY_ERRORn is pulled low during this error condition. In clock-loss condition, the device reports the error to the external device through MCU_SAFETY_ERRORn pin - the pin is driven Low. The recovery mechanism is up to the external system (such as a PMIC to take action). For example, it can try a full system power cycle to see if the system recovers. If the system does not recover then, it has to take some other action such as to check system clocks, external crystal, supply rails.
PLL will lose the lock when clock loss is detected. During this time 12.5-MHz RC clock is output through the bypass muxes. The PLL will relock to a new frequency based on 12.5 MHz.
In an event of clock glitch which may potentially hang the device, then the DMSC0 watchdog timer will expire and will generate an internal reset for the whole device.