Make route files for your Garmin: Difference between revisions

From Wildsong
Jump to navigationJump to search
Brian Wilson (talk | contribs)
Brian Wilson (talk | contribs)
Line 23: Line 23:
ogr2ogr -overwrite -t_srs wgs84 -f "ESRI Shapefile" BikeMap.shp SelectRoutes.shp
ogr2ogr -overwrite -t_srs wgs84 -f "ESRI Shapefile" BikeMap.shp SelectRoutes.shp


ogr2ogr is from the gdal-bin package.
ogr2ogr is installed from the Ubuntu gdal-bin package. See http://www.gdal.org/ogr2ogr.html


=== Shapefile to GPX file ===
=== Shapefile to GPX file ===

Revision as of 06:11, 11 February 2009


The project

I have obtained a shapefile from bikemap site.

I want to convert it into a format suitable for use in a Garmin GPS receiver.

What is a route?

Conversion process

Obtain suitable data

Shapefile containing points or lines

In this case it's lines. Each line feature in the file represents one bike ride route.

Coordinate system

The file is in a projected coordinate system and I need it in latlon WGS84 format.

ogr2ogr -overwrite -t_srs wgs84 -f "ESRI Shapefile" BikeMap.shp SelectRoutes.shp

ogr2ogr is installed from the Ubuntu gdal-bin package. See http://www.gdal.org/ogr2ogr.html

Shapefile to GPX file

This command converts the shapefile into a GPX file. GPX is an interchange format commonly used by free and open source GPS programs.

gpsbabel -i shape -f BikeMap.shp -o gpx -F BikeMap.gpx

Transfer GPX file to Garmin

Three Linux programs that can be used to load GPX files are Viking, josm, and merkaartor. None of these seem to do anything with the file that I created. Thuban can display the shapefiles but does not understand GPX.

Windows -- In the past I have used a Windows program called EasyGPS which I believe supports GPX files.

Conclusions