Tag Archives: VTT

generating maps for Garmin Etrex Vista HCx from openstreetmap osm files

I needed a map of Ireland.

You need to have java installed.
Here’s how I made it:

Download Splitter(here)
Download mkgmap (here)
Download the open street map from geofabrik(here)
Update: I recommend to download *.osm.pbf files.
Install all java stuff in a directory called, for example, in a linux box, ~/gps/
In the same directory, put all the other files you will download following this post.
run:

java -Xmx1500M -jar splitter-rxxx/splitter.jar your_map.osm --output=xml

then edit template.args
add something like:

country-name="FRANCE"
country-abbr="FR"
generate-sea=multipolygon,floodblocker
gmapsupp
route
net
remove-short-arcs

then run:

java -Xmx1500M -jar mkgmap-rxxxx/mkgmap.jar -c template.args

the 1500M is the amount of memory.
Try to allow as much memory as you can.
If you see:

Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
at it.unimi.dsi.fastutil.longs.LongArrays.ensureCapacity(LongArrays.java:107)
at it.unimi.dsi.fastutil.longs.LongArrayList.ensureCapacity(LongArrayList.java:202)
at it.unimi.dsi.fastutil.longs.LongArrayList.size(LongArrayList.java:271)
at uk.me.parabola.splitter.SparseInt2ShortMapInline.resizeTo(SparseInt2ShortMapInline.java:97)
[...]
you need more memory

A file named osmmap.img will be generated.
Rename it as gmapsupp.img, then copy it to the “Garmin” directoy in you GPS’ memory card.