-
Notifications
You must be signed in to change notification settings - Fork 231
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
How can i store locations even when device is not moving? #213
Comments
implement background_fetch callback. This plugin (also managed by Transistor Software) is already included as a dependency. Execute BackgroundGeolocation.getCurrentPosition in your fetch callback. |
Just need to implement I was trying it on One last question: We use Firestore. So need to buy license for |
Yes. The |
questions:
|
Any Android app that has been terminated.
Yes, iOS has no such concept of running “headless” |
Ok, and about |
Fetch has similar Android headless mechanism. If user terminates app, iOS stops firing fetch events. You absolutely have no ability to keep periodically requesting location when user explicitly terminates the iOS app. However, the iOS background-geolocation plugin will automatically initiate location tracking in a terminated app when device moves about 200 meters. |
So, i cannot make my app to IOS if i expect capture user home position, if app is closed? |
If the iOS device is sitting stationary in the same place, correct. However, once the user moves ~200 meters, the |
Hello @christocracy . There is a thing i don't understan. You told me here that when device became stationary, and app closes, i can use But, in background_fetch pub.dev page, it has an iOS badge... So, did you found a way to implement it in ios too ?? |
Where did I tell you that? |
Here..
After i ask about not works on ios, even with background_fetch. |
Where did I say:
|
I make a short resume about all stuffs we discuss here... just that... at least, as I understand it. The point is: Your plugin is amazing, far beyond others. This is a fact and I congratulate you for that But, my solution needs to capture positions every 15 (or 30) minutes even when device is in a fixed position all day. In Android is fine with |
iOS background_fetch will completely re-launch an app that was terminated by the os to service the event, just as if launched from the home-screen. However, If the user terminates the app, iOS halts fetch events. In that case, it’s impossible to do any time-based location tracking. Sometimes, what you want on mobile (particularly iOS) is simply impossible. |
Also for iOS background_fetch, if the user doesn’t open your app daily, iOS will halt fetch events. |
Your Environment
flutter doctor
):Expected Behavior
Need to capture points even when device is not moving.
Actual Behavior
Get location only when users walks.
Steps to Reproduce
Context
I only need to detect the user's position every X minutes, even if the device is not moving.
Debug logs
Logs
The text was updated successfully, but these errors were encountered: