Using CoreLocation I need to measure how far I drive. I don’t care if I get the distance every 100 meters, 500 meters or 1k meters – I just need it to be as accurate as possible.
Is startMonitoringSignificantLocationChanges accurate enough for my purpose?
Thanks!
Mojo
There are 2 parts to what you mentioned.
1) frequency of update
2) accuracy
(1)
For frequency of update, significant location change is not very frequent. It depends on density of cell tower, so it can be between 500m to 10km. I wrote an app to test this, and plotted a chart. It maxes around 2km where I am.
If you are not concerned about frequency of updates, you can use this. If you are, try using continuous location update instead.
(2)
Accuracy depends on the amount of time the app has when it is active, to get accurate location. You will get better accuracy with continuous location update because the app stays active and have enough time to get good location.
Usually, accuracy wih significant location update is bad because the app is woken up momentarily and does not have much time to get accurate location until it sleeps.
If you want to improve accuracy when using significant location change, use task completion API to keep the app awake until you can your desired accuracy. But you also need to bear in mind that you should terminate the task if you can’t get an accurate result after sometime. If user is in a building or underground, you don’t want the app to keep trying and uses up battery.