GPS coordinates always snap to nearest address (building?) instead of accurate coordinates

Hi everybody,

I want to create a simple hide-and-seek game for children, where they can hide painted pebbles somewhere, and others can find them. I have challenges with the GPS coordinates.

When someone wants to drop a pebble, Adalo grabs the coordinates of the nearest building or address instead of the accurate position. This makes it challenging because the children won’t find the pebble there.

Here’s an example:
The place where I want to hide the pebble:

The coordinates that Adalo give me:

The coordinates that are saved in the db:
image

The coordinates I get from another app (slightly different):

The difference in where I put it (blue dot) and where Adalo thinks I put it (the red marker):

I used different ways to save the GPS coordinates:

Simply in a location field:
image

But also in two lat, lon, text fields:
image

Both of them have the same results.
I checked the GPS permission; it’s even set to accurate and always.
I tried to install Pragmaflow’s Geolocation plugin, but it doesn’t show up in my private components.

This is the only thing hindering me from creating this app, so it’s a bit frustrating that I cannot fix it. For the rest I’m quite happy with Adalo and don’t want to switch to a different platform (bubble.io could do the trick), so I’m thankful for any tip or suggestion that could potentially solve this.

Thanks a lot for thinking with me.

The Google Maps API ignores everything past 6 digits. At 7 digits, coordinates are tracking at 1 cm of distance. Six digits is like 10 cm. Interestingly, if you right-click on a Google Map, you get to see 5 digits, which is a little over a metre, but when copied, you get 15 digits, which is like atomically small precision and totally useless. I suspect the Adalo map component resolves to 5 digits, but I’m not sure. I had the same problem with markers getting stacked, so I shifted to Google Static Maps API and just fed it the 6-digit coordinates from two fields in the collection and all was fine.

Also, if you are using address lookup, then that might be an issue. That farm road Appenzell probably has the same official address as the closest structure, or official house lot.

Hi @acwarsing, thanks for your comment. That sounds interesting. Can you tell me a little bit more about how you achieved this with the Google Static Maps API? Do you have an example? Thanks for your help! It would be awesome if this does the trick I think.

Sure, this is the syntax for a Static Map. A Google Static Map is just an image that you can size however you like. So, you would just add an image to your app, then configure the URL like the example. Just read through it and from some trial and error you’ll get it and produce what you need.

You need an API key. Static Maps are 100% free. Here are the docs:

screenshot - 000015

Hi @acwarsing, I got it. Thanks for explaining. It doesn’t help me, unfortunately, because the users need to be able to scroll/zoom/pan the map to find pebbles nearby. Thanks for the suggestion though.

You can link the map using a URL action to a mapping app on the mobile device. Anyhow, this is an example of the problem. This Biergarten has an official address far away from a road, and it’s only accessible by foot or bike.

Best of luck!

Thanks for explaining. Good to know that there’s this option as well. Unfortunately, I need the map interaction.

Do you know if there’s another API than Google Maps that I could use for showing markers on a map in Adalo? Or any workaround to be able to show markers more accurately on an interactive map?

Well, I think the issue is the interactive map widget. You can use many different mapping solutions, but displaying an iFrame might be the problem. The mapping widget removes the need for an iFrame or Javascript by doing the address lookup, then storing the individual address components in the collection for use as magic text.

Check out OpenStreetMap and MapBox.

OK. I did a quick test. You can use the map widget, but, you can also just feed it your own more precise lat/lon from the collection. See the difference?




This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.