Click here to Skip to main content
15,896,207 members

Comments by NormR1 (Top 4 by date)

NormR1 16-Oct-14 7:50am View    
The program continues to work differently each morning. Yesterday morning it worked as desired. This morning there was a delay in starting the service after I rotated the tablet. Why would the Android system restart my service when I lifted and rotated the tablet? My service should have been executing and receiving Sensor values which it would use to turn on the screen.
NormR1 13-Oct-14 7:19am View    
How is the weather now?
NormR1 10-Oct-14 12:32pm View    
How is the weather now? Any suggestions for How do to find the bug?
NormR1 8-Oct-14 18:18pm View    
Thanks for the response.
It's a very elusive bug. The code works so many times and fails so few times that I'm not able to come up with a debugging scheme to find out a reason or pattern for the failure.
Do you have any suggestions?

Something I've observed by looking at the logs is that the system restarts my service (passing a null intent to the onStartCommand() method) very soon after I have plugged in the tablet to turn on the screen. How would a bug in my code cause that?

Another observation: the system often restarts my service 5 seconds after the AlarmReceiver is supposed to receive an alarm: at 22:00:05 for an alarm set for 22:00:00.