-
- Downloads
device-nokia-n900: implement udev-based battery monitoring (MR 5868)
The bq27200 fuel gauge depends on its battery-backed memory for capacity reporting. If the supply is off for some time, the fuel gauge's last known capacity is reset, after which a capacity value can only be read after a full charge cycle. Thus, most of the time, as used on the Nokia N900, the reported percentage cannot be relied on for making power-off decisions on battery low conditions, e.g. through UPower. However the fuel gauge can very accurately detect and report a low battery condition internally, even if the reported capacity is incorrect, e.g. when it has been reset. The low battery condition is reported by the kernel via capacity_level in sysfs, and also generates uevents. So we can implement safe battery shutdown by requesting the kernel to more regularly polling for status changes, then performing an immediate shutdown when the capacity_level is reported as Low and the device is not charging.
Showing
- device/community/device-nokia-n900/APKBUILD 13 additions, 1 deletiondevice/community/device-nokia-n900/APKBUILD
- device/community/device-nokia-n900/bq27k-monitor.sh 16 additions, 0 deletionsdevice/community/device-nokia-n900/bq27k-monitor.sh
- device/community/device-nokia-n900/bq27k-options.conf 1 addition, 0 deletionsdevice/community/device-nokia-n900/bq27k-options.conf
- device/community/device-nokia-n900/udev/15-bq27k.rules 1 addition, 0 deletionsdevice/community/device-nokia-n900/udev/15-bq27k.rules