1. What is the issue? Please be detailed.
Using ODK collect latest version with a BT GPS to use a Garmin handheld GPS to map plot polygon. Use a geotrace activity that allow-mock-accuracy = True. Every couple of seconds, the form widget switches from handheld GPS to tablet GPS for 3/4 seconds then comes back to handheld GPS for 10seconds.
2. What steps can we take to reproduce this issue?
Just open the activity and wait
3. What have you tried to fix the issue?
we didn't try to deactivate the tablet GPS maybe it helps but i don't think this is possible without deactivating the all location service.
4. Upload any forms or screenshots you can share publicly below.
Did the same workflow have a different behavior with a previous version of Collect? That is, is this a new issue after an upgrade or is this your first time testing this workflow?
Could please also share what version of Android? What is the tablet make and model?
We have been using an fork of ODK from 2020 and this behavior wasn't present. Now this is the first time that we test the latest version with ODK v2025.1.5
Test is done with Android version 14 on Samsung Tab A7 Lite SM-T225
Thanks for reporting this, @OlivierVernin. I'm not sure yet, but this could be a bug in Collect. @dbemke can you please try to reproduce this? Try first with a GPS spoofing app.
In the video I can see that after a few second you’re moved to the location. You’re using "Manual location recording" which checks the location every few seconds and this moves the screen to the location. It seems to me that you might have moved the view to a different location and that’s why you can see the view changing when Collect checks the location.
If you want to place the marker manually you can try out "Placement by tapping" input method. This method doesn’t move back to the real location.
Do you use any GPS spoofing app? In the video the location accuracy isn’t 0.00 m which means the real location is checked. If you use "Manual location recording" or "Automatic location recording" and a GPS spoofing app, Collect also moves the screen back to the location (the fake location) every few second after moving away from the location.
Have you tested the Garmin / Android combination with another app?
I use a Ubloxx-based external GNSS, connected via Bluetooth and have found similar issues. However, it appears to be 'system wide' not ODK Collect in my case. It took me a while to figure this out - you need an app that shows the accuracy visually (like the blue circle in ODK Collect) or an app that generates a log showing XYZ and location accuracy. Orux Maps has visual representation which is where I spotted the same behaviour, but you can see accuracy monitored in GPS Logger and probably GPS Test apps. I have used Bluetooth GNSS and GNSS Master apps as my mock location providers.
I found that SOMETIMES (not reliably replicable) the external device drops and is replaced by the internal GPS signal. Some days are worse than others. One scenario is where I am using RTK (i.e. centimetre accuracy) and either the NTRIP server or 4G signal drop out - I don't know if there is cause effect here. I happen to have a device with broken internal GPS, and in this case it records the location as 0,0 on a GPX track - so I get a visual 'spike' that is not visible when I use my usual device (both are Samsung Note 8).
But it is infrequent and isn't always detected in the field - an INVALUABLE feature of ODK Collect showing accuracy during geo-data collection - I always check / wait for the accuracy to lie within my expected range with external device (e.g. <0.5m) before recording a point / vertex. Not so easy if you are using Automatic recording as you may be unlucky... then the data might need to manually 'clean' your data to remove the points / vertices recorded with the internal GPS...
Check the GNSS app that links your external device to mock-location - it may have a logging feature so you may be able to cross check whether there are any missing data points.
I'm not saying it's not ODK Collect (sorry about the double negative), but it would help if you can confirm that it doesn't occur with any other app.
Thanks for the additional information. The second video makes it easier for me to interpret.
It is behaving in the same way as I have experienced (if your tablet has an unreliable or poor internal GPS receiver it is not unusual for it to change location and show low accuracy when it initialises - ODK Collect is grabbing the first data available). Some older devices I have used could take 20 seconds to get a good fix (even from warm-start), so I became accustomed to keeping their GPS signal 'live' with a secondary app running a track...
If the connection to the Garmin drops temporarily, your device will probably fire up the internal GPS - and if it is struggling to get a fix, this is the behaviour you would 'expect'. And then when the Garmin reconnects, it will jump back to your actual location.
My suggestion is to use another 'navigation' app to test if the same thing happens - not to ask whether you are using more than one app at once. If Bluetooth GPS app has logging available you could go through that. to see if there are drop-outs - it may not show up, hence suggesting the visual test in another app.
I'm not yet convinced it is an ODK Collect specific issue. If you can confirm whether the same behaviour happens with other apps, using the same device(s), I think that would help point the finger more clearly.
As an aside, the Garmin device appears to have accuracy of approx 6m, which is no obvious advantage on an internal GPS on an Android device - you probably have other reasons for using it and therefore need mock-location?
Hi @OlivierVernin,
We were able to reproduce the issue you described with switching between fake and real locations. It turns out that apps that spoof locations can fake those coming from GPS, but location data can also be derived from Wi-Fi or cellular networks.
Based on our testing, if you disable "Improve location accuracy" in the Android settings, the device will rely solely on GPS. In that case, if GPS is being spoofed, the location will consistently appear fake.
@OlivierVernin please give it a try and let us know if it solves your problem.