# Voltage Divider - Arduino Pro Mini 3.3V - Smartphone Battery (4.2V max) - which resistance values?

I want to measure the battery voltage on my arduino pro mini (3.3V version), which runs from a Li-ion smartphone battery (max 4.2V).

I used the typical voltage divider setup with R1 = 5.6M and R2 = 2M, because of this formula:

// ((R1+R2)/R2)*1.1 = Vmax = 4.2 Volts // 4.2/1023 = Volts per bit = 0.004105572 float batteryV = sensorValue * 0.004105572; int batteryPcnt = sensorValue / 10;

But it doesn't seem to work.. currently it is giving me a voltage of 1.28V, but my multimeter is measuring 3.86V.

What am I doing wrong?

• Start with smallest value not over 100k and see how it works. ADC bias current and input offset current flowing in equivalent input resistance of the divider want to produce a voltage rather less than 1 LSB of the ADC. Look up the current values, calculate the voltage of 1 LSB. Go... – Russell McMahon Apr 8 '16 at 15:09
• It's all about reading the small (but very important) print in the data sheet – Andy aka Apr 8 '16 at 15:12