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

System event handler SDK16, S212

I'm trying to register a handler to determine when a system event occurs?

Previously on older design kits, I used softdevice_sys_evt_handler_set(......) to register the handler and trying to do the same using SDK16. 

I tried using NRF_SDH_STATE_OBSERVER and NRF_SDH_STACK_OBSERVER  but it prevents my application from running. 

For example if I include it after

NRF_SDH_ANT_OBSERVER(m_ant_observer, XXX_OBSERVER_PRIO,
XXX_sens_evt_handler, &m_ant_XXX);

 the application ceases to run.

Is there an example on how to register an event to get notified when a system event occurs? I  am not expert on interrupts and can't seem to find any examples on how to do it.

I was able to use SD_EVT_IRQHandler but now it gives an error that it is multiply defined as more utilities are added. 

Thank you

Related