OruxMaps

Uncategorized Boards => MEJORAS/NEW FEATURES => Topic started by: hikingforfun on November 05, 2017, 12:30:36 PM

Title: API Access to Track Database
Post by: hikingforfun on November 05, 2017, 12:30:36 PM
Hi,



I would like to export all of my tracks as GPX and KML files for further processing in GPSies and Google Earth. As I am a long term (and very glad) oruxmaps user, I already have a huge amount of tracks. It would be a tedious effort to export all these tracks.



The track database is stored in sqlite format. It should be straight forward to write a Java program, python script or similar code doing this job.



Has anyone already  written such a program and is willing to share her/his code? I would greatly appreciate any feedback - even if it is only a program fragment.



@orux: I know you don't want to make oruxmaps open source, but maybe you will make an exception for the GPX/KML exporting functions... ;-)
Title: Re: API Access to Track Database
Post by: matt on November 06, 2017, 07:42:26 AM
Quote from: hikingforfunHi,

I would like to export all of my tracks as GPX and KML files ......It would be a tedious effort to export all these tracks.

Go to "Manage Tracks/Routes", select ALL tracks of your database with one click on icon on top right (toggle selection). Then press the "floppy disk" button at the bottom.  All marked & exported tracks appear in oruxmaps/tracklogs/



Matt
Title: Re: API Access to Track Database
Post by: hikingforfun on November 06, 2017, 11:29:36 PM
Hi Matt,



thanks for your reply. I have organized all of my tracks in huge number of folders. Following your advice I would have to repeat your procedure for every single folder. Or do you know how to select ALL folders for the export?
Title: Re: API Access to Track Database
Post by: matt on November 07, 2017, 07:03:36 AM
Oh, sorry. Hmm, if you have a huge number of folders, yes then it may be tedious to export all, using the built-in function.
Title: Re: API Access to Track Database
Post by: hikingforfun on November 21, 2017, 09:35:36 PM
Because I did not find any solution, I have written my own python program.

If somebody wants to use it, here is the link: //https://github.com/optiprime/omexport
Title: Re: API Access to Track Database
Post by: hikingforfun on December 03, 2017, 01:39:32 PM
Another cool feature is the "--combine" option (see //https://github.com/optiprime/omexport):

python omexport.py --combine

This call will export all tracks into one tracks.gpx file. If you drag and drop or open the file in Google Earth you can browse your hiking/biking/... tracks easily and conveniently.

Google Earth has become a very impressive tool, it has very good maps and nice 3D effects giving you a good visualization about the height profiles of your tracks.
Title: Re: API Access to Track Database
Post by: njupalo on May 21, 2023, 09:53:55 AM
Hi,

I was trying to export my tracks but nothing happened.  :'(
Script just create folder tacks and thats it!

What I'm diong wrong?

Regards