Hello,
i use the bond manager together with a own module to store data in memory. On user interaction i want to delete the whole memory. I proceed as follows:
- Disconnect from Device/Deactivate Advertising
- Call ble_bondmngr_bonded_centrals_delete() function
- Call my own delete function for user momory
- Call Bond manager init function (also pstorage_init() is calles in this function)
- Call my own memory init function (pstorage_init() is not called)
- Activate Advertising
The problem is now that if i call bond manager init (step 4) the pstorages module is reinitialized and the command queue from pstorages module is deleted. So my own delete function call from step 3 is nor executed.
What is the best practise to get the state after all commands are processed in pstorage module. In the pstorage module there is the function pstorage_sys_event_handler() but no callback is called if all commands are processed.
Do all memory commands have to be executed before i call Bond manager init?
Do all memory commands have to be executed before i start advertising?