How to do multichannel adc in low power consumption

I am new to nrf52832 development. The question is that:

I want to do multichannel(4 or 5 channels) ADC in scan mode every 1s. and the MCU consumes ultra low current(3-5uA) at idle time.

I tried this example and it works just fine. 

It seems to be using  workaround from Errata 212 to cut the current consumption, but I didn't quite understand it. Could anyone help to explain it?

And is there other ways to do the same thing?

PS: I have tried another example but current consumption(about 1.3mA) is far higher than the former one.

Parents
  • Hi,

    It seems to be using  workaround from Errata 212 to cut the current consumption, but I didn't quite understand it. Could anyone help to explain it?

    In some cases, the SAADC enter a bad state. This workaround recovers by making a copy of some undocumented internal registers (including those that hold the offset calibration), and resetting the SAADC peripheral (disable and re-enable) by writing to an undocumented internal register, before writing back the data that was there before the reset.

    And is there other ways to do the same thing?

    The first example you refer to use the V2 API of the nrfx_saadc driver, and this is significantly improved and handles things like errata 212. So I recommend you use this. With that, as long as you stop the SAADC when not in use, you should get a low sleep current.

Reply
  • Hi,

    It seems to be using  workaround from Errata 212 to cut the current consumption, but I didn't quite understand it. Could anyone help to explain it?

    In some cases, the SAADC enter a bad state. This workaround recovers by making a copy of some undocumented internal registers (including those that hold the offset calibration), and resetting the SAADC peripheral (disable and re-enable) by writing to an undocumented internal register, before writing back the data that was there before the reset.

    And is there other ways to do the same thing?

    The first example you refer to use the V2 API of the nrfx_saadc driver, and this is significantly improved and handles things like errata 212. So I recommend you use this. With that, as long as you stop the SAADC when not in use, you should get a low sleep current.

Children
No Data
Related