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

Assertion in soc_radio_timeslot.c

Hello, I am getting a 0xdeadbeef assertion at src\soc_radio_timeslot.c line 390. I am using S110 SoftDevice v7.1.0 with nRF51822 revision 2 CEAA. I am using the multiprotocol timeslot API to run BLE simultaneously with Micro ESB. What could cause this specific error? I don't think it's caused by spending too much time in the timeslot signal handler, because that causes an assertion at a different line in soc_radio_timeslot.c. Thanks, Paolo

Parents
  • I think that I might have found the problem:

    In the Micro ESB library, the uesb_init function calls NVIC_SetPriority to change the RADIO IRQ priority, by default to AppHigh. Since that library assumes that it's not running under a SoftDevice this would normally be ok. Based on the nrf51-ble-micro-esb-uart sample code, I am calling uesb_init from a software interrupt at AppHigh priority, triggered from the radio signal callback at the start of a timeslot. However the SoftDevice probably is expecting that the RADIO IRQ priority would not be changed during the timeslot. Removing the call to NVIC_SetPriority from uesb_init, leaving the RADIO IRQ priority at the level the SoftDevice set it to, appears to fix the problem.

    I haven't done much testing of this fix yet, and will post here if I have any more trouble.

Reply
  • I think that I might have found the problem:

    In the Micro ESB library, the uesb_init function calls NVIC_SetPriority to change the RADIO IRQ priority, by default to AppHigh. Since that library assumes that it's not running under a SoftDevice this would normally be ok. Based on the nrf51-ble-micro-esb-uart sample code, I am calling uesb_init from a software interrupt at AppHigh priority, triggered from the radio signal callback at the start of a timeslot. However the SoftDevice probably is expecting that the RADIO IRQ priority would not be changed during the timeslot. Removing the call to NVIC_SetPriority from uesb_init, leaving the RADIO IRQ priority at the level the SoftDevice set it to, appears to fix the problem.

    I haven't done much testing of this fix yet, and will post here if I have any more trouble.

Children
No Data
Related