Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question]: Improve Location Accuracy in Flutter App using Geolocator #1590

Open
4 of 8 tasks
akashs-gloify opened this issue Oct 11, 2024 · 0 comments
Open
4 of 8 tasks

Comments

@akashs-gloify
Copy link

akashs-gloify commented Oct 11, 2024

Please check the following before submitting a new issue.

Please select for which platform(s) you need help

  • Android
  • iOS
  • Linux
  • Web
  • macOS
  • Windows

Your question

We are developing a Flutter application that uses the Geolocator plugin for real-time location tracking. However, we are experiencing issues with the accuracy of the location data:

  • Inaccurate location points: The recorded location points often appear on nearby buildings rather than on the road, where the user is walking or driving.
  • Fluctuations when stationary: Even when standing still, the location coordinates tend to fluctuate, causing erratic movements in the plotted path.

Current Setup

  • Flutter Version: 3.24.3
  • Geolocator Version: 13.0.1
  • Platforms: Android & iOS
  • Accuracy Mode: LocationAccuracy.bestForNavigation
  • Distance Filter: Set to 15 meters

What We’ve Tried So Far

  1. Set Higher Accuracy Mode: Using LocationAccuracy.bestForNavigation for the highest precision.
  2. Distance Filter: Set to 15 meters to control the frequency of location updates.
  3. Checked Location Services: Ensured the location services are enabled.
  4. GPS Accuracy Optimization: Prompting users to enable "High Accuracy" mode on Android devices.

Despite these steps, the accuracy is still inconsistent.

Expected Behavior

  • Accurate location points along the road, with minimal deviation when the user is stationary.
  • Smoother paths when tracking movement.

Help Requested

We are looking for assistance in improving the location accuracy for both Android and iOS platforms. Any insights or advanced techniques would be greatly appreciated. Specifically, we are looking for help with:

  • Implementing techniques to reduce fluctuation while the user is stationary.
  • Improving real-time tracking precision while the user is moving (e.g., on the road).
  • Any advanced filtering techniques (e.g., Kalman Filter or sensor fusion) that can be applied to improve accuracy.

Additional Information

  • Device Used for Testing: Redmi, Samsung, iPhone etc.
  • Environment: Urban area with moderate building density.
  • Code Snippet: Here's a sample of how we're currently implementing Geolocator:
Position position = await Geolocator.getCurrentPosition(
  desiredAccuracy: LocationAccuracy.bestForNavigation
);
  • Map View Example: Here's a screenshot of the issue we're seeing with location plotting:
Screenshot 2024-10-11 at 8 33 12 AM

Any contributions or suggestions on how to resolve this issue would be greatly appreciated. Thanks in advance!

Version

13.0.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant