Ccna final exam - java, php, javascript, ios, cshap all in one. This is a collaboratively edited question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.
Sunday, January 15, 2012
Get last battery charge date time from BatterManager
How do I get the last charge date/time from Android BatteryManager? Well maybe it's not BatteryManager but some other API to use for this.
I want to display something like "Charged 2 hours ago".
Register a broadcast reciever for ACTION_POWER_DISCONNECTED intent and then you could store the time at which power was disconnected.
ReplyDelete