3

Converting tracks from a GPX track to a CSV table or some other format is relatively easy, but I'm looking to go the other way. I have a table of point locations logged with a handheld GPS, with timestamps. I need to convert them to a GPX file with a tracklog containing those points so they can be used with some other software to geotag some photos. I can convert them to GPX waypoints easily enough using QGIS/GDAL, but not to a GPX tracklog, the timestamps are lost.

Here's the header of my CSV:

Lon,Lat,Altitude,NewTrack,TimeStamp,Datum,InternalTime
3
2

GPS Visualizer will pass your time stamps to gpx format.

Using the online tools will preserve your timestamp in the .csv file.

Convert a GPS file to plain text or GPX

This form reads a tracklog or waypoint file (in a recognized format) or plain-text tabular data, and converts it to an easy-to-read tab-delimited or CSV text file, or to a GPX file.

http://www.gpsvisualizer.com/convert_input

1

The question was asked years ago, so if you are searching for this recently and you are using or willing to use Python >= 3.5, you can use gpx_converter.

Install using pip
pip install gpx_converter
then use it by calling the csv_to_gpx in your case:
from gpx_converter import Converter

Converter(input_file='your_input.csv').csv_to_gpx(lats_colname='Lat',
                                                 longs_colname='Lon',
                                                 output_file='your_input.gpx')

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.