Question GSAM Battery Monitor - How to find wakelocks? What is preventing me from deep sleep?

Search This thread
Working for me properly... besides kernel wakelocks

And you also do not have the same error message under the permission tab?
When opening BBS I also get a toast msg "failed to load since boot" or "failed to load since unplugged", depending on what is set in the app.
In "raw stats" it tells "BatteryInfo Service could not be contacted".

There seems to be a fix. Will try when I am home:
 
Last edited:
  • Like
Reactions: roirraW "edor" ehT
I get terrible deep sleep states in accubattery. between 20 and 40% of the time while the screen is off. Thats bad right?
Yes this is really bad. Actually I think even my 50% are bad. For now it is slowly climbing to 69% but I will track it and post results.

In a perfect world your deep sleep is 99% when your screen is off :> :>
 

old_fart

Senior Member
Dec 8, 2011
1,484
400
it never rains here
Install betterbatterystats and apply the adb command/fix as described in this thread.

Then check for what is causing partial wakelocks or alarms :)
Went to the thread.
First thing . . . . I am very, vey grateful for all the hard work the people put into that thread/app. Wow 1905 pages ! I believe I saw that Android 12 is not supported ( not yet ? ) Hey, so you got it showing wakelocks ? Are you rooted / not rooted ?
 
Okay, so here are my screeenshots from BBS from day #1 and day#2

This post contains day #1 and next post contains day #2.
 

Attachments

  • bbs0112_6.jpg
    bbs0112_6.jpg
    130.1 KB · Views: 168
  • bbs0112_7.jpg
    bbs0112_7.jpg
    138.9 KB · Views: 161
  • bbs0112_5.jpg
    bbs0112_5.jpg
    113.8 KB · Views: 137
  • bbs0112_4.jpg
    bbs0112_4.jpg
    57.3 KB · Views: 121
  • bbs0112_3.jpg
    bbs0112_3.jpg
    66.6 KB · Views: 114
  • bbs0112_2.jpg
    bbs0112_2.jpg
    39.2 KB · Views: 97
  • bbs0112_1.jpg
    bbs0112_1.jpg
    47.2 KB · Views: 166
If your issue is caused by an app or service (which it sounds like it probably is) constantly running in the background flashing the kernel won't help at all.

Your best bet might be BBS, battery historian (you can take a bug report and then view it there, just google it) or maybe top command.

And here is day #2.

Am I understanding this right:
There are nearly no partial wakelocks. So the Problem isn't there.
But there are long "Alarms" listed. Those come from Alarmdroid, Android and GMS.
I attached the specific causes from each of those three according to BBS.
Now I still don't know what do disable / look out for?

Thanks!
 

Attachments

  • bbs0212_5.jpg
    bbs0212_5.jpg
    70.1 KB · Views: 86
  • bbs0212_4.jpg
    bbs0212_4.jpg
    50.8 KB · Views: 78
  • bbs0212_3.jpg
    bbs0212_3.jpg
    65.2 KB · Views: 68
  • bbs0212_6.jpg
    bbs0212_6.jpg
    76.6 KB · Views: 65
  • bbs0212_2.jpg
    bbs0212_2.jpg
    68 KB · Views: 59
  • bbs0212_1.jpg
    bbs0212_1.jpg
    49.2 KB · Views: 84

Lughnasadh

Senior Member
Mar 23, 2015
6,174
7,673
Google Nexus 5
Huawei Nexus 6P
And here is day #2.

Am I understanding this right:
There are nearly no partial wakelocks. So the Problem isn't there.
But there are long "Alarms" listed. Those come from Alarmdroid, Android and GMS.
I attached the specific causes from each of those three according to BBS.
Now I still don't know what do disable / look out for?

Thanks!
First of all, run this command and then reboot to get as much of BBS working on Android 12 you can (kernel wakelocks probably won't work though). adb shell settings put global hidden_api_policy 1

Also, you need to create an idle dump file which is saved with less than 1 minute of the screen being on. Having stats with the screen on more than 1 minute is pretty useless because you can't differentiate what is happening with the screen off vs the screen on. See the BBS thread to learn how to create a proper dump file. https://xdaforums.com/t/app-2-2-05-oct-v2-4-betterbatterystats.1179809/

Then upload the idle dump file here or in the BBS thread. It is very difficult to decipher what is happening with the screen off with just screenshots.

A quick glance shows Splunchy Alarm Clock widget using up a lot of battery and keeping phone awake.
 
Last edited:

xflowy

Senior Member
Jun 4, 2011
1,888
260
Google Pixel 7 Pro
@Lughnasadh mate..you seem to know much about this stuff. any idea why i lost 10 percent during 8 hours overnight in wifi connection. obviously its the first wakelock. but what is this? :l

thanks man!
 

Attachments

  • Screenshot_20211202-073247.png
    Screenshot_20211202-073247.png
    556.6 KB · Views: 103

Lughnasadh

Senior Member
Mar 23, 2015
6,174
7,673
Google Nexus 5
Huawei Nexus 6P
@Lughnasadh mate..you seem to know much about this stuff. any idea why i lost 10 percent during 8 hours overnight in wifi connection. obviously its the first wakelock. but what is this? :l

thanks man!
Hard to tell based on 1 screenshot (see my post above about idle dumps), but com.google.andorid.iwlan seems to be using battery. Not sure what that app is but probably related to a WiFi/Data/Hotspot connection. Sorry can't be of more help.
 
First of all, run this command and then reboot to get as much of BBS working on Android 12 you can (kernel wakelocks probably won't work though). adb shell settings put global hidden_api_policy 1

Also, you need to create an idle dump file which is saved with less than 1 minute of the screen being on. Having stats with the screen on more than 1 minute is pretty useless because you can't differentiate what is happening with the screen off vs the screen on. See the BBS thread to learn how to create a proper dump file. https://xdaforums.com/t/app-2-2-05-oct-v2-4-betterbatterystats.1179809/

Then upload the idle dump file here or in the BBS thread. It is very difficult to decipher what is happening with the screen off with just screenshots.

A quick glance shows Splunchy Alarm Clock widget using up a lot of battery and keeping phone awake.

Yep you are right that a dump is needed.

Funny thing is:
I had my phone off the charger tonight and deep sleep was at 94%.
Then while driving to work and sitting a bit in my office (45m total time) it fell down to 50%.
I also noticed that the "location" symbol is constantly displayed in the statusbar eventhough according to the permissiosn tab nothing is using location atm.


Since there are good deep sleep values during the night, the differences that come to my mind are:
  • Bluetooth connected while in car
  • Lower signal at work and probably more signal searching while driving
  • Different WIFI at work
  • Phone is moving (any sensors not allowing deep sleep?)
  • Any app in "do not disturb" or "do not sync" scheduler while at night

Attached are the dumps of both situations. Maybe you can find anything?
I will add another dump after my work day. But that will be from "unplugged to current" with several tasks done on the phone.
 

Attachments

  • BBS_94DeepSleepNight-2021-12-03.txt
    175.9 KB · Views: 13
  • BBS_50DeepSleepCar-2021-12-03.txt
    160.2 KB · Views: 7
Last edited:

Lughnasadh

Senior Member
Mar 23, 2015
6,174
7,673
Google Nexus 5
Huawei Nexus 6P
Yep you are right that a dump is needed.

Funny thing is:
I had my phone off the charger tonight and deep sleep was at 94%.
Then while driving to work and sitting a bit in my office (45m total time) it fell down to 50%.
I also noticed that the "location" symbol is constantly displayed in the statusbar eventhough according to the permissiosn tab nothing is using location atm.


Since there are good deep sleep values during the night, the differences that come to my mind are:
  • Bluetooth connected while in car
  • Lower signal at work and probably more signal searching while driving
  • Different WIFI at work
  • Phone is moving (any sensors not allowing deep sleep?)
  • Any app in "do not disturb" or "do not sync" scheduler while at night

Attached are the dumps of both situations. Maybe you can find anything?
I will add another dump after my work day. But that will be from "unplugged to current" with several tasks done on the phone.
You have cross-posted this in the BBS thread (and have been answered) so it's best if the experts in there handle it. They are very experienced in diagnosing battery drain. No need to be posting the same thing in multiple threads. Good luck 👍
 
Last edited:
  • Like
Reactions: Utini

Freak07

Recognized Developer / Recognized Contributor
Jan 2, 2011
6,441
23,040
well that is ****ing crazy. my phone never ever goes into deep doze. how is that possible?
these include stats overnight. I think when I´m at work or keep the phone in my pocket constantly, it won´t enter deep doze much if at all either. (of course as usual depending on usage, if it´s on my desk for 3 hours without being touched it will enter deep doze at one point I guess, but I´m no expert on that)
 
  • Like
Reactions: Utini and xflowy

Top Liked Posts