I have a rare issue where my device won't advertising as it is waiting for a Pending Flash event to clear. However I want to add a supervisor time-out to this. It is safe to call sd_nvic_SystemReset() to clear pending Flash events?
Thanks
I have a rare issue where my device won't advertising as it is waiting for a Pending Flash event to clear. However I want to add a supervisor time-out to this. It is safe to call sd_nvic_SystemReset() to clear pending Flash events?
Thanks
The CPU is blocked while flash operations are performed, so you cannot reset the chip (or do anything else) from software in that case. You could of course use the watchdog, but a better option is to figure out why your code is stuck waiting for the pending event to finish.
How are you waiting for the event? Do you have a flag that you set yourself in your code that you wait for? How and where are you setting the flag, waiting for the flag and clearing the flag? Are you using pstorage or are you accessing the flash in another way?
The CPU is blocked while flash operations are performed, so you cannot reset the chip (or do anything else) from software in that case. You could of course use the watchdog, but a better option is to figure out why your code is stuck waiting for the pending event to finish.
How are you waiting for the event? Do you have a flag that you set yourself in your code that you wait for? How and where are you setting the flag, waiting for the flag and clearing the flag? Are you using pstorage or are you accessing the flash in another way?