How do I add bus routes?

I’m not sure how to add a bus route: should I draw a new “road” that is tagged “route=bus” and named according to the route name or number? Or, is there some kind of preferred relation that is linked to the already existing highways?

Is there some way to add a time table to the route?

Do not draw new ways.

For each bus route create a relation (second button down on the right in Potlatch, a completely separate panel in JOSM) and tag the relation as route=bus. The number of the bus can be entered in as ref=## or name=##, with, I think, ref more or less essential.

Then for each way (road) which is on the bus route make that way a member of the new relation. You may need to split the way (little scissors icon in Potlatch or ‘x’, on tools menu in JOSM) when the bus route diverges from it. If the route goes in both directions no more needs to be done, but if it only travels along the way in one direction then add either forward or backward depending on whether the direction of travel is with the orientation of the way or against it.

Bus stops are best added as separate nodes alongside the road, and can then be added to the appropriate relations.

Timetable information I know little about, but there are various tagging schemas for time based information.

I would thoroughly recommend looking at some examples. The ÖPNV-Karte http://www.ö is an OSM-based map designed to show public transport information, and is a good way to find some complete examples.

Once relations have been built it is a good idea to check that they work with various tools (see the wiki).



See also

Thanks for the pointers, especially the discussion on the Wiki. For some reason my Wiki search didn’t lead me there.

I don’t like the idea of having to split roads when there are already nodes in them, however. Let’s say that a bus takes part of one road and then turns to another road at a node. I would think it would suffice to describe the bus route information as “road 1 from node A to node B, then road 2 from node B to node C, etc.” instead of having to split road 1 at node B. I realize that there may be technical reasons having to do with how relations are implemented, but otherwise it seems wrong to me that the first road must necessarily be split at that node.

ok, i am really just a beginner, so a stupid question - what is the use of marking the bus routes as relations, and setting bus stop directions, if this information doesn’t appear on the map afterwards? also many other things I can tag, but don’t see these tags used anywere. Can one specifically include some information based on these tags on a, say, embedded OSM map?

The information isn’t shown right now, but future versions of the maps might optionally display various types of routes depending on your choice.

Also, think of it as information that may be useful elsewhere. There are other uses for the OSM information than displaying it on the OSM online maps. For example, a mobile phone application might connect to OSM and help you find your way through town via bus or subway, even if the routes aren’t displayed on any map.

The mapnik and osmarender maps on the main site are by no means the only maps that are made with OSM data.

For instance, the ÖPNVkarte is specifically made to show public transportation networks, and for that map, having bus routes and bus stop information is very crucial.

trakais, remember: it’s not the maps that are OSM, but it’s very much the database itself.

OSM is not about making the slippy map on our frontpage, it is about gathering as much information of our surroundings as possible. What is done with that data is totally up to people like you and me who make special use cases.

The slippy map on our frontpage is just a big shiny neon sign showing what we can do in a nice way, not to show everything we have.

cool, I understand. What if I wanted to retrieve and present this data in some other ways myself, where can I read about it? Also apart from the slippy map, is there a list of resources that use the OSM database in other ways, like öpnvkarte?

by the way, öpnvkarte locks to a specific region, my country is not visible. if they use the standard busroute tags, they could allow display of any area of the world :frowning:

The major reason why many maps show only a limited region, is the amount of data they have to process if they loaded the entire world. They may also have limited traffic, and want to prevent the whole world to overload it.

There are lots of lists that show where you can find maps, resources, and that’s mostly the problem: too much fragmentation of information. Your best bet would be to look in the wiki for more information, or write to the creators of ÖPNV-Karte.

OpenStreetBrowser can display PSV as well. You only have to activate the layer first.

I’m in the process of adding the National Cycle Routes to my bit of the world so this is of interest to me. The cycle routes join a road for a while and then leave it, but what if I don’t want to split the way? Isn’t there a danger of ways becoming very fragmented as different bus or cycle routes joing and leave it? Or doesn’t that matter?


It doesn’t matter, and is indeed essential the more details you add to a way. When a speed limit changes, or the number of lanes changes, or the est_width or width change then if you are tagging such details you will need to split the way.

I believe some people have been using route relations to define the complete way, although I don’t think this is currently necessary for anything if the individual sections are all correctly tagged (although I guess it makes maintenance easier if you only have the name and ref tags on the relation and not on all the sections, I think it will be more confusing in the way existing editors handle relations).