I'm trying to track the battery charge level of a couple of iPads used as Home Assistant control panels, so I can turn the charger on and off with an automation and maximise battery life.
Major problem trying to achieve that, but one of the bizarre issues I am seeing is the actual battery level being reported.
The HA companion app is hopeless at this, but can be made to update its sensors with Shortcuts on the iPad itself. I am also running the iCloud Integration which also reports battery level and then of course there is the actual iPad screen that shows battery level in the top right hand corner.
AND ALL 3 ARE DIFFERENT.
Just a minute ago I noticed that the iPad was down to 5% as shown on its screen and a dialog then popped up to say "low power etc.".
Meanwhile the HA app shows a steady 38% and the iCloud Integration was showing 40%, both having updated just 2 minutes before.
How can there be such a variation?
It's not just down to update time. I have watched the HA and iCloud reported level drop over time (iPad charger off) and one method can update and report a higher level then the other did a few minutes previously. So the difference CANNOT simply be a different time of sampling the level.
Seems to me the iPad should compute the battery level and update its screen and HA app and iCloud Integration just grab that. So a simultaneous update of the 2 remote mechanisms should both agree with the device itself, but this is far from the case.
What on earth are these Integrations doing that means they report different values than the device itself is showing. Only one of them can possibly be correct so I'm assuming they both are incorrect. Usually the difference is only a few degrees and my automation can cope with that, but this latest fiasco breaks everything I try in order to prevent the battery going flat.
So the question is, how can these 3 mechanisms of reporting the iPad battery level be different. At all, let alone the massive discrepancy recently exposed?