If charger is connected and battery capacity is 0, charging animation should
run. The device would be booted up even if capacity is 0 in off-mode charging.
At that time, it would take some time to be 1 from 0 for capacity if you
use USB charger.
Bug: 17606689
Change-Id: I37e0f1b6ab0ee1f6d833882e169bf3ea06cf2399
Logic for this check was inadvertently reversed when porting this from
the charger daemon to healthd. Request suspend if a charegr is connected,
else stay out of suspend waiting for a charger connect or power off if
none.
Bug: 17112463
Change-Id: Iffdb6dbcd0d0a2a614ff8f50bf5f2e22e1ad552f
connected to fake battery.
Detects if the device is attached to a fake battery if yes, healthd
reports 42% battery charge and 42.2 degrees temperature.
Change-Id: I2508fd91c8d3848ea64f57ab59d20be1c2817913
At present, charging animation runs irrespective of whether charger is
connected or not. When the charger is disconnected, device does not
shutdown for 10sec. Charger animation during this period should be
avoided.
Change-Id: I34dc5028522ca199d50a1a1b684b035b2d81ef68
setprop persist.sys.battery.capacity 77
setprop persist.sys.battery.temperature 123
and reboot to cause a fixed battery level of 77% and temperature of 12.3C
to be reported to Android.
Typically used on power evaluation boards without batteries connected.
Bug: 14839868
Change-Id: Ibae5e16429d05891cb0787d74a2fe93b07013699
The minui library has changed to no longer use libpixelflinger. It
also offers a more efficient way of storing and loading frames of
animation; use it to represent the battery-full state images.
Also removes the unused battery_charge.png image.
Bug: 12131110
Change-Id: I6cc8b19f36a806c99cda30cc47b5968daf6b333b
* Replace unnecessary warnings about missing attributes with a more
informative message when no battery devices provided by the system.
* Turn off periodic battery checks when no battery devices (thereby
reducing unnecessary kernel log spam).
* Replace battery properties in log messages with a more informative
message when no battery is provided or the battery is removed.
Change-Id: I68a514aa7315ae2b5d22cb8861d3c9b1b38035a1
Previously because /sbin/healthd does not exist on the build host, make
always tries to rebuild the symlink even in an already-up-to-date tree.
Change-Id: I41201282281476b14eaf4c7d9b2e09fe367c1422
* Add healthd charger mode ops
* Check for executable invocation as "charger", set charger mode if so
* Incorporate charger executable as healthd charger mode
Change-Id: I4a44e7a4c3a65ae9be94491f7f498aa48d4f8a84
* add ops for different "modes" of healthd operation: android vs. recovery
* recovery mode selected by runstring options -r
* binder/Android communication moved to android mode
* recovery mode ops avoiding binder service registration
* "no service manager" flag removed; now handled by android vs. other modes
Change-Id: I3d8c89bf96a18a6a00cc85306f9a07d3f408f2a0
Make it easier to later separate out binder-related code.
Add helper functions healthd_battery_update(), healthd_get_property() to
allow these operations without needing references to the BatteryMonitor
object.
Change-Id: Ie584bf53e5178ce0a098d0d940d6c311fdff62d4
Adding support for batteryChargeCounter and batteryCurrentNow as parameters
likely to be useful for power consumption analysis.
Change-Id: Ib23b05d3c31c22ece0d21e55cc481c1b5dabe59e
Allow health HAL to select specific paths to be used, overriding
default search for arbitrary power supplies with the named paths.
Change-Id: I5f724739f58ef56087ab592b7403fc083db8f173
uA and uAh units are converted to mA and mAh.
If current_now is present, add it to the heartbeat log (c=nnn).
Change-Id: I2b5fe7b4505c98ca2d11c3f94564c1c38493c8b9
Initially moving battery health monitoring here.
Command line flag -n tells healthd not to use (or wait for) servicemanager
in this execution, for charger and recovery modes.
Change-Id: I1720594724af0c068497b359f9c6ad65aeaa1519