This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Clearing Pending Flash Events via System Reset

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

Parents
  • I see. I guess what is happening is that the softdevice never sees a timeslot long enough to give time for the flash operation in this case. It is probably possible to break the connecting/disconnecting loop somehow, but if not, I do think it would be safe to call sd_nvic_SystemReset(). However I think you can call pstorage_init() again instead, which will lead to flushing of the command queue.

Reply
  • I see. I guess what is happening is that the softdevice never sees a timeslot long enough to give time for the flash operation in this case. It is probably possible to break the connecting/disconnecting loop somehow, but if not, I do think it would be safe to call sd_nvic_SystemReset(). However I think you can call pstorage_init() again instead, which will lead to flushing of the command queue.

Children
No Data
Related