yashsingh1/xdaforums huggingface dataset:
[BetterBatteryStats] DB126:
Generic guidance for all: establish a baseline, understand what is impacting performance and/or endurance then decide if it's worth acting on. If so seek simple solutions (often just a setting change) using the least intrusive tools. Changing ROMs, kernels, etc is rarely needed. Careful app selection can go a long way to resolving most issues.

Specific to your situation:

- new battery

- Greenify identified abusers as needed (or some other hibernation tool)

- don't worry about syncs, etc unless it impacts endurance or performance

- avoid direct alarm/wakelock management unless absolutely necessary

Answers to your other questions are obvious: Google benefits from 7x24 connectivity; most users are fine with that.

As you said: OT. Enough time at the pulpit. Knob turners are getting anxious (and likely annoyed). Final comment. My idle drain rates average 0.25-0.40% per hour on three very different devices with minimal active management. Includes full push mail (50+ items/day) and location services. Imagine that.
[BetterBatteryStats] DeadlyToast:
I've been using this app for a few months and the package info never worked for me. I can't select application settings or app ops nor i can open the permissions and services tab. Anybody been in the same boat as me and solver it? I'm using OP3T.
[BetterBatteryStats] peterlee928:
[MENTION=542640]Zotho[/MENTION] i will make this short - [MENTION=5488402]Davey126[/MENTION] has taught me (and others) much about the less is more. and it has worked well for me. also sometimes more beneficial to get rid of bad apps rather than kill their associated wakelocks/alarms. the latter tends to create more problems than solving them (at least for me... but imma noob). :):good:
[BetterBatteryStats] adm1jtg:
Still haven't heard anything and still unable to use BBS on any 8.1 rom i have tested for shamu
[BetterBatteryStats] Zotho:
I think this is right in many aspects, but you know: I like to fiddle around a little bit and try. :p After all, it won´t help much but gives a good feeling to gain the control over your own device :laugh::silly:
[BetterBatteryStats] peterlee928:
lol dont blame ya. and its thanks to folks like you that new, helpful methods get discovered :)
[BetterBatteryStats] DB126:
No doubt about that; fresh eyes and perspectives are always welcome. :)

---------- Post added at 11:08 PM ---------- Previous post was at 10:56 PM ----------

Suggest trying another monitoring tool like GSAM. If issue persists across app boundaries it is likely specific to your device (config) or device type. If not then your issue goes into the queue to be resourced at the developers discretion.
[BetterBatteryStats] TNSMANI:
Nothing jumps out in the dump. You already have a reasonable drain, 0.5% per hour.

I hope that you have read the posts on the last couple of pages, if not please do so. I also subscribe to the sentiments expressed in those posts and have benefited by the observations of Davey126 in the past.

So why don't you just enjoy your device?
[BetterBatteryStats] Zotho:
Just as a short info to end this topic for me: I reverted back to MM stock ROM (modified by _alexandr for Galaxy S5/klte), and got an overnight battery loss of around 0.1%/h . :D

Had around the same settings and apps as with Nougat LOS and the modifications of it. So it seems it has to do something with my phone, it doesnt like the taste Nougat or of LOS so much :p.

Now I am debloating this ROM to remove the unneccesary tools by Samsung and everything is good to go. :victory: Missing a few minor features of the other ROMs like Themes and stuff, but in exchange got some others working (like Equalizer and Camera HDR)

[/OT]
[BetterBatteryStats] peterlee928:
howdy all. curious if the great minds here have any guidance. my overall sot drain is fine... but 2 wakelocks in particular are on almost the entire time.

1) 9-0022 (couldnt find any info on this)

2) 6a00000.ssusb

for the 2nd one, i tried to use this solution... but when i restart my phone, the "Y" changes back to "N".

https://xdaforums.com/oneplus-3/help/6a00000-ssusb-wakelock-wld-bbs-t3463062/post73113344

would anyone happen to know:

1) the real source of these wakelocks

2) are they bad actors that should be killed

3) if so, what would be the optimal method to kill

much thanks in advance :)
[BetterBatteryStats] DB126:
Kernel WLs are tough to diagnose (typically related to physical component) and often impossible to remedy without switching kernels - either directly or via custom ROM. Assuming the hardware is ok you are probably looking at a kernel issue.

Appears one is related to the USB port and OTG functionality. I have seen similar issues on various devices; usually rebooting sans tether clears it. I once had a device (Moto XT1030) that generated OTG WLs due to a sloppy USB port. Had to exercise care when plugging/unplugging to avoid the WL.

Looks like one/both WLs are contributing to a disruption in "deep sleep" but composite idle drain remains reasonable at 0.7%/hr. You could try a different kernel (if available) or roll back to Nougat. Or just leave it alone.

Sorry couldn't be more specific.
[BetterBatteryStats] chamonix:
looking at the logcat I see a lot of data flowing but also one error retrieving the alarms that I want to look into. Unfortunately you didn't attach the dumpfile so I must guess what the result was.

I/AlarmsDumpsys( 3397): getAlarms: SDK=27, RELEASE=8.1.0
E/ NonRootShell( 3397): An error occured while executiing command dumpsys alarm. Unable to add commands to a closed shell
D/StatsProvider( 3397): Result [su rights required to access alarms are not available / were not granted]

I will look into this and kindly ask you to wait for the next beta and retry to re-test and provide both logcat and dumpfile if the problem persists
[BetterBatteryStats] chamonix:
Unfortunately I am not a SELinux expert but what would be interesting to know is if there is an issue with the perms on the upper directories, so /sys , /sys/kernel and /sys/kernel/debug. The errors that you see is when BBS tries to access /proc/wakelocks as the wakelocks are located in either the one or the other location. As I don't know of any way to tell where the files are the code attempts both:

(from https://github.com/asksven/BetterBa...en/betterbatterystats/data/StatsProvider.java)

// we must support both "old" (/proc/wakelocks) and "new formats
if (Wakelocks.fileIsWorldReadableExists() || WakeupSources.fileIsWorldReadableExists())
{

if (Wakelocks.fileIsWorldReadableExists())
{
Log.i(TAG, "Using Wakelocks file");
myKernelWakelocks = Wakelocks.parseProcWakelocks(ctx);
}
else
{
Log.i(TAG, "Using Wakeupsources file");
// check if we have a LG G4, G3 or G2
// Build.BRAND: lge
// Build.DEVICE: g3, g2 or p1
if ( (Build.BRAND.equals("lge"))
&& (Build.DEVICE.equals("g3"))|| Build.DEVICE.equals("p1") || (Build.DEVICE.equals("g2")))
{
Log.i(TAG, "Using LG G2, G3, G4 specific wakeup sources");
myKernelWakelocks = WakeupSourcesLg.parseWakeupSources(ctx);
}
else
{
myKernelWakelocks = WakeupSources.parseWakeupSources(ctx);
}
}
}

Edit: good way to find out if there is something inconsistent with the perms is to switch to kernel wakelocks using the API (advanced settings). In that setting the files are not accessed anymore by BBS but I rely on the android framework to read the files. If the raw stats show nothing after switching to API then it means that there is something borked with the perms as the susbsystem is always supposed to have access to these files.
[BetterBatteryStats] chamonix:
Sorry for my responsiveness not meeting your expectations. I am on it and you can track resolution in issue #823 on github.
[BetterBatteryStats] chamonix:
I am not sure if the issues are somehow related but I don't thinks so:

- suspend_backoff: it's interesting so see what happens in dmesg. From what I read it seems that your device goes into the PowerManager (PM) cycle to shut down to sleep but in that procedure there is a sequence to shut down CPUs that seems to fail on CPU3, causing the procedure to be aborted, hence the back-off from the suspend procedure

- qcom_rx_wakelock: seems related to the device being woken-up by wifi broadcasts/multicasts, probably uPnP.

I'd recommend that you turn Wifi completely off, expection the rx-wakelock to disapear. The chances are low but It'd interesting to see if this has an effect on suspend-backoff
[BetterBatteryStats] TNSMANI:
I have no info on the two wakelocks mentioned. But considering the huge background downloads on wifi and mobile data, 0.7% drain per hour seems very reasonable. I am sure that the drain would come down to less than 0.2% if these background downloads are discounted.
[BetterBatteryStats] adm1jtg:
The program never saves any files for me. I setup a default directory, go over share and save, and no files show up. Even tried emailing them but receive an empty email. The logcat I provided had to be captured by another program.

I am happy to provide a dump file if you can tell me how when it appears the program is not saving any log files at all.
[BetterBatteryStats] chamonix:
Will look into that. 2.3-218 is up, fixing the issue I found in the logfile where accessing alarms failed
[BetterBatteryStats] rignfool:
Let me guess...

You have no alarms...

On 8.1 NOTHING HAPPENS before you unlock the screen the first time... So BBS has a problem saving the on boot reference (I don't care what [MENTION=1330150]chamonix[/MENTION] says... This is the issue)

You have to create the unplugged reference... With the screen on...

Also take BBS out of battery optimization...

And remember this is on a volunteer basis
[BetterBatteryStats] steigerth:
I installed in the mean time another custom rom: LineageOS 12.1 for Z1c with current Sec.Patches, Android 5.1.1

With this rom I do not face anymore the problems with suspend_backoff and qcom_rx_wakelock. Battery drain during the night (airplane mode and battery energy saver) is about 0.3-0.4%/h which is OK for me. In normal conditions with bluetooth and wifi on I have a drain of about 1.5%/h which is also a good value.

I might be that I have a TWRP backup of the previous setting with the other rom from which I gathered the logs. Before I do a restore I would like to ask a question about the dmesg log. Am I right that at the beginning of each line there is a time stamp (in square brackets)? If yes, do all the events occur in almost the same time. From 21767-21874 it would be only 107 seconds. Or does the phone write all log messages into the file when I switch the phone on?

Again thank you very much for the BBS app. I learned already a lot about the phone and will my usage habit of the phone adapt to what I learned.
[BetterBatteryStats] One Twelve:
On 2-3-218

Can't figure out where it saving the dump files ? whether at all it it is saving anything

On 2.2.2.0, the writing seemed to work.

Once you downloaded some funky looking file manager called Ol file manager. It makes me wonder why this app doesn't have its own file manager built in.

it adds extra complications when documenting to others to try out this app

---------- Post added at 07:45 AM ---------- Previous post was at 07:44 AM ----------

Damn it! that is ExACTLY the problem i'm having and pulling my hair out over
[BetterBatteryStats] Lughnasadh:
I had the same problem and ending up checking the "private storage" option in advanced settings and then putting a shortcut to that folder on my desktop for easy access. Had no problems saving dumps to that folder.
[BetterBatteryStats] adm1jtg:
That worked great... Still having some issues getting initial value set... Seems over time it does eventually. Here are fresh logs maybe they will help further diagnose the issues 8.1 users are having as well as the not saving logs files to anywhere but default location issue.

Hmmm... attachment didn't upload... use link to download I guess:

http://bit.ly/2nZcXMp
[BetterBatteryStats] stylemessiah:
[MENTION=1330150]chamonix[/MENTION]

Just tried the latest build (debug) from your group on 8.1, as per the last version I posted about, it doesn't give any stats and the refresh takes forever. I turned on debug logging and have attached logcat.

https://www.dropbox.com/s/s4iolae8qf6918e/2018-02-12-17-11-05.txt?dl=0

On Dropbox as trying to upload via XDA Labs was an exercise in futility.....

Also fwiw, another app I often use, Wakelock Detector, also fails on 8.1...

Gsam however works fine
[BetterBatteryStats] DB126:
No surprise. WLD has not received recent updates related to 8.1; GSAM has. FWIW I also experience BBS lags and failure to aquire stats on some devices running 7.1.2. I have not pursued the matter as there are other ways to derive the info I need to properly manage those environments. I suspect a permission issue is at the core although have no direct evidence. Hopefully [MENTION=1330150]chamonix[/MENTION] can track down thus bad boy once and for all with the logs presented by recent posters.
[BetterBatteryStats] One Twelve:
2.3-218

Can't get the Network stats section to populate. Should add it never worked on 2.2.2.0 either so wondered whether the beta be better ? no :(

Not rooted here

Network says, it requires root, but so does partial wakelock and processes which both work fine.

All three perms granted says the app

ignore oprimisations set for BBS in settings - Apps. So whitelisted yes.

Network Stats using Api in Advanced ? Enabled

In raw stats under Network i see a lot of items with 0 bytes, in the dump file there is nothing and in the app it says no stats collected yet but only for Network

What do i do next ?
[BetterBatteryStats] nospherato:
[MENTION=5656100]tnsmani[/MENTION]

As you told I did the first dump showing my problem. The strange thing is: If I boot in safe boot and reboot the battery is okay as long as I stay in my wifi range and do not change any settings (like disable it when in standby). But if I for example get out of my wifi range and reenter it, bam battery usage comes back to like 7% per hour... (Tested with 3 different routers and 2 different ISPs).

The 2 screenshots are only there to show, what I mean... the service app shows only 4% consume, but it's 50%~ for real (like BBS shows it).

Edit: Sorry forgot it, that's with "wifi always on"
[BetterBatteryStats] TNSMANI:
Something is definitely wrong with the wifi connection. Though wifi was on and running the whole time, mobile data was used for some background downloads while wifi was not used at all.

I suspect a rogue app. It doesn't show up in the dump nor in the battery stats. The dump is normal for a drain of about 0.5% to 0.7%, definitely not for the 7% approx. drain that you have.

I am no good at reading logs. Let someone more knowledgeable comment on that.

In the meanwhile, clean flash your ROM with no other apps and check whether this behaviour repeats.
[BetterBatteryStats] DB126:
While I concur with [MENTION=5656100]tnsmani[/MENTION]'s thoughts and recommendations my gut leans toward a hardware problem or kernel corruption. The WiFi radio dials up power levels when establishing a connection, maintaining a weak connection or searching for signals. Your description suggests power levels never return to 'normal' after those events.

This appears to be a relatively new device that has not been rooted. Consider a warranty claim if a factory reset does not resolve the issue.
[BetterBatteryStats] aerofan:
I have the same problem (Sony xz1c , not rooted, last firmware)

(and other peolpe too: Abnormal Battery Consumption Wifi, How To Deactivate Rcs Service Rich)

About 6% / hour if connect the xz1c to wifi.

If i simply restart the phone (with wifi left on), it decreases to less than 1% / hour.

If it is a hardware problem, i supposed it should appear after reboot, too. Right?
[BetterBatteryStats] amirhosseinakb:
hi

my v20 phone battery draining was about max 1% per hour before (less than 7% totally over 6 hours ) and recently increased between 2% to 4% during sleeping time overnight. (draining at least 15% -20% overnight in sleeping state) .

it seems that during day either performance off battery is decreased. (about 4h with wifi and screen on usage)

Fast charging while second screen is On , is slower than when it is off therefore when second screen is Off , fast charging goes better . exactly , first 30 mins fast charging makes about 40% battery charge(instead of 50%) and after 60 min leads to 85% and full charging taking place after about 135 min instead of 122 mins.

another important thing is that sometimes shades have been seen on the LCD that many users have complained about it.

phone information is :

Android security patch level: September 1, 2017

BASEBAND : MPSS.TH.2.0.1.c3-00045-M8996FAAAANAZM-1

KERNEL : 3.18.31

BUILD NUMBER : NRD90M

SOFTWARE VERSION : V10g-AME-XX

MODEL NUMBER : LG-H990ds

my actions are as follows :

phone is factory reseted. No third party apps is installed. [especially social media apps.]

battery calibration steps for not rooted phones is taken place.(turning off the phone and charging several times repeatedly).

turn off location services and location scanning for WiFi and Bluetooth scanning

turn off WiFi being On during screen is Off.

turn off auto sync, NFC, GPS etc.

not using auto brightness.

not using comfort view .

turn off location services and location scanning for WiFi and Bluetooth scanning

second screen is off during test overnight. (either with second screen is ON with faced down to lower brightness in other day test )

phone is in Air Plane Mode and all data services is off.

system apps like Google services and Play and Assistance is limited by permissions.

you can see in the attachment several tests that taken place with my friends in xda .also BBS log report for 10 hours full sleeping with fight mode and every things turned off is attached.

any help with this issue is appreciated.

................................................. ...........................

update s:

- flashing rom to previous stock version (v10f) was not give me any clue and it seems is not related to the problem.

- testing phone in safe mode couldn't help to decrease draining .

- turning off or on second screen doesn't solve the problem yet.

-changing network operators not solve problem.
[BetterBatteryStats] TNSMANI:
As your drain is 3.7% in airplane mode, check the same while the phone is switched off. That is, charge it to full, shut down the phone, leave it idle for 6+ hours, boot the phone and save the dump "charged/unplugged" to "current". Battery may be going bad.
[BetterBatteryStats] DB126:
Probably (although not conclusive). A kernel or stock ROM interoperability issue now seems more likely given the additional info. Monitor your device forums for an official update and serviceable workarounds. Or wait for a custom kernel which will likely carry its own pros/cons.
[BetterBatteryStats] stylemessiah:
Switched to an AOKP 7 ROM and bbs doesn't work on it either...
[BetterBatteryStats] nospherato:
Okay it wasn't a hardware error or kernel stuff.. just the sony doesn't like my ap...

https://xdaforums.com/showpost.php?p=75562996&postcount=46

---------- Post added at 03:36 PM ---------- Previous post was at 03:35 PM ----------

Okay it wasn't a hardware error or kernel stuff.. just the sony doesn't like my ap...

https://xdaforums.com/showpost.php?p=75562996&postcount=46
[BetterBatteryStats] DB126:
I'd argue the kernel still bares some/primary responsibly for not handling this common scenerio. That said, device incompatibility with various AP families and configs is not uncommon; vendors rarely address unless widespread.
[BetterBatteryStats] nospherato:
[MENTION=5488402]Davey126[/MENTION]

True and of cause you are right, but at least I found a "workaround" for me.

Perhaps my findings can also help others with same problems :)
[BetterBatteryStats] DB126:
Agreed! Thanks for posting your findings. Didn't mean to sound ungrateful.
[BetterBatteryStats] adm1jtg:
Still cant get bbs to work reliably. Posted logs earlier.

Can never set from to reference... cannot be loaded. Raw stats seem to work

Build 218

phone: nexus 6 (shamu)

rom: Tried on RR unofficial, velocity, beltz, ABC (All oreo 8.1)

Here is a set of fresh logs

Have to use links cant seem to post files directly

http://bit.ly/2EmVW5R

http://bit.ly/2o7Iyf8

http://bit.ly/2o01tJn

Currently on rom RR -O unofficial
[BetterBatteryStats] DB126:
Based on member feedback getting BBS to work on Android 8.x is hit/miss. If you need something immediately suggest going with GSAM which seems a bit better behaved on Oreo. I'm sure [MENTION=1330150]chamonix[/MENTION] will get it sorted in time. Like most volunteer developers he has to wedge BBS work in with the rest of real life.
[BetterBatteryStats] adm1jtg:
Understood. Earlier I had reported these issues and he wrote back how bout sending some logs instead of just complaining (Though he said it more tactfully). I agreed that would be a better course to take and posted some logs but was unable to get him a dump. Tried the latest version and had same issues so got him some fresh logs and was able to obtain a dump this time. So really just following up on what he said which is basically you can be a part of the problem or part of the solution. I choose to try and be part of the solution.

That said I wont likely post again till there is a new build to test. He has all the information I can provide now so ball is back in his court.
[BetterBatteryStats] DB126:
Excellent! While sorry BBS isn't working on your device opting to be "part of the solution" by posting logs makes a huge difference and is much appreciated. Disclaimer: I have absolutely nothing to do with BBS development but certainly want to recognized those who choose to contribute to the XDA community in their own way. Thanks again. :)
[BetterBatteryStats] alireza_simkesh:
Just had a quick question.

I have purchased BBS from playstore. But what is the latest version of this program?

I see on Play Store the latest version is 2.2.0, on BBS website the latest version is 2.0.0 (http://better.asksven.org/bbs-changelog/) and on other websites such as Mobilism the latest version is 2.3.0.

So what is the actual latest version now?
[BetterBatteryStats] sirxdroid:
The version in the Play Store is very old and does not work with Android Oreo. Very disappointing that I spent money on it and cannot use it.

I also tried contacting the developer via the support email address posted on the app page and total silence. Sad. :confused:

You can try and get test builds but those don't seem to work either, at least on my Pixel 2 XL. Again, I asked about it here and no answer at all.

https://rink.hockeyapp.net/recruit/e8a901e5d6a04e73a95c53b0fa21ab1a

Time to find an alternative, unfortunately BBS is not what it used to be.
[BetterBatteryStats] alireza_simkesh:
Really?!

I just purchased BBS a few weeks ago and now that I have Oreo they are not gonna upgrade it for me?:confused:

That's very sad. I still don't understand if the latest version is 2.3 how come I am not allowed to update the app to this version through Play Store?
[BetterBatteryStats] zevzek:
Did you join the beta programme on google play?

There is support for Oreo in newer versions
[BetterBatteryStats] alireza_simkesh:
No I didn't, but that would give me Beta versions. Why am I not getting the latest stable version?
[BetterBatteryStats] zevzek:
The latest officially stable version obviously is the one you have.

Beta versions are working and are almost bug free
[BetterBatteryStats] sirxdroid:
Not beta from the play store, I switched to the XDA test builds from AppHockey thinking that I'd get Oreo/Pixel 2 XL fixes even faster. But they don't work. Ended up uninstalling the app. Looking for alternatives if anyone has any suggestions.

---------- Post added at 11:01 AM ---------- Previous post was at 10:52 AM ----------

They are working on Magisk rooted Pixel 2 XL, latest Oreo Feb updates? Really? Not working for me ...
[BetterBatteryStats] zevzek:
Yup, the version from hockeyapp has support for Oreo, I'm using it and I'm not even rooted yet.

What exactly is not working for you?

Did you allow the app to run in background and exclude it from power saving?
[BetterBatteryStats] sirxdroid:
https://xdaforums.com/showthread.php?p=75375609#post75375609