troubleshooting battery drain: utility for wakelocks - Optimus V Android Development

a tool came out a few months ago that I'd been hoping someone would make
BetterBatteryStats available as a free download from xda or paid from the market
original dev thread here
this should be in any ROM user's toolbag. if you ever follow brandall's tasker tuts he makes on xda he'd had something similar in the works but this is something he's helped on troubleshooting since it took wake lock monitoring that step further.
So if you have battery troubles tend to go this app for troubleshooting apps that may cause unnecessary drain by staying active when your phone is trying to sleep
used it to see com.android.email.email was continuing to run in background and maintaining a partial wake lock. still troubleshooting because I have sync disabled for my email accounts
fyi- Spare Parts doesn't do what this app does. This one actually discerns which apps & services are causing the wake locks

Related

[Q] Battery Drain in Airplane Mode, and even otherwise - Andromadus Mimicry

Hey all,
I have a rooted Desire Z, that's almost 2 years old. I had been using the Virtuous Sense ROM for the most part and had been quite happy with it. Recently, I figured it was time I switched to ICS. So I flashed the Andromadus Mimicry ROM and have been loving it ever since. My only gripe with it is the battery life. I have been meaning to test it out extensively before I could bother the DEV with my nooby queries, but haven't had the time to do so.
When I check Settings > Battery, the screen always seems to be using up most of the %. I have searched through the forums and have done the following, in addition to a few steps that I could think on my own -
Re-calibrated Battery Stats
Clear cache & devklik cache fortnightly
Brightness - Set to 20% (No Auto)
Set to dim after 30 seconds
No render effects (ROM specific I think)
Animations are On.
No Bloatware Installed (Facebook, Twitter, Chrome, etc)
Sync is Auto (I need this)
Froze Google Maps and few other unnecessary background apps that I rarely use with Titanium (using Watchdog to monitor what was eating up CPU)
Disabled Google Backup
Wifi is always Off (I have to depend on 3G for my connectivity needs)
No Battery Saving Apps or Auto Kill Task Managers installed.
News & Facebook widgets set to manual update.
V6 SuperCharger with stock Services.jar.
CPU clock runs @ 245 Mhz on idle, which is most of the time.
GPS is always Off
Google's Location Service (Wifi & mobile network) is On.
Coming to the point, last night the phone was fully charged to 100%. I decided to turn Airplane mode On before I went to sleep to figure the drain in the absence of networks. Woke up to find 78%. That's 2.2% per hour. I checked Better Battery Stats and it seems the phone was awake for the whole ~10 hours. The culprit seems to be GPSLocationProvider. Note that the GPS is Off ; so this has to be the Google's Location Service (Wifi & mobile network)? Disabling this would be inconvenient because it's needed for Weather, and a few other things.
I'm attaching the screens, because I'm pretty new to this and would like to see what people who know more than me have to say about this. A drain of 22% in Airplane mode isn't normal and is crazy, right? Or perhaps,it's time to get a new battery?
PS: The battery has drained a further 20% since the time I took the screenshots, while I was typing this. I merely used the phone for a few messages and to check my mail. (see second-to-last vs last screen)
Radio - 12.56.60.25_26.10.04.03. Signal Strength is usually ~ -89dBm. I have noticed people claiming that the .19 radio is quite battery-friendly but I live in India, so I had to go with the WWE radio that seemed the latest. I didn't think it'd work here. Perhaps I'm wrong?
Any insights offered would be greatly appreciated.
It's an app calling the location services api. Try disabling Facebook and/or whatsapp and see if that helps. I'm unfamiliar with either of those apps, but I've heard nothing but bad things about the Facebook app, so that would be the first one I'd remove to see if it helps.
This goes without saying but of course make sure you've done a full wipe of /data since coming from your old rom. Hope that helps. I'm currently sitting at 12 days since my vision has been unplugged in airplane mode (radio off, wifi off, etc).
Sent from my SAMSUNG-SGH-I747 using xda premium
GPSLocationProvider - Reboot to Fix.
Thanks for your input, blk_jack. I did do a full wipe before migrating. As suggested in your ROM's OP, I don't use the Facebook app. The Facebook entry seen in the screenshot belongs to the Facebook Messenger app, which might partly be the cause. Upon further searching, I found that many people have been complaining about this issue on many different flavors of ROMs (ICS / JB) and hardware (HTC, Samsung, LG). Let me elaborate.
Searching for 'GPSLocationProvider' brings a ton of threads about this issue. I will post here whatever I could gather from these posts, for the benefit of others who face this.
Some people get this wakelock if they use GPS for anything and then turn it off. For example, if you turn on GPS, use a map application for a short while, close the map application and turn off GPS, the wakelock is born. Even if you kill any active map services, it will still be there and ends up draining your battery.
It seems to be chiefly caused by apps that use Location such as Google Maps, Facebook, Facebook Messenger, etc. Turning off all location services is advisable.
In some cases, the GPS does not turn back on until the phone is rebooted but that is not the case in this ROM. GPS works when turned On.
To get rid of the wakelock caused by GPSLocationProvider, rebooting seems to be the only working option as of now.
There is a step-by-step instruction guide (written by Karpfenhai) in the [APP]BetterBatteryStats thread OP, that deals with configuring autostarts, which apparently fixes this issue. I'm yet to try it, so I can't comment if it works or not.
I wish I'd been smarter and searched for 'GPSLocationProvider' instead, before creating this thread. Thanks for your time, anyway.
Screen Off Widget/Shortcut on Desktop?
@blk_jack
If I may use this opportunity to ask you something else related to your ROM.. I just found out that I don't have 10 posts yet, so I can't post it in the ROM thread.
Is it possible to create a widget/shortcut on the desktop to turn off the screen, perhaps by using the Launcher Activity options? I am currently using the one that's there in the Notification Drawer (Power Widget), pulling it down each time to turn the screen off is a tad inconvenient. The desktop Power Widget doesn't seem to have the Screen Off option. Is this possible at all without having to use an external app?
Yep, I have a nova launcher gesture set to run the root app killscreen.apk (search google).
You could add that app to your home screen too.
Sent from my SAMSUNG-SGH-I747 using xda premium

[Q] Short battery life but nothing specific seems to be a big drainer

Hi guys,
Though I have been reading these threads for quite some time now, I just joined so that I can post the issue that I am facing.
I am rooted and using Liquidsmooth v2.4
I am facing a battery issue. Battery life is short. I never survived more than 2 hours of screen time on my device which I know from these forums that is not normal.
The stuff I have tried but didn't help:
Wiped and factory reset on several occasions, both using the settings function and CWM
Flashed various roms (Cyanogen Mod, Carbon, Liquidsmooth, Stock rom)
Unroot to stock and root again
Changed to various more battery friendly CPU governors
Changed battery with a friend who is using the international version (which is using the same battery according to the Samsung website)
I am not in the states now and the local Samsung service centre refused to service it because they don't have the appropriate parts and also due to the difference in software. (I unrooted it and restored to stock before sending in.) They just looked at the model number and refused service; didn't do anything more.
I have attached some screenshots. There are no obvious wakelock issues and no app in particular is draining the battery. 50% power used on screen appears to be normal. The rest of the apps also look like they are behaving themselves, at least power consumption wise. I am not a very heavy user and don't run any games/apps that are huge in resource requirements. Email/facebook/browsing are my main activities.
The current settings on my phone:
Auto brightness
Wifi/bluetooth/GPS all off
Autosync is off by default but will use it sparingly if I need to.
Almost all of my apps have their notifications off and all apps are set to sync manually.
I only have one calender widget on my home screen, no others elsewhere.
CPU Governor is "ondemand", iO scheduler is "row". Min/max freqency: 384/1512 MHz
Juicedefender is enabled with "aggressive" (I know its effectiveness is controversial but on my device, disabling it eats more battery)
Any help is appreciated. "Thanks" will be awarded to all who post!
Thank you!
Hairy07 said:
Hi guys,
Though I have been reading these threads for quite some time now, I just joined so that I can post the issue that I am facing.
I am rooted and using Liquidsmooth v2.4
I am facing a battery issue. Battery life is short. I never survived more than 2 hours of screen time on my device which I know from these forums that is not normal.
The stuff I have tried but didn't help:
Wiped and factory reset on several occasions, both using the settings function and CWM
Flashed various roms (Cyanogen Mod, Carbon, Liquidsmooth, Stock rom)
Unroot to stock and root again
Changed to various more battery friendly CPU governors
Changed battery with a friend who is using the international version (which is using the same battery according to the Samsung website)
I am not in the states now and the local Samsung service centre refused to service it because they don't have the appropriate parts and also due to the difference in software. (I unrooted it and restored to stock before sending in.) They just looked at the model number and refused service; didn't do anything more.
I have attached some screenshots. There are no obvious wakelock issues and no app in particular is draining the battery. 50% power used on screen appears to be normal. The rest of the apps also look like they are behaving themselves, at least power consumption wise. I am not a very heavy user and don't run any games/apps that are huge in resource requirements. Email/facebook/browsing are my main activities.
The current settings on my phone:
Auto brightness
Wifi/bluetooth/GPS all off
Autosync is off by default but will use it sparingly if I need to.
Almost all of my apps have their notifications off and all apps are set to sync manually.
I only have one calender widget on my home screen, no others elsewhere.
CPU Governor is "ondemand", iO scheduler is "row". Min/max freqency: 384/1512 MHz
Juicedefender is enabled with "aggressive" (I know its effectiveness is controversial but on my device, disabling it eats more battery)
Any help is appreciated. "Thanks" will be awarded to all who post!
Thank you!
Click to expand...
Click to collapse
I see horrendous wakelocking. Install BetterBatteryStats. Charge it up for a bit, reboot the phone, then let it idle for a couple hours. Then post screenshots of everything.
It might be the worst I've ever seen. Good news is it's probably not a hardware issue.
It also looks like half the time you had a poor signal. Data transfer on a poor signal can wat at your battery too.
Always use wifi when available.
Sent from my SGH-T999 using xda premium
thanks folks. I've installed better battery stats and will update shots accordingly at the end of the day or end of the battery cycle(probably won't last a day)
Really appreciate the help.
Here are the shots for today.
I rethinked about the poor reception comment and wondered if any of my radios are malfunctioning or if my radios can work in the frequency bands here in Singapore. I called my local service provider to ask about the frequency bands and.it appears that my device's radios can recieve the GSM bands here although they suspect 3G may be an issue. Nothing concrete but I do hope to find out if that could be a possible reason for my battery drain.
I managed to squeeze past 2 hrs of screen time today by using as much wifi as I possibly can. This improvement in battery life probably means that data reception can really be an issue. It's not unlikely that both my home and workplace suffers from.bad reception but i do have a Q. If poor reception is an.issue, will the battery consumption by cell radio sky rocket?
For some reason the previous battery stats screenshots was only for about 5 hrs. i have refreshed and have uploaded the refreshed screenshots
Hairy07 said:
Here are the shots for today.
I rethinked about the poor reception comment and wondered if any of my radios are malfunctioning or if my radios can work in the frequency bands here in Singapore. I called my local service provider to ask about the frequency bands and.it appears that my device's radios can recieve the GSM bands here although they suspect 3G may be an issue. Nothing concrete but I do hope to find out if that could be a possible reason for my battery drain.
I managed to squeeze past 2 hrs of screen time today by using as much wifi as I possibly can. This improvement in battery life probably means that data reception can really be an issue. It's not unlikely that both my home and workplace suffers from.bad reception but i do have a Q. If poor reception is an.issue, will the battery consumption by cell radio sky rocket?
Click to expand...
Click to collapse
This is not BetterBatteryStats. We already know your battery life blows. I want to know why, and BBS will tell me. I can't do a thing for you until you show me that. I think there is a free version on the forums, but it's cheap in the Play Store, and worth it. Get Greenify, too. You're going to need it. Greenify will prevent notifications from showing up for greenified apps. If you don't need notifications from Facebook (honestly, who does?), Greenify it. Maps, too. And disable Juice Defender for now, so I can see what is really happening.
Poor cell reception, if not on wifi, causes drain, yes. It seems to only get really bad when the phone can't hold a data connection.
Try turning off GPS. Also under Settings > Backup and Reset, turn off the Back Up My Data option.
Additionally, check the stickies in this forum. Woody has a fantastic Battery Thread that you should read if you haven't already.
Sent from my SGH-T999 using xda premium
Type betterbatterystats xda on Google. It'll link you to the official thread where you can install the free apk file.
Sent from my SGH-T999 using xda app-developers app
Thanks everyone! I sheepishly searched better battery stats on Google play and.simply installed the first that popped up without looking closely. My bad. I've purchased the app and will post up screenshots soon. I didn't manage to grab the shots today as my batt went flat before I could. Should have kept a better eye.
Will certainly post up screen shots tomorrow.
PS: My GPS has been offed by default. Will disabling Google backup services help?
Hairy07 said:
Thanks everyone! I sheepishly searched better battery stats on Google play and.simply installed the first that popped up without looking closely. My bad. I've purchased the app and will post up screenshots soon. I didn't manage to grab the shots today as my batt went flat before I could. Should have kept a better eye.
Will certainly post up screen shots tomorrow.
PS: My GPS has been offed by default. Will disabling Google backup services help?
Click to expand...
Click to collapse
It cant hurt your battery life! Theres a number of things you can do for settings. Read woodys thread stickied here as its pretty much all there. One of the big batt drainers can be auto brightness btw.
Sent from my SGH-T999 using xda premium
Once you get a good cycle run with BBS, the screen shots we want to see are Since Unplugged/Process and Since Unplugged/Partial Wakelocks. Those two will help tell what is eating your battery and also what is causing all those wakelocks in your original screen shots.
If you are using Juice Defender, that will contribute to the wakelocks (but doesn't keep your device from entering Deep Sleep, so no worries there). I use it, but I have mine set up custom plus have done some basic build.prop edits regarding the RILs and wifi_supplicant_intervals.
My suspicion is that there is a rogue app that is transmitting data somewhere and that is not letting you sleep. If it is transmitting in a poor reception area then that puts ever more strain of things. You are not the first and wont be the last but Doc, Aero and I can help you figure it out.
Images for today. I've included a few more shots for the items that appear lower in the lists.
I've installed greenify but did not add any apps while collecting these data. Juicedefender is also disabled. My screen time was less than 2 hrs.
I did some of the stuff listed in Woody's informative thread. Deleting the tombstone files, lost&found files etc.
Thanks for everyone's help. Hope to solve this issue soon.
Get Greenify from the play store.
Greenify:
Maps
Facebook
Google Now
Take more pictures with BetterBatteryStats tomorrow.
Looks like Maps is misbehaving. Terrible coding is terrible.
Yup. Looks like you are broadcasting your location all over the place. Do you use Maps? If not close it and Greenify it.
Are you getting notifications from Facebook or have a "Check-in" thing going on?
Google Now>Settings> turn off what you don't use.
Settings>Location> Off.
Edit: Tombstones and Lost.dir files are just memory management and have nothing to do with battery.
Shots for today. Things are a little better but looking at my screen usage, maybe there's still a lot of room for improvement.
I've greenified just about all apps that may run in the background. Facebook, Maps, Google+, Gmail, Chrome, Google Search (I converted it into user app), dropbox, etc. Whatsapp, Viber and Wechat are spared as I needed them to be able to notify incoming messages. Juicedefender is on, with advanced settings - set to sync only once an hour. Maps have been set not to update my location although I didn't go to the extent of denying location access ( I use maps fairly often).
All these are rather aggressive steps and I do see improvement. What else can be done? Other than my messengers, all my notifications are essentially off.
Once again, thank you everyone for your time and effort.
Please stop using Juice Defender. I want to see what your battery life looks like without it now. And it's also responsible for the majority of your wakelocks. And if you could get us some ~4 hour idle BBS stats (during sleepy time), that would be fantastic.
Aerowinder said:
Please stop using Juice Defender. I want to see what your battery life looks like without it now. And it's also responsible for the majority of your wakelocks. And if you could get us some ~4 hour idle BBS stats (during sleepy time), that would be fantastic.
Click to expand...
Click to collapse
Noted. I'll charge my phone up and take some shots in the morning. Juicedefender will be disabled and hopefully more information will be revealed. Do today's shots show any improvement?
Hairy07 said:
Noted. I'll charge my phone up and take some shots in the morning. Juicedefender will be disabled and hopefully more information will be revealed. Do today's shots show any improvement?
Click to expand...
Click to collapse
I think you are heading in the right direction (8% deep sleep improvement). For this next test, please disable Juice Defender (don't turn it off through the app, but disable it in the app manager to make sure it can't run). Also, I'm hoping to get a test where the screen isn't on for more than a couple seconds, so I can get an accurate reading on the usage per hour.
I suspect the rest of your issues (bam_dmux_wakelock), are due to a bad cell connection for a good chunk of the time. Connecting to a wifi network will solve that. If you don't have a wifi network, you can turn on airplane mode, or set up some Tasker profiles to help with that.
Out of curiosity, how bright do you have your screen set? Obviously its a big drainer, but it seems like every time your screen is on the batt level plummets.
Sent from my SGH-T999L using xda premium

[GUIDE] Insanely Better Battery Life When Idle - Battery Life Thread

UPDATE: Wanted to add from personal experience that these tricks all work on 4.4 KitKat ROMs. This information isn't stale
This guide should work for any Android phone running any ROM. (Though you do have to be rooted for most of these options. Nothing is THAT simple!)
The goal is to reduce your battery drain when your phone is idle. Nothing in this guide will improve your battery life when the phone is in use. But it will keep the battery from draining quickly (actually it will nearly keep it from draining at all) when the screen it off and the phone is not in use. And the battery savings can be extreme! As I write this guide my phone it has been 4 days, 15 hours, and 9 minutes since I last unplugged my Galaxy S4. I have 33% battery life remaining. You can have this too!
These fixes are not your typical "Lower screen brightness and delete carreir bloatware and disable auto syncing" tips. (Though all that stuff is still a good idea)
You can try all of these techniques or just some of them. Some of them will break features of your phone and might not be good options for you. Only you can decide if these fixes are right for you.
Special thanks for Mike216 and Penko956 for the endless research they did Greenifying, freezing, and disabling they did on just about every system and app on thier phone to see what all could be disabled. And to Torbitege who initially helped figure all this out with me for the HTC Sensation.
First off, what's using your battery?
If you're not already familiar with Better Battery Stats, fix that about yourself. Download it. Use it. Love it.
This app will run in the background constantly monitoring what's using your system resources 24 hours a day. It will tell you what apps are causing wakelocks, which are waking the device, etc etc etc.
The app won't do anything to help your battery life. But it will give you the information you need to adjust problematic apps.
Wakelocks and Battery Drain caused by Google Services
The battery saving impact is major.
This is my personal favorite battery saving technique. But it's not right for everyone, so read thoroughly.
Basically Google thinks your phone belongs to Google. Google Services runs A LOT even when you're not using the phone. This causes a ton of wakelocks and wake ups that use battery. I hate that. So I stopped it with a simple mod to the Google Services Framework.
Here's how....
This is a good old fashioned dirty fix, as it breaks some things. Most push notifications WILL NOT WORK AFTER DOING THIS!!!!! So this is not for everyone!!!! You've been warned. Please don't complain later in the thread that you aren't getting new mail or Twitter or whatever notifications after doing this. You're being told up front they will probably not work.
GTalk and GoogleNow (and maybe a few other things) will not work after doing this. Push notifications for any Google apps will also not work. They are casualties of the dirty fix. But if you're like me and never use GTalk or GNow this will help. Some other Google services might not work after this either. But if you're like me and the only Google service you use is the Play Store app, this will not affect you adversely. (Gmail and Google Maps run independantly of the Google Services framework and are not affected at all by this.)
Use this version of the fix for older Google Service Framework installs. You will know if you have a newer version if doing this install doesnt' prevent your wifi and data icons from turning blue (or whatever color your theme uses). If they turn blue, use the newer version below....
You need to download System Tuner from Google Play. The app will tell you to get Android Tuner instead. Don't do it. It doesn't have what you need. The icon is a blue suitcase with tools on it. Thats' the one you want.
First I froze GTalk and Gnow (Google Search). And no, you can't just freeze those two apps without touching the GSF. The GSF will still create wakelocks when trying to activate them even if they are not there. So you have to modify the GSF as well.
Go to System Tuner and select "Start Ups".
Then pick the Google Services Framework from the list and open it. You shoudl see a list of services.
Uncheck the things on the list below. (Basicall anything with GTalk or Checkin in the title)
gtalkservice.diagnostits.gtalkdiagnostics
gtalkservice.connection autherrordialog
talk.talkprovider
checkin.checinservices$reciever
checkin.checkinservices$triggerreciever
checkin.eventlogservices$receiver
gtalkservice.diagnostics.gtalkdiagnosticsbroadcast reciever
gtalkservice.serviceautostarter
gtalkservices.datamessagereciever
gtalkservice.sendxmppreciever
gtalkservices.packageinstalledreciever
gtalkservice.xmppendpointreciever
checkin.evenlogservice
gtalkservice.service.stalkservice
gtalkservice.pushmessagingregistar
You can freeze the GSF entirely with 1 easy step and that will also kill the wakelocks. But the Play Store becomes another casualty if you do that. Disabling the events above will stop the Google Services wakelocks dead in their tracks, and allow the Play Store to continue working. If you want to go that route you can do it but you'd have to unfreeze the GSF everytime you wanted to update an app.
Newer version if you have updated Google Service Framework.
Freeze the Google Services Framework entirely.
Profit.
Note: I haven't personally tried this and can't attest to it's viability to drawbacks. It was suggested by other members in this thread and confirmed to be working by several other people. Your miliage may vary.
One little quirk with both of the above versions is that when you turn on wifi or mobile data, the signal bars don't turn colors. They stay gray because you aren't connecting to the google servers anymore. (They normally change color to indicate that you are connected to the Google servers). After 1 day I stopped noticing they didn't change colors. Now it looks weird to me when I see them colored.
I highly recommend making a Nandroid backup before trying any of this. Once you go that, go nuts! You can't hurt too much when messing with the GSF because it will just shut down google elements. Worst case, you can always just reactivate everything, reboot, and it'll all work like it did before you messed with it. But if you accidentally disable Android System instead of Google Services, you will probably kill your ROM. So back a backup first.
And severely worst case, if you totally louse up your ROM, just restore the Nandroid and it'll all be back to normal in a flash. (Get it? In a 'flash'...haha I crack myself up)
The Greenify App Sollution
The battery saving impact is moderate.
This is one that you're just silly not to be doing.
Get the Greenify App from The Play Store
There is a free version. But its freakin' awesome so buy the donate version. It's $3 and the developer has more than earned it for the way he's making your phone awesome. (The donate version also includes some special experimental features. Read all about it. Do NOT just get the donate version. You need the free version too.)
This app basically lets your freeze any user app when you're not actively using it. And unfreeze it automatically when you want to open it again.
So if you have an app that likes to wake your device and run itself when you're not using the phone, you can just Greenify it and it will be prevented from using any system resources when you're not actively using the app.
You don't want to Greenify everything. Some apps need to run 24/7 like your messaing app, your phone app, etc. If you Greenify those you won't get messages or calls. The app is incredibly simple to us. You just select the app that's causing trouble and tell Greenify to 'go'. And it does the rest. It's just as easy to un-greenify an app if you greenify something you shouldn't have.
Not every app on your phone needs to be Greenified. Most apps behave themselves. Only do this to the ones that are showing as causing wakes or alarms or wakelocks in a battery monitor like Better Battery Stats.
Two that I will suggest for everyone to start with are Google Maps and T Mobile's My Account app. Both of these love to run when the phone is alseep.
If for whatever reason Greenify those apps hinders the way you use your phone, just ungreenify them! Simple as that.
Google Play Services and You
The battery saving impact is noticable.
Google Play Services wakes the phone a lot. It also does a lot. Read more about what all Google Play Services does here.
You have two options for this one. The first option is the nuclear option. Freeze Google Play Services outright. It will never bother you, but it might break some usefulness of other google apps.
The second option, thanks to XDA Member Karpfenhai , is to disable only certain aspects of the Google Play Services. This one uses the same technique mentioned above in the Google Services Framework Section, just different services to disable. (Thanks to Perseus71 for making me aware of this one and asking that it be included!) THIS HAS BEEN RECENTLY UPDATED
NEW PROBLEM AS OF MARCH 2015
The battery saving potential is ABSOLUTELY REQUIRED!
Since Google updated Play Services all hell has broken loose on custom roms. You get a persistent and unkillable wakelock for SystemUpdateManager.
The battery drain is horrendous. Your phone is awake and active 100% of the time.
This affects GPS version 7.0.97
I fixed this by going to the permissions manager (built into many aosp roms. If not available in your rom, consult yoir rom thread for ways to alter permissions) and disabling the permission in Google Play Services for "wake" and "keep awake".
Note: Some phones only show "keep awake". Just do that one if that is the case.
The problem is that on custom roms no ota is available. But Google tries to get it anyway. When it fails it doesn't shut down. It just keeps trying.
If the permissions method doesn't work, try this...
http://forum.xda-developers.com/general/general/fix-fix-systemupdateservice-wakelock-t3060548
I
Just so you don't think I'm kidding around when I say you can severely increase your battery drain when idle, take a look at tehse screen shots from my Galaxy S4.
My specific set up is running CyanogenMod 10.1 nightlies with ChronicKernal. I haven't been using my phone much over the past 4 days. I have a total of 2 hours and 34 minutes screen on time and 40 minutes of phone calls during that period. So this is admittedly very light usage. But that's perfect to show you that these techniques really work to minimize battery drain when the phone is idle. And I promise you that your results will vary based on your ROM and Kernel.
This won't make the battery last longer during use. The screen will still burn a lot of battery and the cell radio does too. But if you want to make sure your phone will be charged when you need it without you having to carry a charger with you everywhere you go, these are the mods for you.
As you can see from these screen shots I am at 4 days, 16 hours, 50 minutes since unplugging. I have 31% battery left. (That's what the 31 in the upper left corner is. Thats' from an app called Big Battery Notifier. Its free on Play.)
The other screenshot is from Better Battery Stats showing my Alarms screen. Alarms are loosely the same as wakes. Everytime an app wakes the device (not neccessarily turning the screen on) it will record an alarm. If you look at your BBS alarms screen without these modifications I bet you see a lot more alarms than you see here, and keep in mind that mine screen show is showing 4 and a half days worth. Each one of those represents an app or service waking the device and using battery.
If the written instructions somehow baffle you, here's a video of the whole thing!
http://www.youtube.com/watch?v=cUBpOl77Tm4
This will show you step by step how to do all of this.
Thanks to XDA Member Chaitanyapatel8880 for his work in putting this video together
Just a note. If you convert Google Play Services to a User App (TB), you can then Greenify (free ver.) it. This works very well and does not affect other functions that may rely on that app.
I also Greenify Maps and Google Search. Two more heavy drainers. Convert to User App first.
*Note: You must use Greenify v1.82 to Hibernate Google Play Services! Search this thread for links to it.
Fwiw, my sleep drainage is 0.3 - 0.4%hr, with wifi on 24/7.
I get either 7-8 days standby, or so far, 5.5 days with 3.5 hours screen time, or likely 6-7hrs screen time single day. Screen shots are in my posts.
I would argue too that these settings/tweaks do indeed increase your battery time, since while sleeping, the battery is draining at a much lower rate, therefore keeping more juice for live time use.
Although you and I don't use all of the same "tweaking" programs, we do seem to be on the same mission. Better battery life! :good:
Pinan said:
Just a note. If you convert Google Play Services to a User App (TB), you can then Greenify (free ver.) it. This works very well and does not affect other functions that may rely on that app.
I also Greenify Maps and Google Search. Two more heavy drainers. Convert to User App first.
Fwiw, my sleep drainage is 0.3 - 0.4%hr, with wifi on 24/7.
I get either 7-8 days standby, or so far, 5.5 days with 3.5 hours screen time, or likely 6-7hrs screen time single day. Screen shots are in my posts.
I would argue too that these settings/tweaks do indeed increase your battery time, since while sleeping, the battery is draining at a much lower rate, therefore keeping more juice for live time use.
Although you and I don't use all of the same "tweaking" programs, we do seem to be on the same mission. Better battery life! :good:
Click to expand...
Click to collapse
I like your way of dealing with Google play services. I'll change the op later.
That doesn't break function of the play services to run as a user app?
Sent from your phone. You should be careful where you leave that thing.
Skipjacks said:
I like your way of dealing with Google play services. I'll change the op later.
That doesn't break function of the play services to run as a user app?
Click to expand...
Click to collapse
I have not noticed any dysfunction, though there are likely some things I don't use. But for me it's been completely functional.
Besides, if I froze it, I'd have none of it's functions at all.
Pinan said:
Just a note. If you convert Google Play Services to a User App (TB), you can then Greenify (free ver.) it. This works very well and does not affect other functions that may rely on that app.
I also Greenify Maps and Google Search. Two more heavy drainers. Convert to User App first.
Fwiw, my sleep drainage is 0.3 - 0.4%hr, with wifi on 24/7.
I get either 7-8 days standby, or so far, 5.5 days with 3.5 hours screen time, or likely 6-7hrs screen time single day. Screen shots are in my posts.
I would argue too that these settings/tweaks do indeed increase your battery time, since while sleeping, the battery is draining at a much lower rate, therefore keeping more juice for live time use.
Although you and I don't use all of the same "tweaking" programs, we do seem to be on the same mission. Better battery life! :good:
Click to expand...
Click to collapse
How do I convert those services to user apps?
Sent from my SGH-M919 using xda app-developers app
rodny23 said:
How do I convert those services to user apps?
Sent from my SGH-M919 using xda app-developers app
Click to expand...
Click to collapse
Titanium Backup will do it, I think you need the paid version though.
/System/App Mover is also good app for doing it. It's free on Google Play.
Dang right now Google services is at 41%
Sent from my SGH-M919 using xda app-developers app
Skipjacks said:
Titanium Backup will do it, I think you need the paid version though.
Click to expand...
Click to collapse
Yup. I think you're right.
Something disabled notifications for instagram, etc.
Sent from my SGH-M919 using xda app-developers app
kevinrubio1 said:
Something disabled notifications for instagram, etc.
Sent from my SGH-M919 using xda app-developers app
Click to expand...
Click to collapse
Did you Greenify Instragram? If yes, that explains why you aren't getting notifications.
lordcheeto03 said:
Did you Greenify Instragram? If yes, that explains why you aren't getting notifications.
Click to expand...
Click to collapse
Nope, it's something in system tuner, I unchecked all the "checking" things so it's one of the "gtalk" options. I'm narrowing it down
Sent from my SGH-M919 using xda app-developers app
This has saved a bunch of us from odd battery drain. Skipjacks has been there and done that. Amazing informative thread! Going on two weeks without having to worry about bringing my charger to work thanks to skip
SGH-M919_Omega, the end result
kevinrubio1 said:
Nope, it's something in system tuner, I unchecked all the "checking" things so it's one of the "gtalk" options. I'm narrowing it down
Sent from my SGH-M919 using xda app-developers app
Click to expand...
Click to collapse
I don't believe it. Instagram is its own thing. It shouldn't be reliant on the google services framework at all.
Sent from my SGH-M919 using xda app-developers app
Pinan said:
Just a note. If you convert Google Play Services to a User App (TB), you can then Greenify (free ver.) it. This works very well and does not affect other functions that may rely on that app.
I also Greenify Maps and Google Search. Two more heavy drainers. Convert to User App first.
Fwiw, my sleep drainage is 0.3 - 0.4%hr, with wifi on 24/7.
I get either 7-8 days standby, or so far, 5.5 days with 3.5 hours screen time, or likely 6-7hrs screen time single day. Screen shots are in my posts.
I would argue too that these settings/tweaks do indeed increase your battery time, since while sleeping, the battery is draining at a much lower rate, therefore keeping more juice for live time use.
Although you and I don't use all of the same "tweaking" programs, we do seem to be on the same mission. Better battery life! :good:
Click to expand...
Click to collapse
I'm not sure whether Greenifying Google Search would save as much battery as freezing it would, but I'm going to try it out and see how it works for me. I'll report back some results in case anyone is curious
funkl3 said:
I'm not sure whether Greenifying Google Search would save as much battery as freezing it would, . .
Click to expand...
Click to collapse
It does. It also allows other functions to still work such as TTS. I had the issue a while back. Something to do with shared voice.
I also freeze Contacts and Calendar syncs as well. If I want them to sync I simply thaw them for a few seconds.
Skipjacks said:
I don't believe it. Instagram is its own thing. It shouldn't be reliant on the google services framework at all.
Sent from my SGH-M919 using xda app-developers app
Click to expand...
Click to collapse
Maybe one of the "gtalk" options has something to do with notifications because last night I rebooted my phone a lot checking/unchecking options, none of the "checking" did anything! So that's good, and I unchecked some gtalk but not all and it worked!
Sent from my SGH-M919 using xda app-developers app
Great guide! A little bitter I had to read all of the pages in the original topic :laugh:
Skipjacks said:
I like your way of dealing with Google play services.
Click to expand...
Click to collapse
Btw. I forgot to mention that after I reboot the first thing I do is turn off Google Play in Running Programs. Persistent bugger. And of course I turn off notifications and auto update in GP as well with each new ROM install.
My tweak list is extensive. Someday I'll right it all down as you have. Save me some thinking, LOL.

My phone is working on 384 MHz instead of Deep Sleep

Yesterday i installed CM 10.1.3 from official cyanogenmod site. First few hours i had big battery drain and i saw that the phone isn't going into DEEP SLEEP but only at 384 MHz. I thought that some app is staying on even with locked screen so i downloaded Clean Master and set it to kill apps when screen is off and also i clicked on "don't keep activities" from dev.options menu.
I discovered one bug on this rom - the NFC cannot shut down, is it possible to stay at 384 MHz just because my NFC is always on? If not, give me some suggestion please
qtoo941 said:
Yesterday i installed CM 10.1.3 from official cyanogenmod site. First few hours i had big battery drain and i saw that the phone isn't going into DEEP SLEEP but only at 384 MHz. I thought that some app is staying on even with locked screen so i downloaded Clean Master and set it to kill apps when screen is off and also i clicked on "don't keep activities" from dev.options menu.
I discovered one bug on this rom - the NFC cannot shut down, is it possible to stay at 384 MHz just because my NFC is always on? If not, give me some suggestion please
Click to expand...
Click to collapse
Get rid of clean master. Get gsam and cpuspy from playstore. Sounds like you have cpuspy or something similar.....but gsam can tell you what is keeping your device awake. Then you can deal with it....or search on the app keeping device awake and find fix.
Sent from my Nexus 7 using xda app-developers app
I don't know if NFC would prevent deep sleep, or if clean master would help ( I'd uninstall it ), but I've spent a lot of time researching battery life fixes, so here's some tips:
1. Get the Better Battery Stats app - it's essential. You're most likely going to look under the Partial Wakelocks section from the dropdown. That'll help you narrow down which apps are keeping the device awake. Kernel Wakelocks are important too, but require some research into what stuff means. Select your reference point ( Boot, Unplugged, etc. ), then try to avoid using your phone for a couple of hours from that event at least before checking this app to get better results of what's causing issues.
2. After finding which apps are problematic, you can uninstall them, freeze them, or do the following if you prefer to keep using them without hurting your battery as much:
Install Greenify and hibernate the problematic apps. Hibernating an app prevents it from running unless you start it.
For extra measure, also get ROM Toolbox ( not sure if you need the pro version ), go to "Auto Start Manager", and uncheck certain things for apps ( like Facebook auto starting on location change, for example ) to lessen app wakelocks. You can also use the paid AutoStarts app in the market with the red car icon if you prefer something simpler.
**Note: disabling certain autostarts can break a function of an app, or the whole app, until you enable it again, so be wary of that**.
3. I don't believe this is even an issue anymore, but some roms had issues going into deep sleep on multi-core devices. Eugene373's CPU Sleeper should fix that. I haven't looked into this much though, so not sure whether it works or not.
4. I found this thread on the Skyrocket forums really useful when my phone was losing battery while charging: http://forum.xda-developers.com/showthread.php?t=1759541 .
Also, to save more battery, keep your screen at dimmest system brightness when you can, and turn off sync, data, & WiFi if you don't need it. GPS *should* be okay on all the time, because from what others say, GPS only wastes battery if an app is using it, so if you deal with the app, the GPS is fine.
tl:dr;
Not sure if NFC prevents sleep or if clean master helps. Use Better Battery Stats to find wakelocks. Use Greenify to hibernate problem apps. Use ROM Toolbox's "Auto Start Manager" or AutoStarts to stop problem apps from auto starting.
Oh....another long time habit I have is to reboot after you unplug from charger....every time! This used to be a common fix.....and I still do it.
Sent from my Nexus 7 using xda app-developers app
kj2112 said:
Oh....another long time habit I have is to reboot after you unplug from charger....every time! This used to be a common fix.....and I still do it.
Sent from my Nexus 7 using xda app-developers app
Click to expand...
Click to collapse
I tried your trick but it didn't work
Anyway, i downloaded GSAM Battery Monitor and also Greenify. I stayed like 1 hour and after that i opened GSAM and there was information that my battery drain is caused of Media Service. "Downloads" system app is working in background and it is preventing my phone to get into Deep Sleep. I tried to add downloads system app into Greenify but for this thing i need to get paid version .. anyway, i will not pay it
What to do now, at least now i know why i cannot enter in deep sleep - because of downloads system app ^_^
qtoo941 said:
I tried your trick but it didn't work
Anyway, i downloaded GSAM Battery Monitor and also Greenify. I stayed like 1 hour and after that i opened GSAM and there was information that my battery drain is caused of Media Service. "Downloads" system app is working in background and it is preventing my phone to get into Deep Sleep. I tried to add downloads system app into Greenify but for this thing i need to get paid version .. anyway, i will not pay it
What to do now, at least now i know why i cannot enter in deep sleep - because of downloads system app ^_^
Click to expand...
Click to collapse
Titanium backup can convert any system app to a user app. Then greenify will see them. The catch 22 may be that it only works on titanium backup pro version. LOL
But check and see!
Sent from my cellular telephone
My note3 also had a deep sleep lack this week. The culprit was Clean Master itself. Probably they messed up something with the last update. Beware.

[Q] Battery drain on Note 2 after 4.3 update

Hello
I have had a massive battery drain problem on my Note 2, a couple of days after the 4.3 update. While being idle during the night it loses 25% to 30% of its battery and while using it I can literally see the percentage drop. I have tried everything that I could find on the net. EVERYTHING! Nothing worked. These included: Factory reset (twice), letting the battery frain completely and then recharging it while the phone was switched off, switching off all sync,disabling bloatware including KNOX components (the actual KNOX app is not installed), installing only a few apps after factory reset, using Gsam, Wakelock detector, Deep sleep battery saver (which could not make my phone sleep), no GPS, no 3G, wifi on only when needed and more besides.
The phone is only one year old and unrooted. On 4.1.2 it had a beastly battery performance of almost 1.5 days of normal to heavy use, with 300 apps on it. Now it cannot go for more than a few hours with the same use.
I cannot say for sure but it seems to me that the drain is the same when it is sleeping and when I am using it. Wakelock has given me a 75% awake time even though I only use it for 15-20% of the day at most nowadays. Battery settings show everything normal, or at least I think so, eg Screen 35%, Android OS 15-28%, Voice calls 10%, Android system 5-15%, Cell standby 7%, Device idle 4%, Media server 4%. The batttery chart shows a constant steep drop all the time.
The problem started one day when the Media server went mad consuming 50% of the battery. After I did the factory reset it has never again been a problem but the drain still persists.
I have also read that it's a mess up between syncing of Samsung apps and Google services, but I have no way of verifying that.
Can anyone help?
Thanks
I had the very same problem until yesterday myself but think I found a solution on the web.. Uninstall Google Search and Google Play Services and the goto the Play Store and wait for them to reinstall and that's it....! As I found that there is a bug in Google Services (Nlpwakelock and Location service)
Hope this helps...?
Sent from my GT-N7100 using xda app-developers app
terzisc said:
Hello
I have had a massive battery drain problem on my Note 2, a couple of days after the 4.3 update. While being idle during the night it loses 25% to 30% of its battery and while using it I can literally see the percentage drop. I have tried everything that I could find on the net. EVERYTHING! Nothing worked. These included: Factory reset (twice), letting the battery frain completely and then recharging it while the phone was switched off, switching off all sync,disabling bloatware including KNOX components (the actual KNOX app is not installed), installing only a few apps after factory reset, using Gsam, Wakelock defender, Deep sleep battery saver (which could not make my phone sleep), no GPS, no 3G, wifi on only when needed and more besides.
The phone is only one year old and unrooted. On 4.1.2 it had a beastly battery performance of almost 1.5 days of normal to heavy use, with 300 apps on it. Now it cannot go for more than a few hours with the same use.
I cannot say for sure but it seems to me that the drain is the same when it is sleeping and when I am using it. Wakelock has given me a 75% awake time even though I only use it for 15-20% of the day at most nowadays. Battery settings show everything normal, or at least I think so, eg Screen 35%, Android OS 15-28%, Voice calls 10%, Android system 5-15%, Cell standby 7%, Device idle 4%, Media server 4%. The batttery chart shows a constant steep drop all the time.
The problem started one day when the Media server went mad consuming 50% of the battery. After I did the factory reset it has never again been a problem but the drain still persists.
I have also read that it's a mess up between syncing of Samsung apps and Google services, but I have no way of verifying that.
Can anyone help?
Thanks
Click to expand...
Click to collapse
Download wakelock detector from the play store. It detect which app is waking your device (both screen and cpu) by list.. Then download greenify from the play store and herbinate (greenify) upper most apps from wakelock detector. Hope you can solve your problem
Sent from my GT-N7100 using XDA Premium 4 mobile app
yeminswe said:
Download wakelock detector from the play store. It detect which app is waking your device (both screen and cpu) by list.. Then download greenify from the play store and herbinate (greenify) upper most apps from wakelock detector. Hope you can solve your problem
Sent from my GT-N7100 using XDA Premium 4 mobile app[/
Thanks. I already have Wakelock Detector on. I mistakenly wrote "defender" instead of detector on the original post. It gives me Viber and Messenger as the most active wakelock apps. But they both were not installed when the problem started. Besides, on the 4.1.2 they created no problems. In essence I believe that Wakelock Detector cannot help much. Whatever this problem is , it is well hidden. Thanks for your interest and help anyway. Much appreciated.
Click to expand...
Click to collapse
In wifi settings, goto advanced and untick scanning always available.
Sent from my GT-N7100 using Tapatalk
Manjunath324 said:
In wifi settings, goto advanced and untick scanning always available.
Sent from my GT-N7100 using Tapatalk
Click to expand...
Click to collapse
Thanks, but I have checked and it was not ticked in the first place...unfortunately...
terzisc said:
Thanks, but I have checked and it was not ticked in the first place...unfortunately...
Click to expand...
Click to collapse
Which kernel you are using? And also i recommend using Greenify. Widgets usually eat a lot of battery, I went from battery lasting only 8 hours to get my battery use only 30% in 8 hours.
What i did: installed wakelock detector, gsam battery monitor and better battery stats.
Monitorized the wakelocks.
Applied greenify to the apps which were waking most
Removed widgets which were waking alot
Installed Toggle 2G.
Kernel settings: 200-1600mhz | zzmoove | AFTR+LPA | Multicore power saving (SCHED_MC) = 0 | GPU = stock settings
Works like a charm for me. Hope it helps! Any question, ask!
I've read all sorts of things about this problem since I updated and got hit. I have too much app data to lose by trying the factory restore (which by all accounts shouldn't change anything anyway since you'd still be stuck with 4.3)
I finally decided to try the age old blackberry cure-all: "if in doubt, pull it out" (the battery). Since the entire issue seemed to be related to battery caused problems (ie slow charging, fast drain, etc) it made a lot of sense.
And it worked.
I think the main reason this isn't more commonly tried to fix issues on Android is the same reason I didn't try it earlier. My case is pretty serious and isn't easy to remove. I'm glad I did take the time to take the case off though or I could have ended up wiping my phone.
Nukkels said:
I've read all sorts of things about this problem since I updated and got hit. I have too much app data to lose by trying the factory restore (which by all accounts shouldn't change anything anyway since you'd still be stuck with 4.3)
I finally decided to try the age old blackberry cure-all: "if in doubt, pull it out" (the battery). Since the entire issue seemed to be related to battery caused problems (ie slow charging, fast drain, etc) it made a lot of sense.
And it worked.
I think the main reason this isn't more commonly tried to fix issues on Android is the same reason I didn't try it earlier. My case is pretty serious and isn't easy to remove. I'm glad I did take the time to take the case off though or I could have ended up wiping my phone.
Click to expand...
Click to collapse
Thank you for the suggestion. I have already taken the battery on and off several times. It had no improvement. The phone is only a year old, that is why I don't believe the battery is the culprit. Besides, problems started only after the 4.3 update. Before that it was working perfect. Too much of a coincidence.
Sorry to hear that it didn't work for you
I'm not saying the battery is faulty in any way - however removing the battery and letting the phone power drain completely seems to stop whatever process is running under the buggy 4.3 long enough for it to work again as intended. It's basically just a more thorough way to reboot.
As I said, I've read all sorts of suggestions, many of which don't work for everyone (such as the factory reset) - this is hopefully just one more thing for people to try before they end up wiping their phone in desperation. I mainly posted here in the hopes that others with this issue that may not be forum members can get some more suggestions.
At least for me, wakelock and all the other diagnostic tools at my disposal showed nothing different to before the update. Many other people have found that the Android System is using a lot more of their battery than normal or some other apps are involved - if this is the case, it's likely to be a combination of things causing the issue (the firmware, the drivers, apps, hidden Samsung processes, etc).
Also, for what it's worth, I found that Knox supposedly wasn't installed (when I find it in the apps list, the button to install it is showing...). But it's showing in the list of apps so it must already be installed. I dug through the list of running processes (had to show the system processes too) and I discovered that several Knox and some other new Samsung processes were indeed running.
One other quick tip - If you wanted to check/tweak the 'developer options' and can't seem to find it any more, that's because it's now hidden since 4.2 - go to 'About Device' and tap 7 times on the Build Number. I tried disabling all background processes however it seems this only disables application level processes, not system level processes but if you've tried everything else, it can't hurt to try playing around with some of the options in there.
Nukkels said:
Sorry to hear that it didn't work for you
I'm not saying the battery is faulty in any way - however removing the battery and letting the phone power drain completely seems to stop whatever process is running under the buggy 4.3 long enough for it to work again as intended. It's basically just a more thorough way to reboot.
As I said, I've read all sorts of suggestions, many of which don't work for everyone (such as the factory reset) - this is hopefully just one more thing for people to try before they end up wiping their phone in desperation. I mainly posted here in the hopes that others with this issue that may not be forum members can get some more suggestions.
At least for me, wakelock and all the other diagnostic tools at my disposal showed nothing different to before the update. Many other people have found that the Android System is using a lot more of their battery than normal or some other apps are involved - if this is the case, it's likely to be a combination of things causing the issue (the firmware, the drivers, apps, hidden Samsung processes, etc).
Also, for what it's worth, I found that Knox supposedly wasn't installed (when I find it in the apps list, the button to install it is showing...). But it's showing in the list of apps so it must already be installed. I dug through the list of running processes (had to show the system processes too) and I discovered that several Knox and some other new Samsung processes were indeed running.
One other quick tip - If you wanted to check/tweak the 'developer options' and can't seem to find it any more, that's because it's now hidden since 4.2 - go to 'About Device' and tap 7 times on the Build Number. I tried disabling all background processes however it seems this only disables application level processes, not system level processes but if you've tried everything else, it can't hurt to try playing around with some of the options in there.[/Q
Thanks mate
I think you are right. It is probably a combination of many things. I have opened the Developer options some time back. The one thing that I do for sure in there is limit background processes to 4. Besides that I don't experiment much, exept maybe to change transition animation scale. I am actually thinking of rooting the phone and downgrading to 4.1.2. It was just fine before. I can live without the 4.3 add ons.
Click to expand...
Click to collapse
Problem still persists, even with Google+ and most other Google applications disabled

			
				
Sent from my GT-N7100 using xda app-developers app Some screenshots taken from 3 different apps. Wakelock detector, Better battery stats and Gsam battery monitor
Sent from my GT-N7100 using xda app-developers app
The only battery apps on my phone are the 3 mentioned above, so I don't know what the battery monitor that keeps my phone awake is. The drain existed before I installed these apps. I have read that Chrome could prevent the phone from going to sleep but it is disabled on my phone.
Sent from my GT-N7100 using xda app-developers app
http://www.youtube.com/watch?v=ak1sYWRaEKg
I faced same battery drainage issue, after installing wanam kernel and freezing all bloatwares through Titanium Backup. I'm satisfied with my battery now.
You can try.
Sent from my GT-N7100 using XDA Premium 4 mobile app
Here is detail-
Disable sync always, enable when needed.
Disable wifi always scan from settings
Display set to auto
Uninstall apps of playstore you rarely use
Use widgets on lock and homescreen as less as you can (I don't use any)
Disable motion on settings
Freeze all bloatwares by TB except allshare and samsung content agent
Install Agni kernel, from agni control app-
profile: normal
Governor: pegasusq
Scheduler: cfq
Don't touch other tweaks, hardly you can tweak sound boost.
THIS GIVES ME A SATISFIED BATTERY STATUS.
regards.
Sent from my GT-N7100 using XDA Premium 4 mobile app
Wew 4.3 does have may bugs

Categories

Resources