Hi,
I am using an nRF52840 with SDK 17.0.2 and S140 7.2.0. I am running a scheduler based on app_scheduler.
I am trying to make my FDS implementation blocking as it is too complex to run a synchronously as there are quite a few calls to it that are causing havoc with the queues. I have set up a flag that I set to true before executing an FDS operation and then I want to wait for that flag to become false before continuing. I have tried the following:
Simple, empty while loop. This just locks the processor up and the command is never received
while( _fdsBusy ) ;
NRF Delay. This has a similar effect to above
while( _fdsBusy ) { nrf_delay_ms(1); }
Using my scheduler to wait. While the event is received in the Event Handler, the code never carries on executing.
while( _fdsBusy ) { app_sched_execute( ); nrf_pwr_mgmt_run( ); }
Is there any way to achieve what I want?
Thanks,