2021-06-03 05:06 AM
Hello,
My board consists of stm32f427 and I have a strange problem.
Calling NVIC_SystemReset() causes CPU to hang. This happens only on some boards.
I could overcome the problem in one of the following:
SCB->AIRCR = ((0x5FA << SCB_AIRCR_VECTKEY_Pos) |
(SCB->AIRCR & SCB_AIRCR_PRIGROUP_Msk) |
SCB_AIRCR_SYSRESETREQ_Msk |
SCB_AIRCR_VECTCLRACTIVE_Msk | SCB_AIRCR_VECTRESET_Msk)
These 2 additional bits cause CPU to reset, although they are meant to be used only for debug
I read in forums that others encountered this problem but in my case it looks different:
Could anyone please explain:
Why NVIC_SystemReset() does not work on some boards?
How could the delay of 100 msec or setting system control register bypass the problem?
Thank you,
Ari
2021-06-03 09:06 AM
Only thing I can guess is if there's some flash operation still ongoing that is affecting things.
2021-06-03 09:21 AM
All very odd, don't have an explanation here.
Did you stop something else just prior to doing the reset? Flash Write or Erase? Turn off a PWM?
Is the capacitor really 100nF (0.1uF) and not something much larger?