Adjust RP2040 ADC Vref constant to make battery voltage more accurate

Merged Jakub Vaněk requested to merge bugfix/vbatt into main

My brick was previously under-reporting the measured voltage. To investigate this, I have probed some pads on the PCB with a multimeter and got these results:

battery voltage    ... 8.25 V
voltage at ADC pin ... 2.06 V (OK, voltage is correctly divided by 4)
ADC ref. voltage   ... 3.2 V
ADC measurement    ... 42122 (OK, range is uint16_t, this result corresponds to cca. 2.06 V)

This PR updates the constant to reflect this. However, I'm a bit concerned about the old ADC ref = 3.05 V value - is that one correct for the other brick?

Edited by Jakub Vaněk

Merge request reports