Upload & View Waypoints From File?

974 views
Skip to first unread message

Steve Sr.

unread,
Mar 2, 2016, 8:13:05 PM3/2/16
to Osmand

Hello,

I do volunteer trail maintenance and cover about 70 miles of trail. Someone was good enough to add the base trail (Falls Lake) part of NC Mountains To Sea Trail to the OSM database.

Frequently other trail users take photos and provide GPS coordinates of trail issues that need my attention. I would like to know how to load all of these GPS locations into a text file, perhaps with a comment for each point, and then have these display on top of the map with the trail route on it.

I think I have found how to do this manually but right now I have a dozen+ points to enter thanks to winter storms and my fingers make too many errors on a GS4 keyboard. Once an issue has been resolved I need to be able to remove single points while leaving the rest intact until they can be addressed.

Can someone point me in the right direction on how to accomplish this? And, yes, I am a relatively new user to both GPS and OSMand+ so detailed instructions would be most helpful.


Thanks,

Steve

Max Erickson

unread,
Mar 3, 2016, 1:32:41 PM3/3/16
to Osmand
You could put the coordinates into a gpx file as waypoints and then transfer that over. It's xml so it is text, but the format is picky.

If you are familiar with the command line and so on, you could install ogr2ogr (part of GDAL) and eventually have things setup so that a file with lines like

45.667,-80.9992,wash out

could be translated into a gpx with a command like

ogr2ogr -f GPX output.gpx input.file

(once you get ogr2ogr running, you then need to create a magic file that convinces ogr2ogr that your simple text file contains geographic information, but then a simple command like that is all it would take to complete each translation)

If that sounds like a viable option, I can describe further details.


Max

Steve Lund

unread,
Mar 4, 2016, 9:04:29 AM3/4/16
to osm...@googlegroups.com
Max,

Thanks so much for starting me in the right direction! It looks like I
need a GPX file with waypoints in it. With that much known, being a
basically lazy (hardware) engineer, I started doing some research in
Google.

Rather than try to load and setup GDAL I have found an online utility
that looks promising. Have you ever heard of or tried GPS Visualizer
(http://www.gpsvisualizer.com)? It looks like it will convert an excel
generated CSV file into a GPX file.

Anyway it looks like the path of least resistance for what I want to do
so I think I will try this first. If it doesn't work I'll give your way
a try.


Thanks,

Steve
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Osmand" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/osmand/VUMzEB4ByhU/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> osmand+un...@googlegroups.com
> <mailto:osmand+un...@googlegroups.com>.
> For more options, visit https://groups.google.com/d/optout.

nickjoh...@gmail.com

unread,
Mar 4, 2016, 11:14:01 AM3/4/16
to Osmand, slun...@pobox.com
On Friday, 4 March 2016 14:04:29 UTC, Steve Sr. wrote:
Max,

Thanks so much for starting me in the right direction! It looks like I
need a GPX file with waypoints in it. With that much known, being a
basically lazy (hardware) engineer, I started doing some research in
Google.

Rather than try to load and setup GDAL I have found an online utility
that looks promising. Have you ever heard of or tried GPS Visualizer
(http://www.gpsvisualizer.com)? It looks like it will convert an excel
generated CSV file into a GPX file.


I wanted to suggest GPS Visualizer, but got sidetracked and didn't post.
I've used it create maps showing where I've hiked, but it should work fine for your case.

I pasted a test entry into http://www.gpsvisualizer.com/convert_input and the generated GPX file contained a <wpt> tag which OsmAnd recognises.

Once you've got the GPX file, copy it into your OsmAnd data folder (Android/data/net.osmand.plus/files/osmand/tracks). (If you're using the free version, remove ".plus" from the previous path.)

Alternatively, upload the GPX file to Dropbox and download it using the Dropbox app on your phone. It will open in OsmAnd automatically. You can tap waypoints to see their descriptions.

You can control what GPX files are displayed, select "Configure map" and then "GPX track...". Tick whatever tracks you want OsmAnd to show.

Please keep up the good work of maintaining those trails :)

Thanks
Nick

Max Erickson

unread,
Mar 4, 2016, 12:54:59 PM3/4/16
to Osmand
It sounds like gpsvisualizer will work fine. If you decide to take a look at using ogr2ogr, the documentation for the csv driver is here:

http://www.gdal.org/drv_csv.html

I guess in more recent versions you can just use particular column names to get it to treat the file as geographic.


Max

IanW

unread,
Mar 8, 2016, 5:06:41 AM3/8/16
to Osmand, slun...@pobox.com
Actually, creating a gpx file to import into OsmAnd is fairly simple. The content of the file looks like this:

<?xml version='1.0' encoding='UTF-8' standalone='yes' ?>

<wpt lat="-33.85683" lon="151.21519">
<name>Sydney Opera House</name>
<category>Australia</category>
</wpt>

</gpx>

The bit between <wpt and </wpt> is a waypoint. Just duplicate it as many times as needed inserting the appropriate lat lon name and category. 

I regularly convert Garmin waypoints to OsmAnd with a bit of automated search and replace in Notepad++. Garmin gpx files have a lot more tagging that OsmAnd does not like so I strip it out.

If yours were in a spreadsheet say with lat lon name and category columns, you could import them into a text editor and replace the resulting tabs with the gpx tags the paste the result in place of the waypoint above.

Steve Lund

unread,
Mar 8, 2016, 10:53:48 AM3/8/16
to nickjoh...@gmail.com, Osmand
Nick,



On 3/4/2016 11:14 AM, nickjoh...@gmail.com wrote:
On Friday, 4 March 2016 14:04:29 UTC, Steve Sr. wrote:
Max,

Thanks so much for starting me in the right direction! It looks like I
need a GPX file with waypoints in it. With that much known, being a
basically lazy (hardware) engineer, I started doing some research in
Google.

Rather than try to load and setup GDAL I have found an online utility
that looks promising. Have you ever heard of or tried GPS Visualizer
(http://www.gpsvisualizer.com)? It looks like it will convert an excel
generated CSV file into a GPX file.


I wanted to suggest GPS Visualizer, but got sidetracked and didn't post.
I've used it create maps showing where I've hiked, but it should work fine for your case.

I pasted a test entry into http://www.gpsvisualizer.com/convert_input and the generated GPX file contained a <wpt> tag which OsmAnd recognises.

Once you've got the GPX file, copy it into your OsmAnd data folder (Android/data/net.osmand.plus/files/osmand/tracks). (If you're using the free version, remove ".plus" from the previous path.)
This part of the process is turning out to be and *extremely* big PITA! The file is on Google Drive but after many more hours of research it looks like I need a 3rd party App line ES File Explorer to actually get it to its proper location where OSMand can find and use it.


Alternatively, upload the GPX file to Dropbox and download it using the Dropbox app on your phone.

Do you (or anyone else) know how to make this work directly with Google Drive? If DropBox could do it I would think that GD should as well. If anyone has some good step-by-step directions I would welcome them.


It will open in OsmAnd automatically. You can tap waypoints to see their descriptions.
How does this "automatic" opening work? Does OsmAnd open the file and then move it into the /tracks/ directory or does Dropbox (or GD if it will work) put the file in the /tracks/ folder and then open OsmAnd with the file name as an argument somehow?

It would be nice to come up with the simplest solution to this as some other volunteers on on our trail crew may want to use this and they are not techies at all.


You can control what GPX files are displayed, select "Configure map" and then "GPX track...". Tick whatever tracks you want OsmAnd to show.
I am hoping that when I get this far this will be easy.


Please keep up the good work of maintaining those trails :)
Thanks, It is looking like it will be a busy spring thanks to lots of rain and lots of wind and already some severe weather.


Thanks,

Steve

Thanks
Nick

Steve Lund

unread,
Mar 8, 2016, 10:53:48 AM3/8/16
to Nick Johnston, Osmand
On 3/5/2016 4:13 PM, Nick Johnston wrote:
On 4 March 2016 at 20:40, Steve Lund <slun...@pobox.com> wrote:
Nick,


On 3/4/2016 11:14 AM, nickjoh...@gmail.com wrote:
On Friday, 4 March 2016 14:04:29 UTC, Steve Sr. wrote:
Max,

Thanks so much for starting me in the right direction! It looks like I
need a GPX file with waypoints in it. With that much known, being a
basically lazy (hardware) engineer, I started doing some research in
Google.

Rather than try to load and setup GDAL I have found an online utility
that looks promising. Have you ever heard of or tried GPS Visualizer
(http://www.gpsvisualizer.com)? It looks like it will convert an excel
generated CSV file into a GPX file.


I wanted to suggest GPS Visualizer, but got sidetracked and didn't post.
I've used it create maps showing where I've hiked, but it should work fine for your case.

I pasted a test entry into http://www.gpsvisualizer.com/convert_input and the generated GPX file contained a <wpt> tag which OsmAnd recognises.

Once you've got the GPX file, copy it into your OsmAnd data folder (Android/data/net.osmand.plus/files/osmand/tracks). (If you're using the free version, remove ".plus" from the previous path.)
This part of the process is turning out to be and *extremely* big PITA! The file is on Google Drive but after many more hours of research it looks like I need a 3rd party App line ES File Explorer to actually get it to its proper location where OSMand can find and use it.

Alternatively, upload the GPX file to Dropbox and download it using the Dropbox app on your phone.

Do you (or anyone else) know how to make this work directly with Google Drive? If DropBox could do it I would think that GD should as well. If anyone has some good step-by-step directions I would welcome them.

I don't use Google Drive but I just tested it and it works. Instructions:

1. Upload the GPX file to Drive using your computer.
2. Open the Drive app on your phone and find the GPX file. Tap it.
3. Drive will show an "Open with" card. Tap OsmAnd or OsmAnd+ (depending on which version you use).
4. OsmAnd will open, and will show a brief "toast" pop-up message saying "GPX track saved to ..." or similar.
5. OsmAnd will probably move the map to the first waypoint defined in the GPX file.
This doesn't work in my version of Android (kit-kat 4.4.2). There is NO "Open with" card. Tapping the file just opens it in some form of text viewer. If I tap on the magnifying glass icon drive shows a bunch of file associations and viewers but there is NO GPX file type in the list and no apparent way to associate the file type with the correct OsmAnd App.

I even found a reference to using the "box with the arrow" icon as an "Open With" button. All this does is bring up a "Send file" to a different place and not an "open"

They may have fixed this in newer versions of Android, but I am only guessing.

It will open in OsmAnd automatically. You can tap waypoints to see their descriptions.
How does this "automatic" opening work? Does OsmAnd open the file and then move it into the /tracks/ directory or does Dropbox (or GD if it will work) put the file in the /tracks/ folder and then open OsmAnd with the file name as an argument somehow?

It would be nice to come up with the simplest solution to this as some other volunteers on on our trail crew may want to use this and they are not techies at all.

The automatic opening works via Android's intents system. Applications like OsmAnd can declare that they handle certain file types or actions. When an action occurs (like wanting to share something, or downloading a file) then Android gives you a choice of apps that can do that for you.

If you select OsmAnd from the choice, then it gets the GPX file and imports the file itself. (Due to Android's permission model, neither Dropbox nor Google Drive can write to OsmAnd's storage.)
It would be nice if this actually worked this way. Maybe it is fixed in a later OS version but it doesn't work now!

 

You can control what GPX files are displayed, select "Configure map" and then "GPX track...". Tick whatever tracks you want OsmAnd to show.
I am hoping that when I get this far this will be easy.

Let's hope so :)
Once I figured out how to MANUALLY move the GPX file into the proper "tracks" directory it opened right up!

 

Please keep up the good work of maintaining those trails :)
Thanks, It is looking like it will be a busy spring thanks to lots of rain and lots of wind and already some severe weather.


I just looked that trail up and it's over 1,000 miles--nuts. I went to Atlanta last year and wanted to go to the Great Smokey Mountains, but without hiring a car it was impossible alas :(
The MST is a work in progress. Of the 1000 miles about 500 is currently on the ground and connected via rural road walks. For anyone who wants to learn more please visit www.ncmst.org.

The Smokies are well worth visiting. Fall is usually a good time of year as you can walk through the seasons from late summer to winter ans you change elevation. They are a fair distance from Atlanta though.


Thanks,

Steve

Ian Wills

unread,
Mar 8, 2016, 3:54:02 PM3/8/16
to osm...@googlegroups.com, nickjoh...@gmail.com
So long as you have a valid gpx file it is easy to get it into OsmAnd without external software or websites.

This is what I do using Dropbox (Google Drive will be similar):
  1. Edit the file to your requirements (see my earlier post) and save to Dropbox.
  2. Open Dropbox on your phone or other device.
  3. Locate the file and click on it.
  4. An "Open with . . ." popup will appear with a list of Apps that might open the file. 
  5. Select OsmAnd. (Maybe the first time click "Just once").
  6. OsmAnd will open with a popup "Import to OsmAnd"
  7. If the file contains gpx waypoints, select "Import".
  8. Your imported waypoints will appear in "My places" in OsmAnd sorted into the categories you assigned in the gpx file.
Easy peasy!

--
You received this message because you are subscribed to a topic in the Google Groups "Osmand" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/osmand/VUMzEB4ByhU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to osmand+un...@googlegroups.com.

Steve Lund

unread,
Mar 9, 2016, 5:15:05 PM3/9/16
to osm...@googlegroups.com, nickjoh...@gmail.com
Ian,

I got your other message as well. I could probably edit raw GPX files but like the GPSVisualizer method of converting an Excel spreadsheet. This way the Excel spreadsheet becomes a permanent database that can be updated and changed as necessary and a new GPX file generated. This is also the about the only way some of our less tech enabled would be able to handle this.



On 3/8/2016 3:53 PM, Ian Wills wrote:
So long as you have a valid gpx file it is easy to get it into OsmAnd without external software or websites.

This is what I do using Dropbox (Google Drive will be similar):
  1. Edit the file to your requirements (see my earlier post) and save to Dropbox.
  2. Open Dropbox on your phone or other device.
  3. Locate the file and click on it.
  4. An "Open with . . ." popup will appear with a list of Apps that might open the file. 
  5. Select OsmAnd. (Maybe the first time click "Just once").
  6. OsmAnd will open with a popup "Import to OsmAnd"
  7. If the file contains gpx waypoints, select "Import".
  8. Your imported waypoints will appear in "My places" in OsmAnd sorted into the categories you assigned in the gpx file.
Easy peasy!
Well... Not quite! The "Open With" functionality doesn't appear to be part of Android Kit-Kat 4.4.2 which makes this process quite painful. What version of Android are you using that has this functionality?


Thanks,

Steve

Max Erickson

unread,
Mar 10, 2016, 3:11:14 PM3/10/16
to Osmand, nickjoh...@gmail.com, slun...@pobox.com


Well... Not quite! The "Open With" functionality doesn't appear to be part of Android Kit-Kat 4.4.2 which makes this process quite painful. What version of Android are you using that has this functionality?


The functionality is present in Android 4 (it uses 'intents'). It should also work with reasonably recent versions of OSMAnd (the receiving app has to tell Android it is interested in a given file type).

In the version of Google Drive I have, when I tap a gpx file it shows it to me as text. On this screen there is a button made out of three vertical dots in the upper right corner. If I tap that button, there is an Open with... command.

Testing briefly it seems drive marks the file as a text document and OSMAnd doesn't get a chance to open it. If I download a gpx with the Chrome browser on the phone, I can send that to OSMAnd by tapping it. If I grab a gpx out of Drive, tapping it sends the file to a text editor. I'm not sure if OSMAnd should be registering to handle those files or not (but it currently is not, or I'm doing something wrong).

So in general you need to look at the app for the open with functionality, but there could be corner cases where it won't work.

Yay systems made to be easy that make things hard.


Max

Steve Lund

unread,
Mar 11, 2016, 9:17:54 AM3/11/16
to osm...@googlegroups.com, nickjoh...@gmail.com
Max

Thanks for the insight.

On 3/10/2016 3:11 PM, Max Erickson wrote:


Well... Not quite! The "Open With" functionality doesn't appear to be part of Android Kit-Kat 4.4.2 which makes this process quite painful. What version of Android are you using that has this functionality?


The functionality is present in Android 4 (it uses 'intents'). It should also work with reasonably recent versions of OSMAnd (the receiving app has to tell Android it is interested in a given file type).

In the version of Google Drive I have, when I tap a gpx file it shows it to me as text.
Same here.



On this screen there is a button made out of three vertical dots in the upper right corner. If I tap that button, there is an Open with... command.
All I get is "Download, Send File, Report An Issue". There is NO "Open With".



Testing briefly it seems drive marks the file as a text document and OSMAnd doesn't get a chance to open it.
This may be why I read instances where Dropbox worked while Google Drive didn't. So is this a Drive issue or an OsmAnd issue? Both Apps are fully updated on the phone.


If I download a gpx with the Chrome browser on the phone, I can send that to OSMAnd by tapping it.
So what does Chrome do that Drive doesn't? It would appear that OsmAnd would be the control in this experiment.


If I grab a gpx out of Drive, tapping it sends the file to a text editor. I'm not sure if OSMAnd should be registering to handle those files or not (but it currently is not, or I'm doing something wrong).

So in general you need to look at the app for the open with functionality, but there could be corner cases where it won't work.
So is this an OsmAnd bug or a Google Drive bug... or both!


Yay systems made to be easy that make things hard.
+100!


Max

Max Erickson

unread,
Mar 11, 2016, 11:07:07 AM3/11/16
to Osmand

On Friday, March 11, 2016 at 9:17:54 AM UTC-5, Steve Sr. wrote:
So is this an OsmAnd bug or a Google Drive bug... or both!


I'm not sure, but I think it is Drive doing something idiosyncratic. If I open the safe file  in "Astro file manager, I get the Osmand intent. So that smells like Drive marking the file in a way that other Google apps  (the  Download helper) interpret, but not other Android Apps.

Max

Dave Welsh

unread,
Mar 16, 2016, 4:15:59 PM3/16/16
to Osmand, nickjoh...@gmail.com
No it does not.
Seems to be no way to open it.

Dave Welsh

unread,
Mar 16, 2016, 4:38:38 PM3/16/16
to Osmand
I have never gotten them to come into OSMAND
they come into locus perfect.
I have tried drive and dropbox
just does not work

Ian Wills

unread,
Mar 16, 2016, 6:30:17 PM3/16/16
to osm...@googlegroups.com
I wonder if the problem is an invalid gpx file. 

I could not get OsmAnd to accept gpx files generated by Garmin. There were three problems: 
  • Garmin waypoints have additional fields OsmAnd does not use; 
  • Garmin permits a waypoint to have multiple categories, OsmAnd only one
  • The header for OsmAnd is different from OsmAnd's. 
To check the last, open the gpx file in a text editor and look at the header. The first two lines (before the first <wpt) should read:

<?xml version='1.0' encoding='UTF-8' standalone='yes' ?>

If they don't, try replacing everything before <wpt with these two lines.

Other instructions, see my earlier post. Good luck.






--

Andrew Davie

unread,
Mar 17, 2016, 5:33:30 AM3/17/16
to osm...@googlegroups.com
I have just been reworking the GPX track display code (my first foray into OsmAnd programming, I’ll submit the ‘patch’ as soon as I figure out how to do it). Nothing major, just the track now scales as you zoom in and out, so that when you’re zoomed right out you don’t get massive big GPX tracks with all sorts of artefacting.  Anyway, the powers that be may or may not accept the update but at least *I* have it <evil laugh>.  The point of all this is that I’m quite familiar with the GPX reading/parsing code and able to debug/diagnose problems. If anyone would like to send me non-working GPX files I can figure out exactly what the problem is and probably fix the code at the same time.
Cheers
A

You received this message because you are subscribed to the Google Groups "Osmand" group.
To unsubscribe from this group and stop receiving emails from it, send an email to osmand+un...@googlegroups.com.

Max Erickson

unread,
Mar 17, 2016, 9:14:24 AM3/17/16
to Osmand
I get different intents depending on where I open the same file, so while an invalid gpx could be a contributor, there is also some problem getting an OSMAnd intent when opening a file from inside Google Drive (or in the Downloads helper when the file has been saved from drive).


Max

P Wat

unread,
Mar 18, 2016, 4:44:43 AM3/18/16
to Osmand
I would like to be able to load some ex-Garmin waypoints/POIs (GPX?) into OsmAnd, so this topic interests me.
I'll send my two-penneth when I've tried it.
Paul W

P Wat

unread,
Mar 20, 2016, 3:13:57 PM3/20/16
to Osmand
This may already be common knowledge, but could contribute something, so FWIW:-
To show in "My places" the locations must be in the file called "favourites", in the top level of the OsmAnd folder.
I managed to import some ex-Garmin waypoints in a GPS file. On the laptop I added the existing Osmand Favourites to the ex-Garmin waypoints using "Easy GPS".
I named the new file "favourites" and pushed it into Osmand in the Android mobile, in the place of the existing one.
After restarting Osmand, the added waypoints appeared with the correct names and locations but not without snags including loss of some text details.  Also they were scattered throughout "My Places" in clusters of new inconveniently-named Categories/Groups.
If you could take the time/trouble to edit them (eg in EasyGPS) before pushing back to Osmand, the result could be more useful.
Not a particularly helpful result.
Anyone got anything better?
Paul W
Reply all
Reply to author
Forward
0 new messages