Why not ask your question on the new OpenStreetMap Community Forum?


I have to create a navigation system app for a piece of land (1km * 1km). Currently, the piece of land is empty but there are plans for adding roads. My task is to add the planned roads onto an existing map. Navigation is also required for the added roads.

Where do I start and what are the applications I need to do this? Do I need to host my own tile server?

asked 16 May '19, 10:03

Feruses's gravatar image

accept rate: 0%

Creating a full OSM stack for this is likely far more work than you are willing to do.

The simplest way forward would likely be this:

  1. Obtain an OSM data file for the region of interest, e.g. by downloading it from OSM in JOSM.
  2. Modify the file in the JOSM editor (you cannot use Id for this), adding the planned roads as if they were already there. Do not upload your changes to OSM! Save them to a file only.
  3. perhaps renumber the file to get rid of negative IDs - might not be necessary, depends on whether the tools below can work with negative IDs or not. The command-line "osmium" tool can renumber.
  4. load the file into Maperitive and create a map, or map tiles, from there (alternatively, set up a tile server with osm2pgsql, mapnik, renderd, mod_tile as documented on switch2osm.org to get the "true" OSM look and feel but this is likely overkill)
  5. for navigation, download Graphhopper and load the file into it

Of course if you want a web site that shows your modified map and allows navigation, you'll have to code that yourself using your self-made tiles and your local Graphhopper service.

Please do not under any circumstances upload planned road data to the main OSM database. Firstly, we don't generally record planning data, and secondly, routers would not use these planned roads anyway. In your own local file you can act as if the planned roads were real, nobody cares, but you cannot do that on OSM.

permanent link

answered 16 May '19, 10:18

Frederik%20Ramm's gravatar image

Frederik Ramm ♦
accept rate: 23%

edited 16 May '19, 10:19

I will try this out. Thank you very much!

(16 May '19, 10:24) Feruses

Hi! When I tried opening my OSM file (modified with JOSM) on Maperitive, I received this error "Script execution error (line 1): The file could not be loaded: Node @lat attribute is missing." Do you know what the issue is?

(16 May '19, 10:49) Feruses

I guess you might have deleted a node, and JOSM perhaps leaves the deleted node in the file with an action=delete marker but drops lat/lon attributes, and then Maperitive is unhappy. You'd have to find the objects with action=delete in the XML file and remove them, OR you could use JOSM's "purge" function (instead of "delete") to get rid of them; "purge" does not leave a "deleted" object in the file.

(16 May '19, 12:18) Frederik Ramm ♦

I would also add that if you want to be able to do offline navigation on a phone, you can complete steps 1 and 2 and then run that osm file through OsmAndMapCreator to give you a *.obf that can be sideloaded onto your mobile device.

(16 May '19, 19:57) InsertUser

Thanks a lot for your help! I managed to modify my map via JOSM and created the map tiles through Maperitive. I would like to ask, how do I go about adding these map tiles into my web application?

(21 May '19, 03:21) Feruses
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 16 May '19, 10:03

question was seen: 1,993 times

last updated: 21 May '19, 03:21

powered by OSQA