Tutorial: How to use Vespucci with offline data

Vespucci is able to use OSM data stored on your device so you can map in areas without internet coverage and upload your changes later. The documentation is not the most straightforward, so hence this guide:

  1. If you are lucky and the region you are interested in is here: https://mapsplit.poole.ch,
    you can download the needed data offline through the app.
    a) In Vespucci, first tap the two-arrows-in-opposing-directions icon and then select File…


    b) and then select Download data for offline use…

    c) A view of https://mapsplit.poole.ch will open, just tap on the desired region and Vespucci will download it. Then go to step 6)

  2. If your region is not included, you first need to download the are you are interested in. I find this service the most helpful: Geofabrik Download Server
    Get the appropriate osb.pbf file and save it to your working directory on your computer.

  3. Then you need to use the mapsplit tool that can be downloaded from github. At the time of writing, the most recent version is 0.4.0. Choose the file that has “all” in its name and save it to the same directory where you saved the PBF file.

  4. Then run this command on you copmuter (you need to have working java installation):
    java -Xmx6G -jar mapsplit-all-0.4.0.jar -tvMm -i slovenia-latest.osm.pbf -o slovenia.msf -f 2000 -z 14 -O 2000 -s 200000000,20000000,2000000
    In this example, I am using Slovenia PBF file. Replace the appropriate filename for your area. You can adjust the number after -z to select the maximal zoom that will be used. It is also possible to use a .poly file to only get a specific subarea like a city, instructions to do that are on the mapsplit github page. For getting the appropriate .poly files, I recommend OSM-Boundaries. However, in practice, I just usually use whole countries and do not bother with it. Once you have the .msf file, transfer it to your phone.

  5. In Vespucci,
    a) tap the hamburger menu, then the three vertical dots next to “OpenStreetMap data” and lastly “Configure…”:


    b) Then tap “Add API”:

    c) Choose an appropriate name and under API URL, fill in what the other entries use, as of time of the writing, it is https://api.openstreetmap.org/api/0.6/ and finally tap the memory card card icon and choose the .msf file you transferred to your phone in the previous step.

    Note that Vespucci copies the file due to peculiar Android design, so you can delete the msf file afterwards.

  6. Now to switch to using offline source instead of downloading OSM data from the internet, choose the tickbox next to your new source, in our case Slovenia:


    (to go back to online source, tick “OpenStreetMap”)

  7. Now, when you want to edit an area coverred by what you downloaded, you can use the “Load current view” function even when you are completely offline.

  8. Of course, when you are offline, you cannot upload your changes to OSM, so use the functions “Export changes to OSC file” and “save to JOSM file…” from step 1) b). Due to Android design, the files do not get saved with an extension, so use .osm for JOSM and .osc for OSC. When you get online again, you can load the changes with"Apply changes from OSC files" or “Read from JOSM file…”. For this to work, it seemed to me you first need to Load current view that is bigger than the one used originally. Of course, you could also use these files in JOSM for example. OSC seems to only save the changes, JOSM files save the new state after your edit (so the file is much bigger).

The original documenatation is here: Going completely offline with Vespucci - Vespucci. It is more a technical explanation what is going on behind the scene and it took me some time to figure out what I needed to do. I hope this quide will make it easier for other, I will also try it ot be included in the official documentation in some form. If anything is not clear or there is a mistake, please let me know.

To try later:
it should be possible to also save background imagery with mapsplit, some docs are here: Generating MBTiles files with custom imagery - Vespucci

4 Likes