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

Incorrect ADC readings after waking up from System Off Mode

Hello Nordic Team,

We are working on a project based on nrf51822, we have a problem regarding the incorrect ADC values while waking up the microcontroller from System Off Sleep mode.

Please find the ADC configuration we are using below

ret_code_t err_code = nrf_drv_adc_init(NULL, adc_event_handler);
APP_ERROR_CHECK(err_code);
static nrf_drv_adc_channel_t channel = NRF_DRV_ADC_DEFAULT_CHANNEL(NRF_ADC_CONFIG_INPUT_6);
channel.config.config.input = (uint32_t)NRF_ADC_CONFIG_SCALING_INPUT_ONE_THIRD;
nrf_drv_adc_channel_enable(&channel);
err_code = nrf_drv_adc_buffer_convert(&adc_buf[0], 1);
APP_ERROR_CHECK(err_code);

We are getting proper values from ADC(let's say 610) after programming the nrf51 device. The incorrect readings start when the device goes to system off sleep mode and turned on again using a gpio pin. then the value from the ADC reads 30 less than the actual value (i.e 580).

I have to hard reset the device again to read the correct ADC value. Why is the reason for these incorrect readings?

Am I doing anything wrong? Please help us to resolve this issue at the earliest.

Best,

Krishna

Parents Reply Children
Related