Part Number: MSPM0G1505
Hi TI Gurus,
I am troubleshooting an intermittent runtime reset issue on an MSPM0G1505 (silicon revision 2).
Observed Failure:
During normal operation, the device occasionally resets. After instrumenting the fault handlers, I determined the sequence is:
- NMI occurs with source DL_SYSCTL_NMI_IIDX_FLASH_DED
- NMI exits
- A subsequent HardFault occurs
- Device resets
We do not perform runtime flash programming.
Investigation Performed:
Based on previous guidance and errata review, I verified:
- No DMA reads from flash are occurring.
- No apparent DMA/flash bus collisions.
- Flash wait states are configured correctly for operating frequency.
- I have reviewed code for stack corruption and pointer corruption issues and have not found evidence of either.
- Application image is not located near the end of flash, and avoiding the last flash bytes does not appear relevant to our memory layout.
- I have captured and correlated SYSCTL->DEDERRADDR and it is somewhat random but always near to a __WFI() instruction.
Findings:
While reviewing errata SLAZ742G, I noticed CLK_ERR_01, which discusses operation with a 4 MHz crystal and debugger connected.
Our design uses a 4 MHz HFXT crystal, but the failures occur without a debugger connected.
As an experiment, I changed the HFXTRSEL from:
DL_SYSCTL_HFXT_RANGE_4_8_MHZ
to
DL_SYSCTL_HFXT_RANGE_8_16_MHZ
This completely eliminates the FLASH_DED/HardFault/reset issue.
More importantly, I can reliably make the problem appear and disappear simply by switching between these two HFXTRSEL settings.
Results:
HFXTRSEL = 4-8 MHz
- Intermittent FLASH_DED NMI
- HardFault follows
- System resets
HFXTRSEL = 8-16 MHz
- Failure disappears
However, using the 8-16 MHz setting has side effects:
- Approximately 10% increase in core current (~1470 µA baseline)
- About 3 ppm reduction in measured crystal frequency accuracy
Questions:
1. For a 4 MHz crystal operating without a debugger attached, should there ever be FLASH_DED, NMI, or HardFault events related to the HFXT range setting, specifically the 4-8MHz setting?
2. Is CLK_ERR_01 (slaz742g) strictly caused by active debugger interaction, or can certain debug-related MCU settings, programming/debug operations, or clock configurations trigger the same behavior in standalone operation?
3. Are there any known mechanisms by which an incorrect HFXTRSEL setting could result in FLASH_DED / NMI events?
4. Has anyone observed similar behavior where changing HFXTRSEL from 4-8 MHz to 8-16 MHz eliminates intermittent FLASH_DED / NMI errors?
5. Are there additional clock-system or flash-controller settings that should be reviewed?
Any insight would be appreciated. The ability to command the failure in and out solely by changing HFXTRSEL makes it appear that the clock configuration may be closely related to the root cause.