As of IPhone OS 3.0, MotionX GPS is able to keep recording a GPS track while in sleep mode. After you push the sleep button on top of the phone, the app continues receiving GPS coordinates and recording them. Does anyone know how they're able to do this? I'm only aware of the method to keep running audio while in sleep mode.
Running IPhone apps while in sleep mode
I found a great webpage that explains how to do it -
Cached link from Wayback machine
You have to start a timer that plays a sound every 10 seconds. But the sound can be silent.
this is an cool trick, it solves a real problem, and it seems to work for me as well. i'm a little surprised that and app that used this technique would get approved for the app store though, this seems like the kind of thing that might get an app rejected. –
Pillion
Above link is dead. –
Sepaloid
Added a cached version of the link above –
Humanize
[UIApplication sharedApplication].idleTimerDisabled=YES should do it
THis works to prevent sleep from idleness, but doesn't work if they hit the lock button. MotionX is able to work after hitting the lock button, and it turns the screen off. –
Grimsby
I heard that the [UIApplication sharedApplication].idleTimerDisabled=YES
will leave the screen's background light on, (after the user pressed the sleep button,) which will drain the battery.
But I have not tried this myself, so anybody with experiences correct this if it is wrong.
This stops the iphone from getting bored and locking on its own, but it does not prevent the user from physically pressing the sleep button and putting the device to sleep. –
Mefford
© 2022 - 2024 — McMap. All rights reserved.