I am trying to measure my battery level on my nRF51822 beacon board through the internal ADC.
The chip is just advertising itself every 5 seconds.
The measurement works, I do get voltage readings.
My issue is that the measurement needs to be done during the most power-hungry phase, which is probably the RF phase when the advertisement packet is sent out,
since that's when the voltage seems to dip the most.
My challenge is:
how to get the lowest battery voltage over time?
Since I can probably not continuously measure the voltage, my question boils down to these points:
- What's the proper way of usefully measuring the battery level when just advertising?
- Is there any event fired or any way to hook and execute code while an advertisement packet is being sent, a.k.a when the chip consumes the most power?