diff options
author | Santo Cariotti <santo@dcariotti.me> | 2024-10-18 15:36:07 +0200 |
---|---|---|
committer | Santo Cariotti <santo@dcariotti.me> | 2024-10-18 15:36:07 +0200 |
commit | 7c36badf769a3f6e54855dd7f03d25af5434762c (patch) | |
tree | 4dfb5b6ab8d9b946f3dff4ecef3e5c8ae81657e5 | |
parent | ae024da93d3acb576b43f5dd037ba0fcd4224b35 (diff) |
Increase `distanceInterval` value for location updates
-rw-r--r-- | app/(tabs)/index.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/(tabs)/index.tsx b/app/(tabs)/index.tsx index 6344a22..8e52ee1 100644 --- a/app/(tabs)/index.tsx +++ b/app/(tabs)/index.tsx @@ -446,8 +446,8 @@ export default function HomeScreen() { }, 2000); await Location.startLocationUpdatesAsync(LOCATION_TASK_NAME, { - accuracy: Location.Accuracy.Balanced, - distanceInterval: 0, + accuracy: Location.Accuracy.Balanced, // ~100 meters of precision + distanceInterval: 10, // Send data only if they moved of >=10 meters deferredUpdatesInterval: 1000, showsBackgroundLocationIndicator: true, foregroundService: { |