Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Look like a bug inside the function nrfx_saadc_calibrate_offset() in SDK 15.3.0 (nRF5_SDK_15.3.0_59ac345)

m_cb.adc_state is set to NRF_SAADC_STATE_CALIBRATION inside the function nrfx_saadc_calibrate_offset(), but the value is never changed to NRF_SAADC_STATE_IDLE, even is the function return with NRFX_SUCCESS.

Many functions, like nrfx_saadc_channel_init() will return with NRFX_ERROR_BUSY as m_cb.adc_state != NRF_SAADC_STATE_IDLE.

Workaround is to call nrfx_saadc_uninit() that set m_cb.adc_state = NRF_SAADC_STATE_IDLE, and doing a new call to nrfx_saadc_init()

Parents Reply Children
No Data
Related