[APP] Battery Diviner (May 1, 2011 - V1.06)

Search This thread

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
For update information, see bottom of post

Yes, another Battery Time Left-style app. Originally intended to fill in some of the gaps and problems of the current ones out there, it has since expanded in scope. Here are the main features:

General Info
The Battery Diviner learns your patterns over time to generate extremely accurate battery usage predictions. For example, little to no usage while you're asleep, or large usage when you play games during that train ride every Friday...
  • When first installed, it's using a "Level 0" prediction - a simple charge-divided-by-time, so there's something to display
  • After a day has passed, it switches to "Level 1" prediction, only using Level 0 as a fallback if there's missing data. Level 1 is more accurate than Level 0
  • After a week has passed, it switches to "Level 2" prediction, which includes the day of the week in the algorithm. It is the most accurate, and Levels 1 and 0 are only used as fallbacks at this point
There are no profiles/etc to download, and it should work with any Android 1.6 or greater device. Because it examines usage patterns, it should also still work with over/underclocked phones.

It also never stops learning. Once Level 1 and Level 2 reach their limits (7 days and 4 weeks, respectively), they start overwriting their oldest data. That way, it'll adjust over time, in case your schedule changes.

For example, Level 1 is limited to 1 week. Beyond that, it starts to overwrite the data from exactly 1 week previous (that is, the data from 168 hours previously). So after 1 week more, Level 1 is almost completely adjusted to a new schedule. "Almost", because the gaps where the phone is charging or off don't get recorded, and so, not overwritten.

Main Screen
mainscreenscaled.png

The Main Screen is a summary of information, including:
  • Current percentage
  • From the current percent, how long until the battery is empty, and when that is
  • From the current percent, how long until it is charged, and when that is (AC and USB separate, since they charge at different rates)
The charging times include a "to XX%" column. This means it's only predicting up until it's charged to that percent, because data to go higher is missing. It does this instead of extrapolating, because my own phone slows down above about 93%, and usually reports "full" at 97% or 98% - things that can't be predicted if they weren't experienced before.

History Graph
historygraphscaled.png

The history graph shows your usage over the past several days (up to a week), and includes a prediction section to show you exactly what it thinks you're going to be doing. So if the time remaining seems unusually high or low, the graph will show you why the prediction says what it says, and gives you the final decision.

Blue is history, what your battery was actually at. Red is a Level 0 prediction, Yellow is a Level 1 prediction, Green is a Level 2 prediction.
  • To scroll, drag left/right across the graph
  • To zoom, draw left/right across the Zoom section. To the left zooms in.
  • To re-center on "Now", double-tap on the graph. It also re-zooms to 24 hours, but zooming does not affect the offset at all. Exiting and re-entering the graph does the same thing.

Usage Graph
screenshot2small.png

The Usage graph shows you how much your battery is expected to drop by over the course of the week. The drop percentage is per 15 minutes. The graph display has been smoothed, to make more sense visually, but it means that manually doing a prediction using it (as opposed to simply looking at the History graph) might not have the same accuracy.

Red indicates Level 0 data, Yellow for Level 1, and Green for Level 2.

Controls are the same as the History graph.

Why each 15 minutes instead of each hour? A few things:
  • It comes from the precision of the predictions (Notice how discharging time left always ends with 0, 15, 30, or 45 minutes?)
  • It's less than an hour to give more precise information (not only in creating the prediction from the data, but it also affects storing the data)
  • I was considering using 5 minutes, but that part of the data would end up about 3 times as large. 15 seemed like a good compromise

Widget
widgetscropped.png
widgetscropped.png

There are two sizes currently available: 1x1 and 2x1, shown above in the first image. The 1x1 has two styles, shown in the second image.

The May 1 (V1.06) updated has added the options to change what the text is on the widget. Shown in the second image, the two dark widgets have been customized - the one on the left always shows USB charge time, and the one on the right always shows discharge time.


Widget Configuration
widgetconfigscaled.png
widgetconfigtextscaled.png

Sample of what the new Widget Configuration screen looks like.

The preview defaults to the current percent, but you can drag that slider underneath it to see what the widget would look like at any given percent.

Settings
settingsscaled.png

The displays are very customizable, by way of the Setting screen, allowing you to:
  • Completely alter the display of dates and times
  • Change when the widget switches between the different colors (default numbers are 40 and 20; see above)
  • Turn start-at-boot on and off
  • Change colors used in the graphs and the widget
  • Alter settings for the learning algorithms (More coming soon)

Notification Bar
halfsizefullnotificatio.png

  • Icon shows current percentage
  • The pull-down contains the same information that would be on the widget.
  • Selecting the notification opens the Main Screen
  • Settings -> Misc -> Status Bar to enable

Data can be transferred between Free and Full versions (Import/Export in the Help). Destination data gets erased in the process.

Free: http://www.appbrain.com/app/battery-diviner-(free)/com.paklena.batterydiviner.free
iconfree72.png
chart

Full: http://www.appbrain.com/app/battery-diviner-(full)/com.paklena.batterydiviner.full
iconfull72.png
chart


Upcoming Ideas
(But don't hold your breath. I want to do these, but some I don't yet know how, or could end up being a bad idea once testing starts)
  • Statistics screen doesn't currently exist, but here are two ideas:
    *Maximum possible battery life, by identifying the lowest usage pattern.
    *(Suggested in thread) Remaining talk time, remaining idle time, remaining music-playing time, etc... (Requires knowing when each is running, which could cause call-answering delays, or unnecessary battery drain; "might be a bad idea")
  • Alternative widgets. Two additional 1x1 designs have been chosen, there is now a 2x1, and other 2x1 designs are welcome. The pattern seems to be: Dark background, Light background, and iPhone-style. (Coming, slowly)

Misc.
Each day the data is successfully loaded, it creates a copy as a backup, to prevent complete loss of data, should it get corrupted somehow. The backup is automatically restored if there is a problem, and the user notified as to why the previous day is no longer known. This also creates an odd-looking block in the History graph.

Widgets will not work (and will even disappear from the list of widgets) if the app is on the SD Card. According to khaytsus, if instead using Apps2Ext, it will work fine.

Update: May 1, 2011, V1.06
One bugfix: On one user's configuration, Android somehow was reporting 101% battery (And yes, Android was saying the equivalent of "On a 0-100% scale, you're at 101%", so it's not that it uses a 150-scale or something). I don't know what the cause is, but if this ever happens, the Battery Diviner will now treat that new highest value as the scale. It resets any time the app closes.

New feature: Widget Configuration Screen, plus one new 1x1 widget!

The new Configuration screen allows you to change when the bar colors change, what colors, and even how many to use (minimum 2, but they can be set to the same color). There's also a whole bunch of options for the text that gets displayed on the widget. Text options are:
*Static text (once selected, it asks what you want to display)
*Current Percent (The default line 1)
*Time Remaining (Cur) (The default line 2)
*End Time (Cur) (The default line 3)

For Time Remaining and End Time, in addition to "Cur" for "Current", there's also "Discharge", "USB", and "AC", if you want to force it to always display those times instead of whatever the phone is currently doing.
 
Last edited:

dsMA

Senior Member
Jun 4, 2010
427
6
Sacramento
Sounds very cool.

Some of these battery predictor apps that I have tried have asked for my phone's type/model and as such I am assuming that what it is doing is loading a profile specific to the stock specs for what ever phone is picked, but it sounds like this is not the case with your app? I take it instead of relying on predefined profile your app looks at actual battery consumption and thus would take into account users who have their phones over and underclocked?

You mention a free and a full version of the app, what is the difference between these two?

Motalen's battery predictor app had a cool feature in that when you opened the app it would give you estimates on how much time is remaining to do certain activities (making a phone call, watching a video, listening to music, web browsing, etc) have you any plans on implementing something like this?

Finally I just want to note that I am not sure if I am a fan of the widget's design.
 

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
Sounds very cool.
Thanks!

Some of these battery predictor apps that I have tried have asked for my phone's type/model and as such I am assuming that what it is doing is loading a profile specific to the stock specs for what ever phone is picked, but it sounds like this is not the case with your app? I take it instead of relying on predefined profile your app looks at actual battery consumption and thus would take into account users who have their phones over and underclocked?

There are no downloaded/stored profiles for models of phone, so it should work on any Android device. Every time the battery drops (or charges) a percent, the Android OS notifies my app, which takes note of the time and day. It learns from those patterns. This also means that I'm not polling every X minutes, so there is no artificial draining of the battery.

The only assumptions made are that 100% means "full" and 0% means "empty". (And full may not even be assumed, I'd have to check through the code again)

You mention a free and a full version of the app, what is the difference between these two?

I didn't mention it? Ack. I'll edit the first post with more/better information on that, but for now: the Settings screen is limited to "Autostart: Yes/No" in the Free version, while the Full version has a lot more customizations.

In the next version or two, the Free version will allow all settings to be seen, but not changed.

Motalen's battery predictor app had a cool feature in that when you opened the app it would give you estimates on how much time is remaining to do certain activities (making a phone call, watching a video, listening to music, web browsing, etc) have you any plans on implementing something like this?

I was planning on making a Statistics screen, with things such as, the maximum your battery can last, by identifying the time you use it the least, and the minimum it can last, by identifying when it's used the most, and so on. I'll keep this idea in mind, as another addition to the Statistics screen, but would have to think about how to do it well.

Finally I just want to note that I am not sure if I am a fan of the widget's design.

Yeah, it was meant to be reminiscent of Star Trek, just because I'm a fan. I always intended to make a second one (that would look better on lighter backgrounds), but haven't yet thought of anything that I think would look nice. So I'm fully open to suggestions right now.

The three guidelines for the widget, in case someone wants to design one, are: The status bar (visual battery representation), the eye (what app it belongs to), and the 3 lines of text must be on it.

I've considered making those 3 lines of text fully customizable (Say, someone doesn't want the actual percent there), but again, I'd have to think about it how to implement it. (Already have a few ideas ;) )
 

pinhead875

Senior Member
Aug 4, 2010
384
47
I've only had this app installed since yesterday afternoon, but it's very cool. I love how I can view my past battery usage, and I can't wait to see how well the predictions turn out! Great app so far!
 

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
I love how I can view my past battery usage
You just reminded me of a missing setting in the Full version. Planned since day one but never implemented, will go add before the weekend :eek: (History is limited to 7-8 days (midnight split) to save space, Full version should be able to extend/reduce it. History does not affect the learning parts of the app; that is stored separately)

V1.02 Update coming sometime soon (Friday or during weekend). A bunch of updates to the Settings screen, plus now Free users can see all the settings, their defaults, and the help for them, just not modify them.
 

khaytsus

Senior Member
Apr 8, 2008
7,263
1,176
Central Kentucky
Not sure if this is a question or a suggestion....

Curious about the mechanism you use to learn.. Does it learn "once" then use that forever? Like for example normally at work I use it X amount, but one day was light or I was trying a new program, or installing a new ROM (ahem) and used significantly more battery than normal. Does it continue to average, or would that throw it off forever?

I gotta say, the Usage Graphs are not making any sense to me... It shows different green, red, yellow.... At first I thought it was percent of battery used or such, but it doesn't seem to be.. At least not per hour? I average 3-4%/hr with the phone pretty much idle (ie: me not playing with it) running K9 online imap, weather updating, Tasker doing stuff etc... But Diviner is showing 1%.. woah, now it's showing 3-4%, I SWEAR earlier it wasn't going any higher than 1%.. I'll keep an eye on this, maybe I'm just crazy. Nope, not crazy, I just went back into Graph Usage and it's showing 1-2% again. I wouldn't expect this to be something that'd have to stabilize that much over usage, it should know exactly what I've used since I installed it yesterday evening, right?

One question... Why are the Charging Times on the main screen "to 82%" for USB, "to 88%" for AC? Is this an estimate of what I typically (so far) have charged to for each of these?

Now, a suggestion or two.. :) A "Now" button for the graphs, to make it easier to find the most recent real info (vs estimated).

Make the graphs on the main page representative of the real graphs. Not updating in real time or anything, but right now they're just static icons, right?

Fun stuff, look forward to improvements. :)
 

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
Not sure if this is a question or a suggestion....

Curious about the mechanism you use to learn.. Does it learn "once" then use that forever? Like for example normally at work I use it X amount, but one day was light or I was trying a new program, or installing a new ROM (ahem) and used significantly more battery than normal. Does it continue to average, or would that throw it off forever?

It will continue to average it in, to a maximum of whatever the learning length is. For example: Level 1, the day-by-day one that shows up as Yellow on the graphs, limits itself to 1 week. After that, it wraps around and starts to overwrite the oldest data.

So Level 1 limits itself to 1 week. It's almost fully adjusted to a new schedule after that 1 week, slowly changing over the week. "Almost", because the gaps where the phone is charging or off, doesn't get recorded.

Level 2 limits itself to 4 weeks. This one is (will be) changeable in the Settings, minimum of 2 weeks, no maximum. So it will also wrap around and only keep the most recent 4 (or whatever) weeks of data.

I gotta say, the Usage Graphs are not making any sense to me... It shows different green, red, yellow.... At first I thought it was percent of battery used or such, but it doesn't seem to be.. At least not per hour? I average 3-4%/hr with the phone pretty much idle (ie: me not playing with it) running K9 online imap, weather updating, Tasker doing stuff etc... But Diviner is showing 1%.. woah, now it's showing 3-4%, I SWEAR earlier it wasn't going any higher than 1%.. I'll keep an eye on this, maybe I'm just crazy. Nope, not crazy, I just went back into Graph Usage and it's showing 1-2% again. I wouldn't expect this to be something that'd have to stabilize that much over usage, it should know exactly what I've used since I installed it yesterday evening, right?

The colors I'm sure I mentioned somewhere. Red/Yellow/Green indicates the data it has and how accurate it thinks it will be.

Otherwise, your initial guess was right, it is percent of battery used, but it's per 15 minutes, centered on the hour, and smoothed so it makes more sense to humans just perusing the graph (Yeah, sorry, not explained anywhere). Because it's smoothed, manually doing a prediction probably won't give you exactly the same eventual percent as simply looking at the other graph. But I'm not sure.

The 15-minute decision is based on a several things:
*The number is how precise discharging predictions can be. Time left is always 0, 15, 30, or 45 minutes + however many hours.
*It's lower than an hour to give more precise information. (This has to do with how the data is collected, as well as how it displays and is used)¹
*I was considering using 5 minutes, but this part of the data would be about 3 times as large.

Since per-hour is probably more intuitive, I may separate the Usage display from what's actually stored.

¹Also, please note, that this still does not mean any polling. It has to do with the math involved in data collection.

One question... Why are the Charging Times on the main screen "to 82%" for USB, "to 88%" for AC? Is this an estimate of what I typically (so far) have charged to for each of these?
Yes. It doesn't know how long it takes to go higher. :D
(I chose specifically to do it this way because my own phone, at above 93%, starts slowing down, and usually reports "Fully Charged" when it reaches 97% or 98%)

Now, a suggestion or two.. :) A "Now" button for the graphs, to make it easier to find the most recent real info (vs estimated).

Make the graphs on the main page representative of the real graphs. Not updating in real time or anything, but right now they're just static icons, right?

Fun stuff, look forward to improvements. :)
First one: Double-tap on the graph, and zooming doesn't change the offset at all (I'm sure I put this into the in-app help :( ) (Unless that's not what you're suggesting?)

Second one: Static yes, and it's planned, but have to figure out how to do it. Probably won't come for a while..


Keep the questions coming.. It's sometimes hard to tell what is obvious to me and weird to others (Like the Usage graph), because I'm the one making it, so I already understand it all. Your questions will help me fix up the displays and the "Help" section.

EDIT: Looks like I have URL-posting ability now. Yay! Time to work on the OP...
 

ardax

Senior Member
Jul 22, 2010
358
72
This looks really neat.

One thing I'm curious about, is there a way to have the history also show the expected values, so we can see how accurate the app's been? :)
 

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
Just bought the donate version. The text boxes and such in settings are a little off.
Nexus One Miui11.26 No custom density.
Thanks. I'll try to replicate in the emulator, but not sure of how to fix at the moment.

However, I do have a suspicion. If I'm right, the changes I already made to Settings might fix it when it's released this weekend. Please post again when you get V1.02, if you haven't uninstalled it.

EDIT: Thinking about it more, no, it might not fix it, or it might fix only part of the problem. The ? Help buttons are what are making me think not, now... Eh, testing time anyway.

One thing I'm curious about, is there a way to have the history also show the expected values, so we can see how accurate the app's been? :)
Expected from... The previous time it was unplugged? Not at the moment, it would require some pretty big changes/additions. Maybe in Version 2. (Actually, likely in Version 2. I like the idea, but how to display it on the graph is something to think about)
 
Last edited:

overground

Retired Senior Moderator / Inactive Recognized Dev
Thanks. I'll try to replicate in the emulator, but not sure of how to fix at the moment.

However, I do have a suspicion. If I'm right, the changes I already made to Settings might fix it when it's released this weekend. Please post again when you get V1.02, if you haven't uninstalled it.

EDIT: Thinking about it more, no, it might not fix it, or it might fix only part of the problem. The ? Help buttons are what are making me think not, now... Eh, testing time anyway.
Don't you get uninstall / refund notifications from the market? No, I haven't uninstalled it. ;)
 

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
Don't you get uninstall / refund notifications from the market? No, I haven't uninstalled it. ;)
Sorta. The Developer's Console has been out of date for a day and a half or so (Except for ratings, those seem to update whenever), and the merchant area doesn't list usernames :p

Anyway, I think I see what caused the display problem. Some older parts of the code, that I must have missed when cleaning up for public release, were still in there (pixel values instead of WRAP_CONTENT).
 

ardax

Senior Member
Jul 22, 2010
358
72
Expected from... The previous time it was unplugged?
Good question, since your app is constantly (well, regularly, at any rate) updating its usage estimates. From unplug sounds like it'd be good though.

Changing the graphs to simpler lines graphs would take care of the graphing portion -- you'd be able to use the same view to show both what the app said your history should be vs. what it actually turned out to be.

It is quite a bit to chew on though. There might be a way to feed some kind of error information back into your heuristics for better forecasts, if you're not already doing that.
 

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
I'm on a frontpage? Whowhatnow?

Anyway, along with the Version 1.02 update, I'm posing a question here:

I've made 4 mockups in the Gimp and attached them to this post, named widget2 through widget5 (widget1 being the one currently in the app). Any other possible suggestions? Or would you like one of these?

(And yes, I know widget4 is kinda out there. Also, the green and yellow is customizable in the Settings)
 

Attachments

  • widget2.png
    widget2.png
    1.4 KB · Views: 1,084
  • widget3.png
    widget3.png
    1.4 KB · Views: 1,087
  • widget4.png
    widget4.png
    1.5 KB · Views: 1,084
  • widget5.png
    widget5.png
    1.5 KB · Views: 1,086
Last edited:

x潮騒x

Senior Member
Oct 16, 2010
58
1
I've made 4 mockups in the Gimp and attached them to this post, named widget2 through widget5 (widget1 being the one currently in the app). Any other possible suggestions? Or would you like one of these?
To be honest, they all look quite bad to me. What about a neutral version with just text?
 

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
I'd be willing to drop the bar and lines, but I want to keep the eye on there somewhere as an identifying mark. (One of the upcoming graphics upgrades will un-pixelize the eye, so it should look better, too)

(Offer is still open to make your own mockups - image size is 72x72)
 

Coedy

Senior Member
May 29, 2010
502
53
Swansea
www.ignition-images.co.uk
Hi,
Hope you don't mind, I gave a widget a quick go.

The background is the bar (I don't usually pay attention to battery bars as there is one in the notification bar that gives you a good enough guestimate)
Everything widget wise with android is heading that of the Iphone (everything curvy) so just rounded things off. I didnt know font limitations so just chose a plain one (Franklin Gothic this one is).
I dont know anything about android development so dont know whats possible... :eek:

Im not using your app yet but am excited to give it a go! Currently I use JuicePlotter but am getting fed up of my gallery being slowed down by its 'cache' images for the graph (which I dont use). Your app seems clean, simple and no nonsense! :D

One question. If I got the free version, if I upgrade to the full one at a later date will it have to "Re-learn" everything? or will it see the settings stored by the free version?
 

Attachments

  • widget.png
    widget.png
    4.2 KB · Views: 1,056

Izkata

Senior Member
Aug 2, 2010
121
14
Chicago
Hi,
Hope you don't mind, I gave a widget a quick go.

The background is the bar (I don't usually pay attention to battery bars as there is one in the notification bar that gives you a good enough guestimate)
Everything widget wise with android is heading that of the Iphone (everything curvy) so just rounded things off. I didnt know font limitations so just chose a plain one (Franklin Gothic this one is).
I dont know anything about android development so dont know whats possible... :eek:
Hmm... Looks pretty nice. I'll wait and see if there are any other suggestions before making it, though (plus I'd have to figure out the rounded-corners thing for the bar part, but that doesn't seem like it would be too hard. Maybe I'll include a "Hide the progress bar" option eventually)

By default, the font choices are Sans, Serif, and Monospace, with the Bold, Italic, or Bold And Italic modifiers. No clue what the typeface itself is. Custom fonts are certainly supported (as seen in other apps), but I haven't bothered yet. These seem good enough for now.

Im not using your app yet but am excited to give it a go! Currently I use JuicePlotter but am getting fed up of my gallery being slowed down by its 'cache' images for the graph (which I dont use). Your app seems clean, simple and no nonsense! :D
I was surprised myself at how well my graph scrolled, having used JuicePlotter for a while before making this. I mean, mine even is doing a complete redraw (not just scrolling an image) as it's moved.. So no cache files, either ;)

One question. If I got the free version, if I upgrade to the full one at a later date will it have to "Re-learn" everything? or will it see the settings stored by the free version?
If upgrading to Full later, there's an Import/Export section in the Help that can be used. Full and Free versions don't recognize each other, so they can both be safely installed at the same time.

To upgrade, go into the Free version and choose "Export". A file is created on the SD Card called "Battery Diviner Export Data.mag". Then go into the Full version and choose "Import". That file is read, and when successful, deleted.

Import/Export could also be used if you want differently-trained data. For example, if still in school, export at the end of the semester and rename it, then choose Erase in the Help. Retrain over break, then when next semester starts, export that, rename it differently, then move the original back into place and Import it.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 5
    For update information, see bottom of post

    Yes, another Battery Time Left-style app. Originally intended to fill in some of the gaps and problems of the current ones out there, it has since expanded in scope. Here are the main features:

    General Info
    The Battery Diviner learns your patterns over time to generate extremely accurate battery usage predictions. For example, little to no usage while you're asleep, or large usage when you play games during that train ride every Friday...
    • When first installed, it's using a "Level 0" prediction - a simple charge-divided-by-time, so there's something to display
    • After a day has passed, it switches to "Level 1" prediction, only using Level 0 as a fallback if there's missing data. Level 1 is more accurate than Level 0
    • After a week has passed, it switches to "Level 2" prediction, which includes the day of the week in the algorithm. It is the most accurate, and Levels 1 and 0 are only used as fallbacks at this point
    There are no profiles/etc to download, and it should work with any Android 1.6 or greater device. Because it examines usage patterns, it should also still work with over/underclocked phones.

    It also never stops learning. Once Level 1 and Level 2 reach their limits (7 days and 4 weeks, respectively), they start overwriting their oldest data. That way, it'll adjust over time, in case your schedule changes.

    For example, Level 1 is limited to 1 week. Beyond that, it starts to overwrite the data from exactly 1 week previous (that is, the data from 168 hours previously). So after 1 week more, Level 1 is almost completely adjusted to a new schedule. "Almost", because the gaps where the phone is charging or off don't get recorded, and so, not overwritten.

    Main Screen
    mainscreenscaled.png

    The Main Screen is a summary of information, including:
    • Current percentage
    • From the current percent, how long until the battery is empty, and when that is
    • From the current percent, how long until it is charged, and when that is (AC and USB separate, since they charge at different rates)
    The charging times include a "to XX%" column. This means it's only predicting up until it's charged to that percent, because data to go higher is missing. It does this instead of extrapolating, because my own phone slows down above about 93%, and usually reports "full" at 97% or 98% - things that can't be predicted if they weren't experienced before.

    History Graph
    historygraphscaled.png

    The history graph shows your usage over the past several days (up to a week), and includes a prediction section to show you exactly what it thinks you're going to be doing. So if the time remaining seems unusually high or low, the graph will show you why the prediction says what it says, and gives you the final decision.

    Blue is history, what your battery was actually at. Red is a Level 0 prediction, Yellow is a Level 1 prediction, Green is a Level 2 prediction.
    • To scroll, drag left/right across the graph
    • To zoom, draw left/right across the Zoom section. To the left zooms in.
    • To re-center on "Now", double-tap on the graph. It also re-zooms to 24 hours, but zooming does not affect the offset at all. Exiting and re-entering the graph does the same thing.

    Usage Graph
    screenshot2small.png

    The Usage graph shows you how much your battery is expected to drop by over the course of the week. The drop percentage is per 15 minutes. The graph display has been smoothed, to make more sense visually, but it means that manually doing a prediction using it (as opposed to simply looking at the History graph) might not have the same accuracy.

    Red indicates Level 0 data, Yellow for Level 1, and Green for Level 2.

    Controls are the same as the History graph.

    Why each 15 minutes instead of each hour? A few things:
    • It comes from the precision of the predictions (Notice how discharging time left always ends with 0, 15, 30, or 45 minutes?)
    • It's less than an hour to give more precise information (not only in creating the prediction from the data, but it also affects storing the data)
    • I was considering using 5 minutes, but that part of the data would end up about 3 times as large. 15 seemed like a good compromise

    Widget
    widgetscropped.png
    widgetscropped.png

    There are two sizes currently available: 1x1 and 2x1, shown above in the first image. The 1x1 has two styles, shown in the second image.

    The May 1 (V1.06) updated has added the options to change what the text is on the widget. Shown in the second image, the two dark widgets have been customized - the one on the left always shows USB charge time, and the one on the right always shows discharge time.


    Widget Configuration
    widgetconfigscaled.png
    widgetconfigtextscaled.png

    Sample of what the new Widget Configuration screen looks like.

    The preview defaults to the current percent, but you can drag that slider underneath it to see what the widget would look like at any given percent.

    Settings
    settingsscaled.png

    The displays are very customizable, by way of the Setting screen, allowing you to:
    • Completely alter the display of dates and times
    • Change when the widget switches between the different colors (default numbers are 40 and 20; see above)
    • Turn start-at-boot on and off
    • Change colors used in the graphs and the widget
    • Alter settings for the learning algorithms (More coming soon)

    Notification Bar
    halfsizefullnotificatio.png

    • Icon shows current percentage
    • The pull-down contains the same information that would be on the widget.
    • Selecting the notification opens the Main Screen
    • Settings -> Misc -> Status Bar to enable

    Data can be transferred between Free and Full versions (Import/Export in the Help). Destination data gets erased in the process.

    Free: http://www.appbrain.com/app/battery-diviner-(free)/com.paklena.batterydiviner.free
    iconfree72.png
    chart

    Full: http://www.appbrain.com/app/battery-diviner-(full)/com.paklena.batterydiviner.full
    iconfull72.png
    chart


    Upcoming Ideas
    (But don't hold your breath. I want to do these, but some I don't yet know how, or could end up being a bad idea once testing starts)
    • Statistics screen doesn't currently exist, but here are two ideas:
      *Maximum possible battery life, by identifying the lowest usage pattern.
      *(Suggested in thread) Remaining talk time, remaining idle time, remaining music-playing time, etc... (Requires knowing when each is running, which could cause call-answering delays, or unnecessary battery drain; "might be a bad idea")
    • Alternative widgets. Two additional 1x1 designs have been chosen, there is now a 2x1, and other 2x1 designs are welcome. The pattern seems to be: Dark background, Light background, and iPhone-style. (Coming, slowly)

    Misc.
    Each day the data is successfully loaded, it creates a copy as a backup, to prevent complete loss of data, should it get corrupted somehow. The backup is automatically restored if there is a problem, and the user notified as to why the previous day is no longer known. This also creates an odd-looking block in the History graph.

    Widgets will not work (and will even disappear from the list of widgets) if the app is on the SD Card. According to khaytsus, if instead using Apps2Ext, it will work fine.

    Update: May 1, 2011, V1.06
    One bugfix: On one user's configuration, Android somehow was reporting 101% battery (And yes, Android was saying the equivalent of "On a 0-100% scale, you're at 101%", so it's not that it uses a 150-scale or something). I don't know what the cause is, but if this ever happens, the Battery Diviner will now treat that new highest value as the scale. It resets any time the app closes.

    New feature: Widget Configuration Screen, plus one new 1x1 widget!

    The new Configuration screen allows you to change when the bar colors change, what colors, and even how many to use (minimum 2, but they can be set to the same color). There's also a whole bunch of options for the text that gets displayed on the widget. Text options are:
    *Static text (once selected, it asks what you want to display)
    *Current Percent (The default line 1)
    *Time Remaining (Cur) (The default line 2)
    *End Time (Cur) (The default line 3)

    For Time Remaining and End Time, in addition to "Cur" for "Current", there's also "Discharge", "USB", and "AC", if you want to force it to always display those times instead of whatever the phone is currently doing.
    1
    I seem to have a bit of a problem with this for the history displayed. It seems to suddenly make the history horizontal from a point, despite the history being tracked as I check it during the day (i.e. I will go to look at it to see what happened in the last 24hours, and notice that previously it was fine, and then would have the blue across well past the point of charging or discharging. Please see the following attachment, notice the approx 65% horizontal line? This was actually a full discharge/charge cycle in there (yes, my battery life is garbage, typically 9 to 12hours, Samsung Galaxy S Froyo). And notice the 100% charge, it was discharging actually from about 11pm there, but that has it at 100% till 9am, when previously I checked it today and it was fine.
    Erk. I can think of 3 possibilities:

    *If it was disabled for a while, or the phone off, the last-known value will be stretched like that. Not the case here, as you said it was working fine in the middle of that block-period.
    *The data wasn't being saved during that period, just held in memory. The next time you looked at the Main screen or a graph, it would load the memory and erase the recent data. Shouldn't be the case, as it's supposed to save every time something new happens.
    *The data file got messed up somehow, and couldn't be loaded. Each day, when the data is successfully loaded, a backup is made. If it couldn't load the data and instead when for the backup, this is what happens. There should have been a popup at some point, though, explaining why data is missing...

    If you go into Help and Export, can you email me the file? "Battery Diviner Export Data.mag", on the SD card. I don't know what the problem is, but there might be a clue in there...

    An idea that might mean the second possibility in some roundabout way: Did you create a shortcut to one of the graphs, skipping the Main screen? Someone appears to have tried it, which caused a force-close and an error to get reported to me. I wasn't able to duplicate it (LauncherPro wouldn't let me do that for some reason), so I don't know if I fixed it.

    Yes, moving any app with a widget to the SD card using the Froyo Apps2SD method will break widgets at some point, certainly at reboot time. Moving it back to internal storage and rebooting will fix it. Probably restarting the VM will as well.

    It however works just fine with Apps2Ext. :)
    Thanks! I'll update the main post tonight/tomorrow when I do the next update.
    1
    Version 1.03 Update!

    *Several bug fixes (Yeah, there was more than just Month being off. Shhh, don't tell anyone.. ;) )
    *A few small graphics upgrades
    *Added a 2x1 light widget!
    *Full version has a real color picker instead of a list of predefined colors! (AmbilWarna library, if anyone wants to know)
    *Many internal widget changes in preparation for the big one.

    That last bullet, unfortunately, means RE-ADD YOUR WIDGETS. They will not work until you do!

    (EDIT2: Main post updated)


    EDIT:
    maybe you can put a battery usage graph on the widget, just a suggestion.

    It will be good if your app show battery usage link or graph for apps. x = the percentage of power that the apps use and y = the apps name.
    Never even considered something like that for the widget. Don't really see how helpful it would be, so small, unless I made a 2x2 or 3x3 widget or something. I might look at the idea.

    Not sure what you mean on the second one... There's a built-in usage thingy, accessible in the Settings -> About Phone -> Battery use.
    1
    Does the level 2 mode just use information of the particular weekday or is there some sort of supervised learning to learn eg. weights for a linear combination of different templates (like level 2&3)?
    Once it has enough data, yeah, it is just for that weekday. If there is data for a weekday, but not much (Like, just one week), it does a straight averaging of Level 1 and 2.

    I've taken a data mining course a year ago, and it's given me ideas that might manage to make this even more accurate (for example, noticing a pattern that, if it happens in the morning, alters the rest of the day. Like a day off of work, and a large drop when you're on the train isn't there that day, so it would treat that weekday like the weekend). But however much I want to do this, I instead went for keeping it simple. Training would cause extra battery drain (unless it only happened after starting charging.. hmm), make the phone work reeaally slooowly while training, and it would require -tons- of testing to see that it doesn't mess up and make the predictions go waaay off.

    Im just asking as i think the idea of this application is really good and works better than everything else but level 2 doesnt seem to give me so promising results. That wouldnt be surprising as data is way too noisy and sparse if its just for particular weekdays - at least for my life.
    Mmk, that gives me reason to add something I was considering: The ability to enable/disable Level 2 in the settings. Maybe even enable/disable Level 1, although I don't think it would be too useful, more just for kicks ;)

    Though, it stores 4 weeks by default so that fluctuations from week-to-week like that wouldn't mess with the predictions very much. We're just approaching 3 weeks total on the market (dunno when you installed it), so I'll put the enable/disable on the "upcoming" list, and if you're still having issues like that around New Year's, I'll bump it up. Like notifications, it shouldn't take very much to do, but right now I'm focusing on the widgets.
    1
    V1.04 - Minor bugfix release.

    In the last update something I did made the History graph act a bit funny, if the current battery stretches past where the prediction sees a drop.

    Usage graph has a bit more explanation in the Help.

    Clean up on the Main Screen - columns are now aligned.

    No new features.
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone