Battery reporting, still a problem in 2018

Battery devices have a couple of issues. One is that different devices have different thresholds (see the first post of the link for details). Example some locks die at 50% while others die at 10%
Some low power devices go on till 0% and still keep functioning while others die around 25%. There are lots of reasons behind this starting from device incorrectly measuring and reporting battery levels (firmware issues) to different types of batteries with different voltage curves. I had published a couple of posts around on this issue and how to tackle it as well as how to select batteries. Mismatching batteries to devices can be problematic also, e.g if the firmware has been designed to measure alkaline battery discharge curves then using a lithium ion or a nickel metal hydride battery in those devices will create havoc with the battery reporting.

The second issue is battery defects. Sometimes this drop voltages more precipitously than normal batteries would which lead to a sudden shut down of the device leaving with you the last known battery in your case 22%.

A good way to handle this is to create individual monitoring of battery levels for your device and creating custom notifications based on what % you battery is likely to die.

If you have access to RBoy apps check out this app and the first post