Hello,
I am currently working on the Exercise 3 – Interfacing with ADC using nrfx drivers and TIMER/PPI sample. I have it operating, however I am wondering what is the proper way to stop its operation? I have tried:
nrfx_timer_uninit(&timer_instance); nrfx_saadc_uninit(); nrfx_gppi_channels_disable_all();
However it appears that there is a stuck event NRFX_SAADC_EVT_DONE from the log that continually triggers the saadc_event_handler :
static void saadc_event_handler(const nrfx_saadc_evt_t *p_event) { LOG_DBG("%s", __func__); ... ... }
[07:15:48.192,474] <dbg> batt_adc: saadc_event_handler: saadc_event_handler [07:15:48.200,073] <dbg> batt_adc: saadc_event_handler: saadc_event_handler [07:15:48.207,733] <inf> batt_adc: SAADC buffer at 0x20002c94 filled with 200 samples [07:15:48.216,186] <inf> batt_adc: AVG=3183, MIN=3172, MAX=3192 [07:15:48.222,747] <dbg> batt_adc: saadc_event_handler: saadc_event_handler [07:15:48.230,346] <dbg> batt_adc: saadc_event_handler: saadc_event_handler [07:15:48.238,006] <inf> batt_adc: SAADC buffer at 0x20002b04 filled with 200 samples [07:15:48.246,459] <inf> batt_adc: AVG=3184, MIN=3171, MAX=3200