Inkplate 5 battery voltage measurement returns incorrect values

Customer:

I’m trying to measure the battery voltage of my Inkplate 5 from ESPHome and getting a value of ~0.87V instead of the ~4.1V I measure at the contact pads. I saw I can adjust multipliers and attenuation, but the measured value is so far off that I suspect I’m doing something wrong. Below is the ESPHome yaml block that produces this behavior. Any suggestions?

Originally submitted via email support on 2 July 2025. Migrated to the forum for community visibility.

Soldered Support:

For Inkplate 5 (regular Inkplate 5, not Inkplate 5V2), the pin for measuring battery voltage is IO35. Make sure you’re measuring that with the ADC and you should get the correct battery voltage. Before measuring, you have to write LOW to internal GPIO expander pin 9 to enable the battery voltage measurement circuit. This is done in the function linked in the original message. If LOW doesn’t work, try writing HIGH before measuring with the ADC.

Attachment omitted in migration: image.png

Attachment omitted in migration: image.png

Customer:

That worked. I have one other question – is there a way to detect whether or not the device is plugged in and/or charging? Right now I’m just checking if the measured voltage is over 4.2V, but that feels fragile.

Attachment omitted in migration: image.png

Attachment omitted in migration: image.png

Soldered Support:

Unfortunately it’s not possible to detect this on current HW versions of Inkplate in an absolute way. You can estimate it via voltage like you said. If you want to dig deeper, you can probably make some sort of addition to the schematic via hardware to read via a GPIO pin whether the device is plugged in or not.