Hi
@Celeste_Liu,
Thank you for your response! I appreciate the explanation about the LVD reset behavior and the pointer to the power_mode_switch SDK demo.
However, my actual requirement is slightly different from what was covered. I need to configure the LVD to trigger an interrupt (ISR) instead of (or in addition to) a reset, so that my application can:
1. Detect a low voltage condition at runtime
2. Handle it gracefully inside an ISR (e.g., save state, log the event, or initiate a controlled shutdown)
3. Resume or recover without necessarily triggering a full cold reset
Specifically, I would like to know:
- How to configure the SPC/LVD to generate an interrupt instead of (or before) asserting a reset
- Which NVIC interrupt vector corresponds to the LVD event on MCXA156/155
- How to write and register the ISR to capture the LVD event
- How to clear the LVD interrupt flag inside the ISR
A minimal working C code example demonstrating this interrupt-driven LVD detection on the FRDM-MCXA156 would be extremely helpful.
Thank you in advance!
BR,
Puneeth