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

Re-enable softdevice

Hi. I'm trying to enable and disable softdevice repeatedely. In my code, softdevice is firstly enabled then advertising properly. After some seconds, softdevice is disabled and ESB is enabled. It is worked properly too. and then esb is deisabled, softdevice is re-enabled and try to start advertising. But I found an error code when re-enabling softdevice.

in ble_stack_handler.c

err_code = sd_softdevice_enable(clock_source, softdevice_assertion_handler);

returns 0x00001001 at second enabling. (at first enabling, it returns NRF_SUCCESS)

I don't know how to solve the problem. please help.

Parents Reply
  • Hi. I used ble_conn_params_stop() and softdevice_handler_sd_disable(), as in ble_app_gzll. I didn't check the return values of sd_softdevice_enable() in the ble_app_gzll yet.

    And, ble_app_evt_wait() function returns 0x02 that means soft device is not enabled. (devzone.nordicsemi.com/.../) If the softdevice is already enabled, why the function ble_app_wait_evt() returns 0x02?

    So I think the error code 0x00001001 means "enabled interrupt has an illegal priority level". How can I check priority level of enabled interrupts?

Children
No Data
Related