A very simple and much required API addition in Windows Phone 8 which allows you to retrieve Battery related information. Here’s what this API expose,
- Identify remaining battery percentage
- Discharge time
- An event that triggers when battery percentage drops by 1%
Battery class is contained within namespace Windows.Phone.Devices.Power
Here’s how you can identify remaining battery percentage,
Note that this feature wasn’t supported in Windows Phone 7.5 earlier and makes a comprehensive addition to WP8 SDK.
(With above article in place, we are rolling a new strategy to share a concise article on weekend to keep the tech. guys up and running)