yashsingh1/xdaforums huggingface dataset:
[BetterBatteryStats] cdmackay:
I see a few people submitting reports with no Alarm data, and it says something like "No reference since unplugged set yet".

I got this myself when I switched from the paid app to the XDA app, which was a fresh install.

In my case it was because I'd never previously manually run Alarms (on this new version), so the app had never tried to get root before. First time I manually ran it, it asked for root, and I got the Superuser popup asking if that was OK. From then on, the Alarms data works properly.

If that really is the case, perhaps the app should try to gain root when first it runs, to allow the user to say OK, and so the data can be properly collected?
[BetterBatteryStats] supernova_00:
Could you please help me figure out what is causing my battery drains? I'm suspecting the following, which I have no clue what they are or why they are causing lots and long partial wakelocks:

"vbus-tuna_otg" (): 3 h 18 m 18 s (11898 s) Cnt:(c/wc/ec)13/0/13 2.9%

"modem_usb_gpio_wake" (): 2 h 24 m 5 s (8645 s) Cnt:(c/wc/ec)12105/748/12105 2.1%

"PowerManagerService" (): 2 h 9 m 42 s (7782 s) Cnt:(c/wc/ec)17325/0/0 1.9%

"wlan_rx_wake" (): 1 h 43 m 30 s (6210 s) Cnt:(c/wc/ec)7339/0/7339 1.5%

"modem_usb_suspend_block" (): 1 h 38 m 10 s (5890 s) Cnt:(c/wc/ec)13052/0/0 1.4%

"alarm_rtc" (): 46 m 56 s (2816 s) Cnt:(c/wc/ec)4979/0/1156 0.7%

"nfc" (): 43 m 59 s (2639 s) Cnt:(c/wc/ec)5780/2354/5780 0.6%

From what I could find the first two relat to usb stuff. I have not connected anything to my phone today and I don't have any options related to the usb enabled. Also, NFC is disabled so I don't know what that is showing 44 minutes worth of partial wakelocks as well at alarm_Rtc since I have no alarms set.

Thanks in advance!
[BetterBatteryStats] x01a4:
Hi!

My girlfriend is having massive battery issues.

I checked with BBS and it seems that it's wlan related. (Kernel Wakelock)

Anyone else having problems with the wifi on the HTC Desire HD.
[BetterBatteryStats] noke955:
I'm sorry, but this dump is not much better. Screen on time is too much, better would be a dump from idle time.

Please do the following:

- change default stat type to "since unplugged" (settings, preferences, default stat type)

- plug in to charger, unplug again

- let the phone sleep for at least 2h, better more

- make a dump file and post it
[BetterBatteryStats] jeremysherriff:
I don't think you have a background battery problem, I think you have a problem with the type of things you do with your phone. I think you do a lot with your phone and expect the battery to last.

If you leave your phone idle overnight, does the battery drain?

---------- Post added at 08:56 AM ---------- Previous post was at 08:51 AM ----------

I take it your Desire is completely stock? Not rooted even?

Weird, my Father has a Desire HD and it doesn't do this.

It may be a transient condition? have you tried rebooting? (sorry if that sounds dumb, but some people just don't think of it). Other than that, the only thing I can suggest is setting the wifi to sleep when the screen is off, or taking it for "repair" under warranty.

Or... root - custom recovery - custom rom ;)

---------- Post added at 08:59 AM ---------- Previous post was at 08:56 AM ----------

Alarms refers to the "Alarms" section of the dump, and again there's more weirdness in there. Looks to me like you have a kernel problem, might be worth posting in the thread for your rom/kernel.
[BetterBatteryStats] sohebq:
Here are your top four culprits:

RILJ (Phone): 39 m 38 s (2378 s) Count:543 5.4%

ConnectivityService (Android System): 34 m 52 s (2092 s) Count:4325 4.8%

ChatSession (com.facebook.katana.Facebook): 15 m 23 s (923 s) Count:84 2.1%

JuiceDefender.Service (JuiceDefender): 10 m 26 s (626 s) Count:2111 1.4%

I hope you know about them all.
[BetterBatteryStats] KJ98653:
Here's the log for several hours.
[BetterBatteryStats] jeremysherriff:
Thx. Just a guess, but did you have the phone face-down while it was sitting idle?

Kernel Wakelocks
================
"proximity" (): 2 h 32 m 26 s (9146 s) Cnt:(c/wc/ec)9/0/9 81.9%

You have some kernel issue where the proximity sensor is running all the time.

everything else looks OK to me.
[BetterBatteryStats] supernova_00:
I'm using the leaked 4.0.4 ics build with the stock kernel and no mods other than unlocked boot loader and root.
[BetterBatteryStats] KJ98653:
Nope. Should I run another log since I went from 100% to 72% unusually fast? Or should I just go ahead and flash another kernel? I just ask because it doesn't seem like I'd match my two last batt readings with that sort of idle drain.
[BetterBatteryStats] jeremysherriff:
maybe reboot ( to clear the sensor lock), plug charger/unplug to reset the BBS "since unplugged" time, and take another reading after some idle time? You'll be able to see fairly quickly if that kernel wakelock remains..
[BetterBatteryStats] takeheart:
I know what the second two are (though I'm not sure why Facebook is staying awake/active as it never did before and all sync aspects of it are turned off) but I have no idea what RILJ and ConnectivityService are. Anybody have experience with either of those to know what they might be?
[BetterBatteryStats] KJ98653:
I didn't restart but just plug and unplugged. About several hours since 6PM EST seems to be gone. Doesn't show up at all. I never leave my phone face down, but guess I can't rule anything out. Thanks dude
[BetterBatteryStats] Paragon_X:
Hi everyone. So here are my stats. As I said earlier, I am not one to complain about my battery life. However my sync is high, and for that reason I am not too sure. I'm not sure what I can identify to be using it that much but nevertheless, any insight would be great.
[BetterBatteryStats] TNSMANI:
Which version of BBS are you running? Try ver. 2.5.341 or 2.5.344,
[BetterBatteryStats] maximus81:
anyone knows what is job.deadline wakelock?
[BetterBatteryStats] TNSMANI:
All I know about it is that it is harmless from the drain point of view.
[BetterBatteryStats] Oswald Boelcke:
I agree to @TNSMANI's assessment. I regularly take idle dumps just to check my system's behaviour, with which I'm very happy. I've attached my last four dumps, and I find job-deadline everywhere but no harm and certainly nothing I want to mess around with.

I'd to zip my dumps because for whatever reason XDA didn't allow me to upload the txt-files directly. But this already occured in the past. I'm going to inform the admins.
[BetterBatteryStats] TNSMANI:
This doesn't occur for everyone. Some are unable to and some have no difficulty. I am not able to find a pattern.
[BetterBatteryStats] MikeChannon:
Not sure what we can test here. Can you experiment with shorter simpler file names, and maybe keeping a file name but deleting most of the content (just in case some sort of screening is going on)?

Mike
[BetterBatteryStats] roxy1712:
Preface: I am rooted. :)

I've been having issues getting BBS to work. When I first installed it (version from Google Play), nothing would show up on the summary screen. At one point it did work - I have no idea what happened, but the stats showed up on the summary screen - but it went back to being blank in the days after.

I updated to 2.6 and ran the ADB scripts just for giggles, and did a test that night. Worked brilliantly and I saved the logs (more later). Now I'm back to a blank summary screen on boot and after several hours' of use. The Magisk Superuser toaster (e.g., "BBS has been granted superuser rights") pops up sporadically after I boot and when I'm in the app.

Any tips? I wish XDA would bring back fix the "search thread" feature...
[BetterBatteryStats] halilb1978:
Is there a pause/stop setting for the application ? What to do if i do not wanna uninstall the app but also do not wanna work once i kept my log?
[BetterBatteryStats] badtlc:
batter stats is not collecting data and it also says it cannot connect to batteryinfo service. Any ideas on what might be wrong?
[BetterBatteryStats] leonardoroza:
Force stop it and be sure active monitoring is disabled
[BetterBatteryStats] bilbonotry:
Greetings, could someone take a look at the attached dump please? VK_wakelock prevents my phone from going to deep sleep. I am on alxnder devbase 7.4 for Samsung galaxy s9 android 10.

Thank you
[BetterBatteryStats] bilbonotry:
Dump here http://pastebin.fr/96631 could not attach it
[BetterBatteryStats] mrjuniork:
Please refer to the OP regarding instructions for taking a proper dump.

You got more than 1h sot.

After posting a proper dump, I'm sure some proper analysis will be on its way 👍🏼

And regarding that VK wakelock. Is that somehow connected to the app "Kate Mobile for VK"?
[BetterBatteryStats] bilbonotry:
Oh sorry I searched for these instructions and failed miserably. Got them now.

I do not have the app Kate mobile
[BetterBatteryStats] Oswald Boelcke:
This post is only meant to test if I'm meanwhile able to upload idle dumps without prior zipping.

These are the latest two dumps I took; an analysis is not required as I'm very happy with my 0.3%/h respectively 0.4%/h drainages.

It's weird, and I've to look deeper into any differences. The upload worked only with one file, and I'd to zip the other one.
[BetterBatteryStats] peterlee928:
i am continuing to get the following error message (see attached picture). any thoughts on how to fix? much thanks in advance. device is samsung tab s6 with most recent android 11 update and one ui 3.1
[BetterBatteryStats] Prototype18:
Hey guys this is my log. My phone is awake nearly the same time as screen on. Fully charged and didnt touch it for 9 hours. Then used it a bit and the log attached to the zip. Btw if you check mi fit app ( mi band ) ignore it as the battery life was the same without it before. Thank you
[BetterBatteryStats] Oswald Boelcke:
Your log isn't usable for an analysis as it is not an idle log. Your screen-on-time (SOT) is 1h 3' 58"! Please provide an idle dump with less than one minute SOT.
[BetterBatteryStats] Prototype18:
Ah okay sorry, ill edit tomorrow morning again.
[BetterBatteryStats] Oswald Boelcke:
Fine. Let me know if you're unsure about the procedure then I provide my best practise. Just a few posts above, I've posted my latest idle dumps if you're interested for comparison.
[BetterBatteryStats] Prototype18:
Im kinda happy with my battery life ( even though it changes daily xd) but the most i got out of the F3 is 9hr SOT over 2 days usage. Now it is like worse imo. Same settings same usage and sometimes it goes from 98-91 in like minutes and then it stays os 90 for 30 min gaming. Also i check your post that u mentioned and i saw u have 1hr awake time and still 3% overnight. Thats what i want to adress. Phone awake during screen off eceb though i have set to close all apps after 5 min screen lock
[BetterBatteryStats] Oswald Boelcke:
Affirmative, my usual idle drainage is between 0.3%/hour and 0.5%/hour, and I know already for me it really depends on the quality of the mobile signal. We live in a rural area where you can't depend on too many towers but the drainage is very fine. However, just from a very quick glance into your dump you can't most likely compare our systems as mine is Google-free, running with microG, no Whatsapp, FB, Twitter etc. but alternative and privacy findly social media and messenger, no smartwatch, no "health" tracker etc.

And SOT too much depends on personal usage and preferences and can't be compared in my opinion at all.
[BetterBatteryStats] SingularityHRT3:
BBS doesn't show any stat at all. Just keeps loading. Ran the command already. Status and permissions are fine. Keeping BBS running drains a lot of battery and heats the device up very badly. FCing it fixes the drain and heating. Other apps (can I name Them?) pointed out that BBS was indeed draining the battery (very badly). Should I get logs for it? From in-app or using a log app?
[BetterBatteryStats] Prototype18:
I tried it again and of course bbs gets corrupted. It showes gibberish numbers as i doesnt recognized unplugged or charged. Now it is stucked since the charge before this one. I will have to uninstall and try again.
[BetterBatteryStats] peterlee928:
hi all. so i installed an earlier version of bbs onto the aforementioned device and bbs works well.

however on my pixel 3xl (not rooted, android 12), no version seems to work. constantly get a "no stats have been collected yet" message on the summary screen. am i the only one w/ this problem?

much thanks in advance for any help :)
[BetterBatteryStats] PeQuEsan:
Same here. I had 2.5-341 working till yesterday. Then I updated to Android 12, and today I started to get that "no stats have been collected yet"... I've upgraded to last 2.6-382... same thing.

All permissions OK.
[BetterBatteryStats] peterlee928:
same

i installed the latest bbs version as well as earlier versions... continue getting the same issue on android 12 as well as android 11
[BetterBatteryStats] tortino:
try this adb command:

adb shell settings put global hidden_api_policy 1
[BetterBatteryStats] peterlee928:
that command did not work

i entered that command before entering the permissions commands required for a non-rooted phone

i used the latest bbs version in the link in the 2nd message of this thread

see attached screenshots for the messages that i am seeing
[BetterBatteryStats] PeQuEsan:
Also tried that adb command... Same result as @peterlee928. Seems that BBS + Android 12 doesn't like each other. :)

EDIT: last 2.6-382 version is working in Android 12 with that addition adb command. The only stat I can't see is Kernel Wakelocks and Sensors. Android 12 stock non-rooted in a Pixel 4 XL.
[BetterBatteryStats] Prototype18:
Here are new logs with 13s SOT. Mi fit doesnt drain my battery, especially during the day(sleep tracker) and before i started using it i had the same idle problem. I can use the phone like 2 hours and the battery goes down the drain when not using. Idk what is wrong

Edit: forgot both files and battery percentage is 95-90. 5% drop
[BetterBatteryStats] badtlc:
I had the no stats issue on Android 11. I reset my settings to default (not a factory reset) and reinstalled BBS and it worked.

I updated to Android 12 and BBS still seems to work but it acts really weird and doesn't keep consistent defaults views. Every time I open it, it shows something different and not the default view settings.
[BetterBatteryStats] Zilla0617:
Do you mind sharing the latest version? Thanks
[BetterBatteryStats] PeQuEsan:
You've got it in second post inn this thread. Here:

App Center

install.appcenter.ms
[BetterBatteryStats] Zilla0617:
Thank you. That version is not working for me on my rooted Pixel 4xl
[BetterBatteryStats] Prototype18:
Idk why XDA keeps deleting my log lol. Sorry for double post
[BetterBatteryStats] Duvel999:
Thx. for development of this app.

Using now Older V 2.5-341 on Android 11. With Latest version do you suggest?
[BetterBatteryStats] jonibonim:
All settings for a full-fledged smartphone device are created according to the recommendations in the xxxx theme, the xxxxx manual has been prepared for the dump, and I am attaching it. Wi-Fi is turned off, almost all applications are closed except for necessary ones, and the list of recent applications is cleared. Tell me what and how else to fight for a better sleep? I really need help, I can't handle it myself. As I myself understand from the dump, the main reason is that it limits Google Play, but I already understood them as soon as I could according to the instructions, WhatsApp, as I understood the synchronization of contacts, I have already disabled for it.

Все настройки для полноценного устройства смартфона созданы по рекомендациям в теме xxxx, на дамп подготовлена инструкция xxxx, и я ее прилагаю. Wi-Fi отключен, закрыты практически все приложения, кроме необходимых, и список недавних приложений очищен. Подскажите что и как еще бороться за лучший сон? Мне очень нужна помощь, я не справляюсь сам. Как я сам понимаю из дампа, основная причина в том, что это ограничивает Google Play, но я их уже понял, как только смог по инструкции, WhatsApp, как понял синхронизацию контактов, я для него уже отключил.

MOD EDIT: Post edited to remove references to warez website. Please do not refer to such websites.
[BetterBatteryStats] TNSMANI:
That is a logcat. We need an idle dump file in .txt format. The last time you attached both.

EDIT: Sorry didn't see your subsequent post.

This is an issue.

Another one.

Location/scanning being on, causes some drain.

But your drain is only 0.5% per hour which is ok on Android 11. May be if you take another dump from around 85% battery instead of from "Unplugged", it may show a reduced drain.
[BetterBatteryStats] Prototype18:
2-3 post above i have attached the zip file.
[BetterBatteryStats] TNSMANI:
Please see my edited post above.
[BetterBatteryStats] TNSMANI:
Please use English or a translation to English while posting on XDA as per Rule 4.

You have a drain of 0.4% per hour despite a screen on time of nearly 5 minutes. The screen on time should be as less as possible and in seconds, not minutes or hours. Please post a proper dump.
[BetterBatteryStats] Prototype18:
I will take another dump from 85%. The alarms form mi fit app (mi band) have no impact. I had the same overnight drain before i got the mi band. I can try it without mi app and i will get same 0.5-0.7% per hour. The biggest problem i have is drain during the day where i kill every app and clear cache and i get huge drain. Device is awake for like 3+hours with screen off during the day.
[BetterBatteryStats] TNSMANI:
Killing everything and clearing cache constantly will drain battery quicker since every time you open a killed app, it has to start from scratch and also build its cache. You kill it again and clear its cache .... the cycle continues.
[BetterBatteryStats] Prototype18:
So i should just leave them be. Delete miui security cleaner too ? I will try again but the main problem imo is the phone not going to sleep soon after i lock the screen. the day before the attached log it was awake for 3+ hr in 20hr total time. Ill try and update back here. Last resort would be a factory reset cuz this "other apps" is killin me !!
[BetterBatteryStats] Zilla0617:
All of the versions of BBS I tried, none of them will work with rooted Pixel 4xl on A12.
[BetterBatteryStats] peterlee928:
hi all... apologies for asking again... would love to know if there is a workaround on this issue? really appreciate any help :)
[BetterBatteryStats] badtlc:
I'm also waiting for a working update for Android 12.
[BetterBatteryStats] add_pl:
Please analyze my dump file. I have 0 deep sleep, what can this be causing?
[BetterBatteryStats] Oswald Boelcke:
Which idle dump file? You haven't posted any.
[BetterBatteryStats] add_pl:
I cant attach file :(

dump - Pastebin.com

Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.

pastebin.com
[BetterBatteryStats] Oswald Boelcke:
Pastebin is absolutely fine and sufficient. Quite a few people including me have occasionally issues in attaching an idle dump as txt-file. If you zip the file first, it will work, too.
[BetterBatteryStats] add_pl:
Yes, ZIP file works.
[BetterBatteryStats] TNSMANI:
Kernel wakelocks.:

Try disabling Tap-to-wake and Lift-to-wake options and check if sleep returns. For some, it seems to work. Or try a factory reset, it worked for another. Seems to be a problem with Mi phones. If not solved, try a different ROM/kernel.

Other issues:

Alarms:

Please reduce the number of widgets or their frequency of updation.

Mobile signal is not very good. If possible, locate the phone where you have a better signal while taking the next dump.

Mi weather app is also causing drain. Disable it for the next dump.

But your main issue is the kernel wakelock. And next time you take another dump, let it be for atleast 6 hours, the current one is for less than 4.5 hours.
[BetterBatteryStats] Nekromantik:
Is June version latest? Working on Android 12?
[BetterBatteryStats] TNSMANI:
I don't think that any version works with Android 12. Even with Android 11, only the earlier versions work. Please read a couple of pages back.
[BetterBatteryStats] Camack:
Which version works on Android 11?
[BetterBatteryStats] Duvel999:
2.5 341 works good on Android 11
[BetterBatteryStats] beeshyams:
I saw several posts that it doesn't work on Android 12 and also experienced the same on rooted Pixel 4a.

I opened an issue on Github and now closed it because the same problem was reported earlier (see screenshot) and the fix reported earlier works on Android 12 too (for now at least 🤞) on the latest version (2.6-382) (kernel wake locks don't work though)

Fix is from PC :

adb shell settings put global hidden_api_policy 1

More info on this command from Stack overflow https://stackoverflow.com/questions/55970137/bypass-androids-hidden-api-restrictions

YMMV, hope this helps
[BetterBatteryStats] Zilla0617:
The app works somewhat after entering the command, unfortunately the widget still does not update.
[BetterBatteryStats] tze_vitamin:
Cant find this app on playstore ,what is the latest version?
[BetterBatteryStats] tze_vitamin:
For me widget is working , I must tap on it to start showing updates.
[BetterBatteryStats] Lughnasadh:
Link to the latest version is in the OP, Post #2 under Current test-release, as is why it's not on Play Store anymore.
[BetterBatteryStats] Zilla0617:
That's interesting when I tap the widget nothing happens, it remains at 0% for all stats.
[BetterBatteryStats] tze_vitamin:
I must tap to upade the stat, no automatically update
[BetterBatteryStats] tze_vitamin:
You have also update button on this widget on the right up corner
[BetterBatteryStats] Zilla0617:
I appreciate your advice, but I know how to update the widget, I've been using the app for years. Ever since i updated to Android 12 I experience problems with the app. When I enter the command, the stats inside the app updates but the widget won't, even if I tap the corner.
[BetterBatteryStats] tze_vitamin:
I noticed also that every time when I unlock phone widget update. Maybe its because of ROM. I am using Xiaomi . Eu rom on Redmi note 9 pro 5 G
[BetterBatteryStats] Zilla0617:
That could be possible, I'm rooted on stock Pixel 6 Pro
[BetterBatteryStats] aldarund:
Phone discharged like 70% overnight, cant figure out what cause it. In native battery stats from miui it show other apps as most of cpu, in betterBatteryStats cant figure..

Here logs from betterBatteryStats

Dropbox

www.dropbox.com
[BetterBatteryStats] tze_vitamin:
I have Xiaomi, Redmi note 9 pro 5 G,. Does anyone know what is this first stuff that spend my battery
[BetterBatteryStats] Oswald Boelcke:
SurfaceFlinger and WindowManager | Android Open Source Project

source.android.com
[BetterBatteryStats] tze_vitamin:
Thanks. Didnt see this before in gsam battery monitor
[BetterBatteryStats] TNSMANI:
Requires login to Dropbox.
[BetterBatteryStats] aldarund:
Just checked - it dont require. It show login popup but you can just close it and ignore. Anyway i attached in this message too
[BetterBatteryStats] TNSMANI:
Yes, you are right. Sorry for my error.

Your dump is not an idle dump. It has over 50 minutes of screen on time. Screen on time should be as less as possible, in any case in seconds. So please post a fresh dump saving it as soon as you unlock the phone.
[BetterBatteryStats] tze_vitamin:
What this command do?

adb shell settings put global hidden_api_policy 1

I put phone in fastboot, and through ADB enable it? What wil l get? I could not find answer
[BetterBatteryStats] aldarund:
kk, will do, thanks.
[BetterBatteryStats] TNSMANI:
Please read atleast the last couple of pages before asking. See this post: https://xdaforums.com/t/app-2-2-05-oct-v2-4-betterbatterystats.1179809/post-85903339
[BetterBatteryStats] tze_vitamin:
I read as much as I could.. not only this. I put phone in fastboot mode , connect it with Pc and through ADB use this command?
[BetterBatteryStats] aldarund:
Here new dump
[BetterBatteryStats] TNSMANI:
Just a booted phone, no need for fastboot. Connect it to PC, check whether device recognised and then input the command.