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

SAADC configuration

Hi DevZone,

Here's my setup:

  1.  Using NRF5 SDK 15.2.0, custom board based on NRF52840
  2. Battery powered device with 3.6V battery.
  3. Supply voltage stepped down to 1.8V using buck converter, meaning the MCU runs on 1.8V
  4. There is a secondary I2C-based buck/boost converter in the circuit which can output voltages between 2.6V and 5V depending on I2C commands. The voltage output from this converter is VCC_AUX (see image)

Challenge:

I need to setup the ADC peripheral to sample ADC_VCC_3V8 (which sits on  AIN2) and ADC_BATT, (which sits on AIN1). There are voltage dividers on both voltage outputs.

  1. I'm not quite sure how to configure the ADC channels.
  2. How do I convert the ADC values back to the actual voltages?

Any suggestions are appreciated Slight smile

Thanks

Tim

Parents Reply Children
No Data
Related