| 1 |
|
| 2 |
Making maps for Garmin GPS units |
| 3 |
================================ |
| 4 |
|
| 5 |
The goal of the project is to take the map data from |
| 6 |
OpenStreetMap <http://www.openstreetmap.org> |
| 7 |
and to generate a map in the Garmin file format so |
| 8 |
that it can be loaded onto Garmin GPS units. |
| 9 |
|
| 10 |
The original motivation was to help plan mapping sessions, |
| 11 |
but now the maps are becoming useful in their own right. |
| 12 |
|
| 13 |
Using |
| 14 |
===== |
| 15 |
|
| 16 |
This program requires Java 1.8 or above to run. |
| 17 |
|
| 18 |
Producing a map is simple. Save OpenStreetMap data from JOSM |
| 19 |
or by any other method to a file and copy it to the mkgmap |
| 20 |
directory. In the following examples this file is called data.osm. |
| 21 |
|
| 22 |
Run the command: |
| 23 |
|
| 24 |
java -jar mkgmap.jar data.osm |
| 25 |
|
| 26 |
This will produce a file called 63240001.img. |
| 27 |
|
| 28 |
You can copy the map to your Garmin GPS unit in any way you know how. |
| 29 |
It is best to use a SD card, since then if anything goes wrong you |
| 30 |
can remove it from the unit and all should be well again. |
| 31 |
|
| 32 |
Copy it to the file "Garmin/gmapsupp.img" on the card. |
| 33 |
On many modern Garmin devices, you can use a different |
| 34 |
name so that you can have more than one set of maps. |
| 35 |
|
| 36 |
*NOTE* this will overwrite any other map you have on |
| 37 |
there, make sure that you are not overwriting a valuable map. |
| 38 |
|
| 39 |
Another way would be to use a USB memory card writer and |
| 40 |
for a large map this is quicker as many GPS's have a slow USB |
| 41 |
connection. |
| 42 |
|
| 43 |
There are also various programs that can send a map to the |
| 44 |
device. |
| 45 |
|
| 46 |
You should (depending on the particular Garmin model) see a OSM |
| 47 |
copyright message on starting up, and the map name 'OSM Street map' |
| 48 |
should appear in the map setup section. |
| 49 |
|
| 50 |
For more help see: http://www.mkgmap.org.uk/doc/index.html |
| 51 |
|
| 52 |
|
| 53 |
Invoking mkgmap |
| 54 |
-------------- |
| 55 |
|
| 56 |
Most of the default names mentioned in the previous section can be altered |
| 57 |
by suitable options. Run |
| 58 |
|
| 59 |
java -jar mkgmap.jar --help=options |
| 60 |
|
| 61 |
to obtain an up to date and complete listing of options. |
| 62 |
|
| 63 |
Also consider examples/sample.cfg as a starting point for your options package |
| 64 |
|
| 65 |
Processing more than one file at a time |
| 66 |
--------------------------------------- |
| 67 |
|
| 68 |
The Garmin map format was designed so that a map is made of a number |
| 69 |
of tiles, and if your map has more data than can fit into a single |
| 70 |
tile, you will have to split the map. |
| 71 |
|
| 72 |
See: http://www.mkgmap.org.uk/doc/splitter.html for a program that |
| 73 |
can do this. |
| 74 |
|
| 75 |
You can compile all of the map tiles that are created by splitter |
| 76 |
all at once, by simply listing them all on the command line. |
| 77 |
|
| 78 |
Acknowledgements |
| 79 |
================ |
| 80 |
|
| 81 |
This project is almost entirely based on the file format specification |
| 82 |
document written by John Mechalas at the SourceForge project at |
| 83 |
http://sourceforge.net/projects/garmin-img. The 'imgdecode' program |
| 84 |
from the same source was also very important in checking that I was |
| 85 |
on the right lines to producing a good file. Thanks. |
| 86 |
|
| 87 |
Steve |