summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/(tabs)/index.tsx5
1 files changed, 5 insertions, 0 deletions
diff --git a/app/(tabs)/index.tsx b/app/(tabs)/index.tsx
index 734fa5e..f83b6c0 100644
--- a/app/(tabs)/index.tsx
+++ b/app/(tabs)/index.tsx
@@ -467,6 +467,11 @@ export default function HomeScreen() {
updateLocation(location.coords, location.coords.speed);
});
+ setInterval(async () => {
+ const location = await Location.getCurrentPositionAsync({});
+ updateLocation(location.coords, location.coords.speed);
+ }, 2000);
+
Location.watchPositionAsync(
{
accuracy: Location.Accuracy.Balanced,