On Sun, Jan 11, 2009 at 11:21 PM, [email protected] <[email protected]>wrote:

> How about reading on the capacity of battery via 'dumpsys battery'?


This is not part of the SDK, and you can count on the format of the debug
output printed there to change arbitrarily across releases.

The current battery level is sent out in the broadcast
ACTION_BATTERY_CHANGED:

http://code.google.com/android/reference/android/content/Intent.html#ACTION_BATTERY_CHANGED

I believe this is a sticky broadcast so you can retrieve the current values
without waiting for the next broadcast.

-- 
Dianne Hackborn
Android framework engineer
[email protected]

Note: please don't send private questions to me, as I don't have time to
provide private support.  All such questions should be posted on public
forums, where I and others can see and answer them.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to