Reputation: 517
With background locations, if the device enters Low Power Mode or Background App Refresh is disabled while an app is in the background and gathering locations... the OS kills it. Then even if these modes are reversed, it's not until the app comes foreground again that these activities can resume....
But what about monitoring for geofences in these modes? Does the OS stop monitoring them... or stop waking you up to respond to them?
Also, normally when you're woken up by a geofence, you're allowed to run indefinitely in the background. So I struggle to see how this would still be permitted.
Upvotes: 1
Views: 1039
Reputation: 1369
I worked with geofences a long time ago, but as far as I remember they get deactivated in Low Power Mode.
Apple documentation is not very clear on this, but they say:
In Low Power Mode, iOS conserves battery life by enacting certain energy-saving measures. For example, the system may:
- Pause discretionary and background activities, including networking
Sounds like monitoring your location is a background activity. Also, calling the delegate in your app would qualify as background activity as well.
I would recommend designing your app to be able to survive this kind of events, by listening for NSProcessInfoPowerStateDidChangeNotification
(the Apple documentation page has some nice examples).
Upvotes: 1