[mkgmap-dev] [PATCH] alpha support for motorway exits and service areas
From Mark Burton markb at ordern.com on Sun Mar 8 12:50:23 GMT 2009
Hi, The attached patch provides basic support for processing motorway exits. It's still work in progress but I am posting it so that people can try it out, find what breaks and suggest improvements. Exits in the garmin world have to be associated with a motorway (sounds reasonable) but they don't have to coincide with a node on the motorway, i.e. the exit node doesn't have to be on the motorway! In the case where the exit is defined with a "motorway_junction" tag on one of the motorway's nodes, nothing needs to be done for an exit POI to be generated as mkgmap will work out the association itself (only for roads that are "motorway" or "trunk"). If your "motorway_junction" node is separate from the motorway (not very sensible, perhaps) or you are using a "highway=services" tag on a node (which probably will be near the road but not actually on it) you will need to add a "exit:road_ref" tag to specify the reference of the road that the exit is associated with. Here's example tags that associates a services with the road A41. name=Toy Town Services highway=services exit:road_ref=A41 Note, at this time "highway=services" for areas is not yet supported. Seems to me that it could be by using the new area POIs functionality to make a POI automatically. One attribute of exits is that they exit to somewhere and you need to be able to specify where the exit is going to because mkgmap can't guess that (well, not yet, anyway). To do this, use an "exit:to" tag. So you can say: highway=motorway_junction ref=5 exit:to=Telford East Garmin allow you to specify all sorts of facilities info for an exit and this is described in the cgpsmapper docs. Of course, there is no standard OSM means to express that so we have yet another tag "exit:facility" that should be set to a comma separated set of values that describe the facility. The syntax is exactly the same as used in mp files. Something like this (values are examples, not sensible): exit:facility=0x01,N,0x04,Hello World Yet more flexibility is introduced by the fact that the type code for the exit can be one of a huge range. At the moment, I am using: highway=motorway_junction { name '${ref} ${name}' | '${ref}' | '${name}' } highway=motorway_junction [0x2000 resolution 16] highway=services { name '${ref} ${name}' | '${ref}' | '${name}' } highway=services [0x210f resolution 16] 0x2000 means "exit no services" 0x210f means "exit (service") I played around with the codes and on my gps some codes make little symbols appear to show that the exit has food, hotel, etc. We can probably make it use a suitable code from the facilities info but I haven't looked into that yet. Oh yes, you must have a region defined for your map, if you don't, the exits will not be generated. One disappointment. So far, I have not yet been able to make the exits findable. I am working on that aspect but don't know when I will succeed. All feedback is welcome. Cheers, Mark -------------- next part -------------- A non-text attachment was scrubbed... Name: mb-exits-v1.patch Type: text/x-patch Size: 39748 bytes Desc: not available Url : http://lists.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20090308/8e83821e/attachment.bin
- Previous message: [mkgmap-dev] [PATCH] POI Addresses for areas
- Next message: [mkgmap-dev] [PATCH] alpha support for motorway exits and service areas
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the mkgmap-dev mailing list