yashsingh1/xdaforums huggingface dataset:
[BetterBatteryStats] Karpfenhai:
Hey there, for 7 hours, your dump looks not to bad:

Awake (): 15 m 22 s (922 s) Ratio: 3.7%

Screen On (): 2 m 36 s (156 s) Ratio: 0.6%

Your Phone was kept awake by the following process / app:

"modem_usb_gpio_wake" (): 6 m 59 s (419 s) Cnt:(c/wc/ec)519/74/520 1.7%

"modem_usb_suspend_block" (): 4 m 44 s (284 s) Cnt:(c/wc/ec)556/0/0 1.1%

This seems to be traffic related, have you enabled network location?

Most probably caused by:

com.google.android.apps.maps (): Wakeups: 80

com.google.android.location (): Wakeups: 78

i would also keep an eye on this behavior here:

EntriesRefresh_wakelock (com.google.android.googlequicksearchbox.Google Search): 2 s (2 s) Count:87 0.2%

(com.google.android.googlequicksearchbox.Google Search): 1 s (1 s) Count:94 0.1%

Maybe you can adjust the google searchsettings to behave, otherwise, freeze it if not urgently needed.

Now its up to you... my recommendation, disable all location based services and adjust maps (#3)

Good luck!
[BetterBatteryStats] chamonix:
I was bored in the train this morning and implemented a tabbed pager with 3 tabs for package info, perms and services.

Will be in next RC being uploaded tonight as I have a pretty busy day at work today
[BetterBatteryStats] Greedyfly:
Hi there Cyb0rg. I didn't get back to you about your analysis last time out and as I had a big question I thought I'd revisit it.

The question I had was about 'BatteryMonitor' wakelock. You stated I should disable my battery monitoring widgets....However the only program I have monitoring battery is BBS. Therefore if I want to reduce this wakelock what do I need to do?
[BetterBatteryStats] headcrab777:
Thank you for your answer!

>>Have you checked your favorite ROM/Kernel thread for similar experiences?

Yes I checked but no one has that problem...

>>are there any public kernel sources we could check?

I tried different kernels which is included in CyanogenMod for zte blade (cm-7.2, 7.1, 7.0.3)

>>have you tried different radio versions?

Yes, i tried to change Radio from Gen2 to Gen3 and it does not helps

>>You also may want to enable the root features (advanced prefs) so we can see alarms and network traffic

I activated root features in advanced prefs before logging. But alarms and traffic lists are clear. Maybe it is because system is clear (without programs installed) and I do not use network traffic.
[BetterBatteryStats] AllSeeyinEye:
Installed V1.11 RC2 (previous version was 1.10.5). Works fine. There is however an annoying green line between the stats. See screenshot below.
[BetterBatteryStats] Karpfenhai:
MUHAHAH!! You made my day!!! :D:cyclops::laugh::cool:

Sorry .. thats the new famous delimeter..

as i said, fancy grey would suit better.. ;)
[BetterBatteryStats] GoJo ^^:
Mein problem seems to be solved, it was.. EX tweaks making trouble..! Now I'm back to the -1.4% per hour rate, which is still bad but apparently normal for this phone...
[BetterBatteryStats] Karpfenhai:
Glad you found it! Hope it was not the performance governor..

Now we are looking forward to your next dump, maybe we can now narrow down your "normal" wl's.

@Sven, bad news..

File is there and well filled...

But after fullycharge and unplugging..
[BetterBatteryStats] kvv515kvv:
hi everybody!

Could you please look at my bat.stat.

i do not understeand, what is my phone doing for 43 min during the night.

and what can i do to fix this.

Thanks.
[BetterBatteryStats] kevindd992002:
What is a delimiter?

And also, how can I determine if my live wallpaper was developed good and doesn't consume too much battery?
[BetterBatteryStats] It_ler:
A delimiter is a separator ... something that separates different things (texts/values/etc.) for better readablility in this case.

A black/dark wallpaper comsumes less battery on OLED displays than a white/bright one.
[BetterBatteryStats] Karpfenhai:
Setup the Wallpaper, take a dump 2 hours later, disable wallpaper, take another dump, check the differences..
[BetterBatteryStats] kevindd992002:
Thanks for the tip.

Ok, will do that.
[BetterBatteryStats] Greedyfly:
Ok I have reduced a lot of the above wakelocks with help from a few on here however, the above bold items are still causing wakelocks.

I am waiting to see the results of pulling out my battery on l2-hsic so will wait on that. However Battery Monitor (I don't have any battery monitoring apps or use any widgets) and Alarm RTC continue to baffle. And the content available on these looks very random.

please help.
[BetterBatteryStats] AllSeeyinEye:
A separator

A line between different options

A mark that distinguishes two objects
[BetterBatteryStats] desireboss:
I have some Kernel wakelocks on my sgs3 that I can't find anything about they are named mhl_wake_lock and hostd. They both are keeping the device awake around 75% so currently it shows 4 hours since unplugged and 3 hours wake lock for both processes. It's noticeably draining the battery.. any ideas?
[BetterBatteryStats] eirikrwu:
Looks like a really useful tool to find out what is really eating my battery. Trying it out right now, thank you!
[BetterBatteryStats] sbk_hbk:
App names instead of "Alarm Manager"

Indeed its really a wonderful app.

I have just one request; all the wakelock causing apps are named with "Alarm Manager"; but today we don't have an option to check in the same tool what are all the apps causing wakelock.

Am afraid, if we really got another way to check in the same app the apps that cause wakelock.
[BetterBatteryStats] Tungstwenty:
let me try to explain it's something that helps you distinguish when there are many things being shown at once where one of them ends and the next one starts imagine that when you write a sentence such as this one you had nothing to help the reader organize the several blocks of information in is head it would be a mess right luckily there are things like punctuation marks punctuation marks do in sentences something similar to what the delimiter that sven inserted does on the lists it helps you better visualize where one thing ends and the next one starts

:laugh:
[BetterBatteryStats] alexinna:
Testing 1.10RC2

I fully charged my phone overnight. Now when I check BBS I see:

Deep Sleep (): (-46098 s) Ratio: 100.0%
Awake (): (-46098 s) Ratio: 100.0%
Screen On (): (-46098 s) Ratio: 100.0%

and since is 0 in a dump (screen shows correct value). Dump and logcat attached.

Edit: I do see deep sleep time in CPU section and I think value is correct:

Deep Sleep (): 2 h 49 m 28 s 97.6%

Is it coming from different place?
[BetterBatteryStats] alexinna:
If you are rooted look at Alarms section that will list apps.
[BetterBatteryStats] GoJo ^^:
Everything might not be solved... The device crashed, had to force reboot extweaks issues are back... What the Greek is wrong with this app..?
[BetterBatteryStats] Vahooli:
i searched but i cant find really correct answer...

some times (not always) my networkstats in partial awake get high and high and eat my battery !! what is this ? can anyone help me ? :) (while wifi and data are off )
[BetterBatteryStats] alexinna:
Please provide dump file as described in post #1.
[BetterBatteryStats] chamonix:
Wlan_rx_wake is I believe part of what is causing the second. Rationale: at each wakeup the battery gauge gets updated so avoiding the wakeup would avoid the update.

To get rid of rx_wake:

A) turn wifi off when you are not using it

B) if you are exclusively in an environment (access points) that you control you could try to pin the source and remove it

After that do a next round and provide a dump so we can see where you stand
[BetterBatteryStats] chamonix:
With AlarmManager it's simple as long as you are rooted, same for data traffic. But there is not always a 1:1 mapping and as we can only measure the effect the cause is not always straight forward. It's like medicine, it's about know how and experience, in one word about engineering.

But seriously, that is fun isn't it?

Edit: a prod of mine once said: an engineer is the guy who knows in what book to look for the right and detailed answer
[BetterBatteryStats] chamonix:
*vogelzeich* :P
[BetterBatteryStats] alexinna:
Agree :good:

Edit: But BBS is used by ordinary people as well so it should be user friendly as much as possible. I still remember when I found this app some time ago I refused to spend time and understand all provided information. :)
[BetterBatteryStats] chamonix:
OK I will have a look at that case in the code as I saw the same error with a logcat. At unplug with full charge to references are written at once so there may be something related to that causing the reference to get flushed out of memory, or a typo. I hope I can find something by reading because my battery is pretty empty after a heavy usage day. I will keep the next RC back in the hope that I find something to test fast enough to include a fix. If not I will release anyway with a mention to this issue
[BetterBatteryStats] chamonix:
I think you are spot on, your observation suggests a mix up due to saving two refs in one event and overwriting the internal state used to subtract the current values from. More tonight
[BetterBatteryStats] kingofcomedy:
The battery-lifetime of my nexus 7 is not really good (about 48 hours with little usage), but I can't see anything bad in bbs.
[BetterBatteryStats] kmetek:
fuel_alerted whats that? :D
[BetterBatteryStats] xelra:
I just came around and finally bought your app from the p(l)ay store.

I think it's too cheap. Also there's no in app payment method that let's me donate more money later for continuous development and support. You should really add that.

P.S.: Guys, please stop the noob bashing about the delimiter. ;)
[BetterBatteryStats] kmetek:
nice info

http://www.kreativegeek.com/2012/06/android-tipsmanage-your-android-battery.html
[BetterBatteryStats] Karpfenhai:
Rc2 is showing values right after unplugging.

Lets see what happens after a full charge cycle.

Thx Sven!

Tapatalked from my Samsung GT9100

---------- Post added at 10:54 PM ---------- Previous post was at 10:50 PM ----------

Your dump looks weird, it seems you have been connected to a charger while taking the dump?

Please read post #3 how to produce a certain dump and post another one, no screens needed, thx.

Tapatalked from my Samsung GT9100
[BetterBatteryStats] kingofcomedy:
No, it has not been connected to a charger while I took my first dump. :)

I have attached another dump which I just took after I removed the charger (I connected it some mins AFTER the first dump ;)).
[BetterBatteryStats] chamonix:
This is what happens after the refs were saved (correct):

D/Misc (19334): Substracting Deep Sleep 2 d 3 h 42 m 4 s (186124 s) in 15 h 41 m 51 s (56511 s) Ratio: 329.4% from Deep Sleep 2 d 3 h 42 m 4 s (186124 s) in 15 h 41 m 51 s (56511 s) Ratio: 329.4%

This is where is problem starts:

D/Misc (19334): Substracting Deep Sleep 2 d 3 h 42 m 4 s (186124 s) in 15 h 41 m 51 s (56511 s) Ratio: 329.4% from Deep Sleep 2 d 3 h 42 m 4 s (186124 s) in 10 s

The deep sleep value has not changed what is logical assuming the phone did not sleep yet. But the runtime (the 10s) is wrong. It looks like something happens when the charge goes to 100%, resetting the counters. From that moment on the runtime (and not the absolute values) is borked and of course gets propagated from ref to ref.

I use getBatteryRealtime (internal api) and will give it a try with computeBatteryUptime as the latter seem to be taking full charged cycle into account (the first obviously resets at unplug after 100% charged).

Keep your fingers crossed!
[BetterBatteryStats] alexinna:
I was always under impression that after phone fully charged it will be unplugged so all calculations should start from "0" again because my reference point is "since unplugged".

Is this something new? As per your previous explanation you are trying to go back to 1.9.x calculations and I don't remember ever having such issues there. I hope you will get to bottom of this issue soon.

---------- Post added at 10:47 PM ---------- Previous post was at 10:35 PM ----------

Still this is not a correct dump. First of all it's too short (about 16s). You need to plug/unplug phone and leave it for 1-4h and then create dump.
[BetterBatteryStats] chamonix:
No you are prefectly right, and this problem was not present back in 1.9.

The main reason why I can not revert the whole code is that the batteryinfo service also has some kind of references "since unplugged", "since charged" but no "custom" and no "since boot". Additionally this is depending on the SDK version, e.g. Froyo has completely different "internal" references compared to other Android version.

Of course I don't want to go back to all this handling because it means a lot of code. The strategy I follow is to manage the refs all by myself and always substract the "current" value" from these refs.

And here begin the problem: as we have seen the "current" value do not always increase (what whould have been my expectation), leading to "current values" being < "reference values".

To sum it up: the need for having maintainable code prevents me to revert completely to 1.9 computations (to give you an idea the code from 1.9 was 3 times the current code) or at least leads me to try to avoid blowing up the code again as long as I can. This is why I must torture you with versions trying to mimic the old code while being simpler ;)
[BetterBatteryStats] mohsenking:
I install BBS but i didn't undrestand what it mean :

Please help
[BetterBatteryStats] chamonix:
It's not as complicated as it may seem. I suggest you start by reading post #3
[BetterBatteryStats] chamonix:
Release 1.11RC3

I promised a release tonight so here it is.... unfortunately there is no fix for the negative values after full charge. I have an idea but didn't want to fix blindly so I will wait till by battery gets charged to see if the new counter I chose does what I expect.

There are a few new things anyway so have fun
[BetterBatteryStats] alexinna:
Here we go:

I'm pretty sure more people would benefit from BBS if it would present information in more understandable format. I think it was started as tool for advanced users but it's probably time to open doors for ordinary Android users. Unless it's not your goal. ;)

I think that confusion starts from the purpose of the application. People know battery monitors and some tools that promise battery saving but just stats idea somehow confusing. If this is something you are interested please let us know and maybe together we can provide better user experience. I'm not saying we are not doing it already but I think we have more room for improvement. :)
[BetterBatteryStats] koricua74:
Please take a look...

Could someone take a look my logcat and dump file to give me some pointers on how to improve battery life? It's a Sprint G'Nex, running CNA 3.5, with franco's #251 kernel. TIA
[BetterBatteryStats] alexinna:
You should start from usual suspects location services/maps (read post #3). Also I see that you are using Wi-Fi and keep it on:

"wlan_rx_wake" (): 12 m 55 s (775 s) Cnt:(c/wc/ec)754/0/754 2.0%
"wlan_ctrl_wake" (): 1 m 35 s (95 s) Cnt:(c/wc/ec)171/0/171 0.2%

I would recommend to only keep it on when needed to minimize above wakelocks. Next wakelocks related to network traffic probably when apps such as yahoo mail, maps and so on refresh:

"modem_usb_gpio_wake" (): 30 m 24 s (1824 s) Cnt:(c/wc/ec)2253/1119/2254 4.6%
"modem_usb_suspend_block" (): 20 m 10 s (1210 s) Cnt:(c/wc/ec)2457/0/0 3.1%

maybe you can check in your ROM thread for recommendations. Google wallet is also waking up your phone. Is it possible to change refresh behavior? Please follow suggestions and post new dump but disable Bluetooth this time and keep it on only as needed.

---------- Post added at 03:00 AM ---------- Previous post was at 02:51 AM ----------

I see that you are rooted so if you provide Alarm and Network stats it will be nice. Just enable them in Advance menu.

BTW Bluetooth was On all the time. Do you really needed?

So far I see that majority of wake time is from kernel wakelocks:

"multipdp" (): 22 m 15 s (1335 s) Cnt:(c/wc/ec)196/0/197 4.9%
"secril_fd-interface" (): 16 m 43 s (1003 s) Cnt:(c/wc/ec)216/0/0 3.7%
"l2_hsic" (): 10 m 1 s (601 s) Cnt:(c/wc/ec)1170/324/1170 2.2%

Again the best place to review would be kernel thread.

All the best!
[BetterBatteryStats] kevindd992002:
Is this issue only occuring when full-charged to 100%?
[BetterBatteryStats] alexinna:
New tab based screen is much cleaner. What are the different background colors represent? Maybe to keep it consistent with look and feel on other tabs just change color of the font. Also how is this information can be used to help minimize wakelocks?

---------- Post added at 03:57 AM ---------- Previous post was at 03:48 AM ----------

In my case yes but if you plug/unplug again it should be back to normal.

Also I suspect that calculation could be wrong even if you charge for few hours and it's not 100% yet but I didn't verify such case.
[BetterBatteryStats] sakis_the_fraud:
Hello!

this program is awesome!

it helped me get around 20% more battery life from my device!

Now i want help about the com.google.android.gsf.

From what i have found, it's related to the Google Talk app, but i have removed it from the first day i updated to android 2.3.5.

What should i do to remove these wakeups?
[BetterBatteryStats] chamonix:
The issue occurs after the phone was unplugged at 100% until the next plug/unplug when the charge ist less than 100.

The good news is I found the cause.

Being tired because of a short night made me think differently and I found the cause.

Yesterday I was looking for the reason the runtime was small as it gets reset at 100% but overlooked that the deep sleep time (see my previous post) was high after the unplug. And exactly that is the problem: after unplug the deep sleep time should be zero. This lead me to the cause: caching.

Let me explain: the data saved to the reference is the data prior to the unplug and not after. This is not a problem usually as values grow all the time anyway but in the specific case the counters (runtime) are reset so it matters. Some of you certainly remember the discussions of comparing a ref from before a reboot with values after, it's the same problem.

The solution: remove caching

As the reason for caching is not performance but only the attempt to reduce the chances that the battery info service stops responding (that was an old bug that I think we solved better since then) the fix should have no negative effect and I feel like removing the cache completely. But I am careful because making sure caching is really not required anymore requires time and I don't want to take the risk.

Instead I will take a more conservative approach and invalidate the cache only when saving refs. It will take me a little longer to test again and I will release RC4 this evening and run the quick fix I did this morning till then.
[BetterBatteryStats] chamonix:
About the style: this dialog uses actionbsrsherlock, a framework supporting the features from android 3+ on earlier versions. I will have to look into the hollow theme as is is not present on GB and must be provided by the app itself.

How this data can help: permissions and services are important info when it comes to find ways to avoid partial Wakelocks or Alarms caused by apps running in background of which the user may not even be aware of. Permissions provides info about what event the app reacts on (eg start at boot) and what services it may run in the background. With this info one can try revoking certain perms (eg autostart) and see if the app still delivers its purpose but behaves better.

Edit: re-reading you post I think you meant the background colors of the permissions not of the screen right?

Those are related to the categories of permissions, I will add a legend (#280)
[BetterBatteryStats] chamonix:
Yes I M interested in providing and tool that is more intuitive and the lack of it is the reason why bbs is still in Version 1.x and not 2.0.

I have always said that features come first and there were only a few releases making slight changes to the user interface but that is not user experience.

I have a few ideas and even mockups, especially for a new start screen. This idea is based on the 4 values provided by the 1x1 widget: deep sleep / awake / screen on / rest

Today bbs is a collection of all relevant data but the user has to know where to look and what to do with the info he gets.

A different ui for non experts should change that. I feel that user stories would be the right method to approach that as, if we pick the right stories, the ui flow should follow them. If you are interested to contribute in this first step please feel free to contribute. If you have an idea or a suggestion on a platform where we could start collection and refining ideas feel free, I feel that this thread may not be the right place for that but we could still start here. Once we have a couple of user stories the next natural step would be to mock up or prototype a screen flow supporting this.

But one thing is for sure: there will still be an expert mode for users who don't need to be told how to use bbs
[BetterBatteryStats] suku_patel_22:
Sven, please remove the borders on the list view. It doesn't look good at all

Tapatalked from Desire S running Androdamus
[BetterBatteryStats] chamonix:
Thanks for the warm words. I don't feel it would be right to add alternative means to donate as bbs is a paid app already and support is part of the price in my eyes. If you want to donate please hold on to the amount you wanted to donate, pick the organisation of your choice and donate to it instead
[BetterBatteryStats] Karpfenhai:
Thx Sven, im glad you found the cause! Unfortunately im running out of thanks for today ;)

Maybe a delimeter on / off option would be nice? Default on and a possibility to disable in advanced settings? Or a way to choose a different color... ;)

Have a calm day mate!
[BetterBatteryStats] valsacar:
Ok, so I've googled and looked here... what app or service is causing com.android.providers.calendar to show up so high on wake alarms? I have calendar sync off already.
[BetterBatteryStats] kevindd992002:
Thank you very much. You're the best mate :)
[BetterBatteryStats] kmetek:
my dumps:

http://dl.dropbox.com/u/8043637/BetterBatteryStats-2012-09-19_123549301.txt

http://dl.dropbox.com/u/8043637/BetterBatteryStats-2012-09-19_123549302.txt
[BetterBatteryStats] sbk_hbk:
So its mandatory that my phone needs to be rooted to check which apps causing wakelocks..?
[BetterBatteryStats] xelra:
Search through this thread and limit your results to posts from Karpfenhai.

At some point he posted a detailed guide on how to reduce wakelocks from the Google Service Framework.

Don't get confused by the gtalk string in that wakelock. It doesn't really have anything to do with gtalk specifically.

The idea is to cancel autostarts for gsf, but only those that don't break any user wanted functionality. In his guide he describes which ones that are.

You could also just try for yourself. There's nothing that can't be undone or damaged.

You need either Gemini app manager or Autostarts.

There is another one in the market, but it's expensive and I heard it doesn't work that well.
[BetterBatteryStats] It_ler:
No, kernel (KWL) and partial wakelocks (PWL) are shown without root.

Only "Alarms" and "Network" need root.
[BetterBatteryStats] kvv515kvv:
one more dump file

could someone to review please?

thanks
[BetterBatteryStats] kingofcomedy:
New dump.
[BetterBatteryStats] dpaine88:
Anyone with a clue to the RILJ(phone) wakelock? Does that mean I just have bad service atm? I have not made any phone calls today.