Introducing XDA:DevCon – A Conference For Developers By Developers
XDA Developers Android and Mobile Development Forum
Forgot your password?
 
Post Reply+
Tip us?
 
Simba501
Old
(Last edited by Simba501; 17th March 2012 at 12:36 PM.)
#1  
Simba501's Avatar
Recognized Contributor - OP
Thanks Meter 943
Posts: 2,764
Join Date: Feb 2010

 
DONATE TO ME
Default [Q] Question about a wakelock (Ouch) [Solved]

Take a look at my wakelocks. For some reason, calendar is holding one entirely too long. My Gmail wakelock seems a little high too, but not out of the ordinary (I receive and send a lot of emails during the day). I noticed the calendar wakelock when it was at 37 minutes. I thought it may have been because I leave calendar notifications in the status bar. Cleared them - no luck, still holding it. Went to calendar settings and turned off notifications - no luck, still holding it. Weird thing is my battery life has still been pretty good, but my device shouldn't be working that hard, for that long.

Does anyone know what "StartingAlertService" (associated with calendar) is? I need some help in pinpointing exactly how to stop this wakelock. Not using the calendar (or using an alternate one) is not an option.

Solution:
Quote:
Originally Posted by rodries View Post
. . .

The problem is in TouchWizCalendar.apk not releasing the wakelock properly in class ServiceHandler inside class AlertService

. . .
The touchwiz calendar from his thread fixes the problem. It will work on any Samsung-based rom, 9100 hellraised or i777 bases.
Attached Thumbnails
Click image for larger version

Name:	SC20111004-133729.jpg
Views:	272
Size:	38.1 KB
ID:	739993  
 
Entropy512
Old
#2  
Elite Recognized Developer
Thanks Meter 20795
Posts: 11,493
Join Date: Aug 2007
Location: Owego, NY

 
DONATE TO ME
Quote:
Originally Posted by Simba501 View Post
Take a look at my wakelocks. For some reason, calendar is holding one entirely too long. My Gmail wakelock seems a little high too, but not out of the ordinary (I receive and send a lot of emails during the day). I noticed the calendar wakelock when it was at 37 minutes. I thought it may have been because I leave calendar notifications in the status bar. Cleared them - no luck, still holding it. Went to calendar settings and turned off notifications - no luck, still holding it. Weird thing is my battery life has still been pretty good, but my device shouldn't be working that hard, for that long.

Does anyone know what "StartingAlertService" (associated with calendar) is? I need some help in pinpointing exactly how to stop this wakelock. Not using the calendar (or using an alternate one) is not an option.
Man that's weird... High sync wakelock usage seems like what I call "gmail weak-signal battery rape". Battery would start dropping like a rock if the phone lost signal at certain points during the sync cycle without the cpuidle fix. Things got much better after implementing the cpuidle fix in the kernel, but drain would still be much higher than normal. However your calendar wakelock doesn't seem to be related to sync. I suggest Googling it, or try temporarily disabling calendar sync.

Does this only happen when in weak signal areas?
*so much sig updating needed*

My Github profile - Some Android stuff, some AVR stuff

An excellent post on "noobs vs. developers"

A few opinions on kernel development "good practices"

Note: I have chosen not to use XDA's "friends" feature - I will reject all incoming "friend" requests.

Code:
<MikeyMike01> Smali is a spawn of hell
<shoman94> ^^^ +!
Code:
<Entropy512> gotta be careful not to step on each other's work.  :)
<Bumble-Bee> thats true
<jerdog> compeete for donations
 
Simba501
Old
(Last edited by Simba501; 4th October 2011 at 09:04 PM.)
#3  
Simba501's Avatar
Recognized Contributor - OP
Thanks Meter 943
Posts: 2,764
Join Date: Feb 2010

 
DONATE TO ME
Quote:
Originally Posted by Entropy512 View Post
Man that's weird... High sync wakelock usage seems like what I call "gmail weak-signal battery rape". Battery would start dropping like a rock if the phone lost signal at certain points during the sync cycle without the cpuidle fix. Things got much better after implementing the cpuidle fix in the kernel, but drain would still be much higher than normal. However your calendar wakelock doesn't seem to be related to sync. I suggest Googling it, or try temporarily disabling calendar sync.

Does this only happen when in weak signal areas?
I know, I thought the same thing. I'll keep looking around. It finally stopped at 1 hr 14 mins of wakelock. I hadn't figured out anything else to change so it stopped on its own. If it picks back up again, I'll disable sync in an attempt to gather more information. I've been in a pretty weak signal area for most of the day. I'll monitor it when in other coverage situations.


Update: So I found a HTC Hero thread over a year old over at AndroidForums and it appears that the remedy is to clear data of the calendar application (there were 3 in manage applications that were associated with calendar, so I cleared them all) and re-sync. I had to uncheck and recheck the sync option for Google Calendar, which is what brought my events back. Like I mentioned, the wakelock ended up stopping on its own, but hopefully this will prevent it from occurring again.

Quote:
Originally Posted by cjberg @ AndroidForums
I was having the same problem. I rebooted the phone, went in to the manage applications list and hit clear cache and clear data in the calendar app. Then I went to accounts & sync and re-synced the calendar and it has been working fine ever since. I also use spare parts to monitor the battery useage and awake time, so I can see if it ever pops up again. Been about a week now and the calendar is not keeping my phone awake any longer.
Solution thread link
 
Entropy512
Old
#4  
Elite Recognized Developer
Thanks Meter 20795
Posts: 11,493
Join Date: Aug 2007
Location: Owego, NY

 
DONATE TO ME
OK, so it was a variation on sync battery rape.

I know if you have a Google service that doesn't seem to be syncing reliably (missing events in Calendar, missing emails in Gmail), clearing data for that app usually fixes it.
*so much sig updating needed*

My Github profile - Some Android stuff, some AVR stuff

An excellent post on "noobs vs. developers"

A few opinions on kernel development "good practices"

Note: I have chosen not to use XDA's "friends" feature - I will reject all incoming "friend" requests.

Code:
<MikeyMike01> Smali is a spawn of hell
<shoman94> ^^^ +!
Code:
<Entropy512> gotta be careful not to step on each other's work.  :)
<Bumble-Bee> thats true
<jerdog> compeete for donations
 
foxbat121
Old
#5  
Senior Member
Thanks Meter 195
Posts: 2,503
Join Date: Apr 2006
I have the similar issue but uncheck the calendar sync for my Hotmail solves the problem (just as it did on my Captivate 2.3 ROM). I can't believe Samsung hasn't address the Hotmail calendar sync bug yet.
 
Post Reply+
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Go to top of page...