Case A:
INTOSC1 is used as the clock source. NMIWD is disabled (NMIRESETSEL = 0)
Failure of INTOSC1 causes PLL to issue a limp mode clock. The system continues to function with the limp clock
and so does the VCOCLK counter. Eventually, VCOCLK counter overflows and issues a CLOCKFAIL signal
(MCLKSTS bit is set) and the missing clock detection logic resets the CPU, peripherals, and other device logic
by way of MCLKRS. The exact delay (from the time the clock was stopped to the time a reset is asserted)
depends on the VCOCLK counter value when the INTOSC1 clock vanished. The MCLKSTS bit is only affected
by XRS, not by a missing clock reset. So, after a reset, code can examine this bit to determine if the reset was
due to a missing clock and take appropriate action. Note that even though the CLOCKFAIL signal is generated,
the NMIWDCNTR will not count.
Case B:
INTOSC1 is used as the clock source. NMIWD is enabled (NMIRESETSEL = 1)
Failure of INTOSC1 causes PLL to issue a limp mode clock. The system continues to function with the limp
clock and so does the VCOCLK counter. Eventually, the VCOCLK counter overflows and issues CLOCKFAIL
(MCLKSTS bit is set), which asserts the NMI and starts the NMIWDCNTR. If NMIWDCNTR is allowed to reach
the NMIWDPRD value, a reset ( MCLKRS) is asserted. In the interim period, the application could choose to
gracefully shut down the system before a reset is generated. Inside the NMI_ISR, the flags in NMIFLG register
may be cleared, which prevents a reset.
In case A, reset is inevitable and cannot be delayed. In case B, the software can
• Choose to clear the flags to prevent a reset.
• Perform a graceful shutdown of the system.
• Switch to OSCCLKSRC2, if need be.
Case C:
OSCCLKSRC2 (INTOSC2 or X1/X2 or XCLKIN) is used as the clock source. NMIWD is disabled
(NMIRESETSEL = 0)
When the VCOCLK counter overflows (due to loss of OSCCLKSRC2), the Missing-Clock-Detect circuit
recognizes the missing clock condition. CLOCKFAIL will be generated (but it is of no consequence). Since
NMIRESETSEL=0, the device will be reset. No switching of clock source happens, since the device is reset. This
is similar to Case A.
Case D:
OSCCLKSRC2 (INTOSC2 or X1/X2 or XCLKIN) is used as the clock source. NMIWD is enabled
(NMIRESETSEL = 1)
When the VCOCLK counter overflows (due to loss of OSCCLKSRC2), the Missing-Clock-Detect circuit
recognizes the missing clock condition. CLOCKFAIL is generated and OSCCLK is switched to INTOSC1. For
this reason, INTOSC1 should not be disabled in user code. The MCLKSTS bit is set, but cleared automatically
after the clock switch. PLLCR is zeroed. The user must reconfigure PLLCR. Since NMIRESETSEL=1, NMI
interrupt will be triggered and PLL could be reconfigured there. Inside the NMI_ISR, the flags in the NMIFLG
register may be cleared, which prevents a reset. If INTOSC1 also fails, this becomes similar to Case B. The
advantage of using OSCCLKSRC2 as the source for the PLL is that the clock source is automatically switched to
INTOSC1 upon loss of OSCCLKSRC2.
System Control and Interrupts
86
TMS320x2806x Microcontrollers
SPRUH18I – JANUARY 2011 – REVISED JUNE 2022
Copyright © 2022 Texas Instruments Incorporated
Содержание TMS320 2806 Series
Страница 2: ......