| # OSM Combiner

Introduction System requirements Downloading maps Using OSM Combiner Java memory Credits Licence Questions?

| # OSM Combiner

# Combine OSM maps with OSM Combiner

## Introduction

You can download Openstreetmap based maps for Garmin devices from the website garmin.openstreetmap.nl in various flavors and for all countries in the world. However, there are a few drawbacks:

1. the size of the area that you can get in a single download is limited;
2. every map that you do download has the same name;
3. if you download maps of neighboring countries, there is always an overlap. This is something you should avoid, since it causes problems on the device.

The second issue can be addressed by renaming the map with JaVaWa GMTK (the map on the computer) or with JaVaWa Device Manager (the map on the device), but these programs cannot solve the third issue.

The solution is joining multiple maps to a single one, and eliminating the overlapping segments. This can be done with OSM Combiner, and you can rename the map at the same time.

Note: OSM Combiner is designed exclusively for the maps from garmin.openstreetmap.nl and OpenFietsMap.nl. It has not been tested with other free maps, but it should work with any mkgmap-generated map. With non-free maps it certainly doesn't work.

## System requirements

OSM Combiner requires Java version 6 or higher on your computer.
Windows users can download Java here. If you have a 64-bit version of Windows, get the 64-bit version of Java.

On the Mac it depends on the version of OS X. When you have Leopard or Snow Leopard and you run Software-update regularly you will have the right version on your Mac.
Users of (Mountain) Lion can get Java here: http://support.apple.com/kb/DL1421, or the one from the Java website.
The version of Java under Tiger is unfortunately not the right one, but on this site Tiger users can acquire a working alternative.

## Downloading maps

To use OSM Combiner you have to download the desired maps first. garmin.openstreetmap.nl is offering several downloads; for OSM Combiner you need the file whose name ends in `_tiles.zip` or the file whose name ends in `_gmapsupp.zip` (eg `osm_generic_gmapsupp.zip` or `osm_generic_tiles.zip`). Extracting the zip files is not necessary.

Preferably use the first type (`_tiles.zip`), because these contain additional files to create the overview map. Without those extra files the overview map will be an empty rectangle; not so pretty when you zoom out further in Basecamp or MapSource. On the device it doesn't matter, because the overview map isn't used there.

It is strongly recommended to download all desired maps consecutively. This is because with every update of the maps on the server of garmin.openstreetmap.nl the numbering of the map segments may change, so that the overlapping segment IDs of a previous downloaded map match up with those of a new one. It is essential for OSM Combiner that the IDs of the overlapping segments match.

You can also use other free maps, whether in the form of a combined .img file meant for devices (usually named gmapsupp.img) or as separate map segments. OSM Combiner can handle archives containing these files in .zip or .7z format.

## Using OSM Combiner

1. When OSM Combiner is started, first you will get a choice where to put the (temporary) folder that will contain the map files. Provide a sufficient amount of space; about 1.5 times the size of the downloaded maps together. On the Mac you will need 3 times that amount, because the map needs to be converted too. If you choose to create a gmapsupp.img file too (for the device), then there is additional space with a factor of 1.5 needed (in total 3 or 4.5 times the size of the downloaded maps; depending on the operating system).
2. In the next step you will see a list; drag the downloaded files to this list (simultaneously or one by one). The files will be extracted; a new window shows the progress. After extracting, you can close the new window.
   The list now shows the map segments; clicking the button "Show map coverage" will show a map indicating the coverage of the map segments.
3. In the final step you need to enter some data. These are:
   - The "Family ID"; a number that isn't used yet by one of the maps on your computer or on your device (you can check which Family ID's are already in use with JaVaWa GMTK and JaVaWa Device Manager).
   - The name as it will be shown in MapSource and BaseCamp on the computer, and the name that shows up in the map menu of the device.
   - The TYP file controls the design of the map. You can leave this blank, or select one of the available options: "Mapnik" for the regular routable map, "GRnew" for the experimental version of the map, "OFM" for the OpenFietsMap and "OFM_hike" for the combination of the OpenFietsMap and the "Hiking" layer (more info about this on the site OpenFietsMap.nl).
   - When you check "Create gmapsupp.img", then a file ready for use on a device will be created too (but see the note at Java memory). This option is not available when you have selected more than 3.5 GB of map segments.
   - The "Java memory" button lets you adjust the amount of memory for mkgmap; the program that does the actual work. The default setting is usually sufficient, but when you get error messages you can change this. More on this here: Java memory.
4. Now click "Start", and mkgmap will generate the required index files (and optionally gmapsupp.img.) The progress is shown in a dialog.

OSM Combiner can install the map right away when it is finished, but you have the option to install the map later when you want to move it first.

Under Windows the result can be found in a subfolder (with the specified name for the map) of the folder you chose at the beginning. Put this folder in a location of your choice, and install the map with `install.exe`. You can also convert the map to the .gmap format with JaVaWa MapConverter.
Uninstalling the map can be done with `uninstall.exe`, through Windows Control Panel or with JaVaWa GMTK.

On the Mac the map is automatically converted to the .gmap format. The result can be found in the folder you chose at the beginning. When installing a copy of the map will be made; after installation you can remove the folder you chose at the beginning.

You can install, uninstall or move the map with JaVaWa GMTK.

## Java memory

It may be that there isn't allocated sufficient memory to mkgmap; in that case you have to adjust the value yourself. The type of operating system and the amount of physical memory determines the maximum you can set.
Generally speaking, keep it lower than about 75 - 80% of the amount of memory of your computer. If your OS is 32-bit, don't set it higher than 1400 MB. It may take some experimenting; when mkgmap doesn't succeed in creating the necessary files, you can always try again with another value.
Creating a gmapsupp.img requires a lot of additional memory, so don't check that option unless you really need it.

The dialog also shows some information about Java: the version number, and whether it is a 64-bit version or not.

## Credits

The idea for OSM Combiner is based on the command line tool OSM-Combi of OpenFietsMap.
OSM Combiner uses the applications mkgmap and GMapTool; the Windows version of OSM Combiner also uses 7-zip and NSIS, and the Mac OS X version uses the command line version of The Unarchiver.

## License

Copyright (C) 2014 JaVaWa
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

## Questions?

Do you have questions about this application? Ask them on: forum.openstreetmap.org.