In order to minimize battery impact on the device when recording a track while the screen is off, MyTrails uses the standard method offered by Android where the application is woken up by the OS only when a new track point is ready to be recorded.
The top reasons for this are:
- Android Marshmallow and later have the ability to stop background apps (to save battery) when the device is not moving. This shouldn’t affect MyTrails, except some versions of Android do this incorrectly and also stop apps when you’re hiking. In these cases, allowing MyTrails to keep running in the background may help: Android Settings > Apps > gear icon (Configure apps) > Battery optimization > All apps > MyTrails > Don’t optimize. Because this is a bit convoluted, I made short animation below.
- Similarly, some customized Android versions such as Samsung’s include an Energy Saver feature that disables background GPS. Please check that it is disabled (it sometimes becomes enabled after a system update).
- DontKillMyApp.com lists detailed steps to fix this for the various device manufacturers. Please check this first if you have this problem.
- More info compiled by another GPS tracker app, Strava.
Other things you can try:
- On some phones, Android may occasionally lose track of this, and forget to wake MyTrails up. This would result on a track where no recording takes place during some stretches where the screen was off. Because this is a platform bug and so far has been reported only once, I do not intend to add a potentially harmful work-around to MyTrails.
You can implement the work-around on your phone by downloading Wake Lock from the Play Store and using it to keep a PARTIAL_WAKE_LOCK when running MyTrails.
- Some phones may incorrectly stop recording the track when the Temporal resolution preference in MyTrails is set to something other than 1s.
- System optimizers such as Juice Defender may also stop the GPS when the screen is turned off. Disabling that dubious optimization restores the recording functionality.
- Some devices disable the GPS when the battery is low.
- Some users have reported that using GPS Test to clear and reload the AGPS data may help restore GPS operation for all apps.
- GPS Locker helps prevent GPS from going to sleep on screen off.
- Huawei phones running their Oreo ROM use extreme battery saving techniques, such that only keeping the screen on allows MyTrails to keep recording. Or maybe this page (in French but with Google Translate) may help.
If you do experience this and can’t fix it based on the solutions compiled here, please post in the forum so I can keep track of the affected users and phone models.
Liked this post? Follow this blog to get more.