Hi ,NXP
I am using S32K3 chip now,but I am facing a problem
Boot and App both use the function Mcu_GetResetReason,but the function will clear the reset Reason in it's first call. So when Boot jump to App ,App cannot get the reset reason .
Can you tell me how to solve it
Thank you in advance
Hi @CaoRq
That's desired behavior. Here's the reason:
If the flags are not cleared, you wouldn't be able to get the most recent source of reset next time. Only power-on reset clears the flag, so the flags would cumulate in the registers after "non-power-on" resets and it would not be possible to recognize which flag was set as the last one.
Solution - read the reset reason by Mcu_GetResetReason and store it in own variable for next use.
Regards,
Lukas