Show traffic lights on map (2017 version)
  • This is a continuation of the thread "Show traffic lights on map", which started in April 2015.

    Unfortunately Mapfactor still doesn't follow our requests for traffic lights in their maps.

    To overcome this "issue" I rewrote my python script to create "traffic lights" maps  as POI maps for you.
    The python script is now written for windows. It downloads the "full pbf format" countries, it extracts the necessary data, and it creates the mca file for you using DiggerConsole: all automatically.

    You can find the script with the supporting files on my github site: https://github.com/hvdwolf/Navigator-traffic_lights
    You need my script (of course), python for windows, gpsbabel, DiggerConsole (links on my github repository).
    "Simply" follow the Readme on the front-page of my github repository. This should be workable for everybody who is not a real NOOB on windows.

    To help you I already created maps for Europe, North-America, South-America, Russia and Asia.
    (The script does everything automatically. I simply select a new region with its countries and wait until the script is ready)

    If you are lazy then download the "TrafficLights" zip for your region, unzip it and copy the countries of your liking into the /Android/data/com.mapfactor.navigator/files/navigator/data folder where all the other maps are also located.

  • 18 Comments sorted by
  • Hi,

    I created a new "release" 2017-1.1. Files can be downloaded from https://github.com/hvdwolf/Navigator-traffic_lights/releases/tag/2017-1.1

    The files are much bigger now, but compared to the country maps they are still very small.

    Note that in hardware renderer mode on android 5.x.y, the icons are really small as are all other POI icons.
  • Thank you very much from a lazy one ;)
  • From another lazy one, I've done all you say, and extracted the relevant .mca file to the data directory. How do I make traffic lights appear? I thought they would be in one of the poi categories, but no luck.

  • No, they just automatically appear on the map ;-)
  • Or not as the case may be. I see no lights. Any ideas?
  • you do not extract, just save the mca file
  • I extracted a MCA file from the zip I downloaded.
  • Note that "traffic light" density as registered in OpenStreetmap varies hugely per country.
    the Netherlands have a very good coverage, but even Germany has not so good coverage and also varying per city (Based on your name I assume you are not German though ;) )
    Some countries have hardly any traffic lights/signs registered in OSM.
    Please take a look on openstreetmap to see whther the traffic lights you are expecting are indeed in Openstreetmap.
     

    And of course: For which country did you try the mca? There could be an isue with the file.

    And the data folder: Did it already contain mca files for your countries? Note that there are 2 data folders: one on your internal memory and one on your SD-card. Whether they are used ornot. Copy the mca files in the correct "filled" one.
  • I'm in the UK. The map is the OSM one for UK. The traffic light file is for Great Britain. I'm looking where I know there are traffic lights on the OSM map. The MCA file is with my map file in the data directory.
  • I cannot see any traffic lights anywhere, not even in Amsterdam
    did you set Show on map?
  • @tomas: What do you mean with show on map? I did not need to activate anything. To make sure I disabled all POIs and restarted Navigator and they still show on the map.

    If you look at the picture of my other post about day/night colors you can see the traffic lights in the night screen capture.

    Netherlands: Zwolle, Ceintuurbaan 3;  or Amsterdam, Prins Hendrikkade 96 (many traffic lights)
    For UK I took the first one from the file lat=52.04442, lon=-2.72041  (Hereford, crossroads Walnut-Tree avenue - Holme Lacy Road with Ross road)

    However, In Germany, Berlin, in Unter den Linden
    coordinates: lat=52.517463900, lon=13.395025800 -> visible
    But slightly further in the street (nr 24 or 16), crossroads Unter den Linden with Friedrichstrasse, the traffic lights are not displayed but they are available in the gpx and in the (unpacked) mca. 
    also, when slightly following Friedrichstrasse up north they are available on the next crossroads (Georgenstrasse).


    But: Detmold, Bielefelderstrasse 12 (crossroads) does have a traffic light in OSM (modified 2014-05-17 by chattiewoman) but that one is NOT in my gpx/mca. 

    Really strange: it seems like issuess with my file(s) and issues with navigon.
    I will check my script and keep all intermediate files to check.

    (Note: I don't see a difference either in software or hardware renderer.)


  • sorry, I can see them, but there are miniscule, I need to enlarge them

  • OK, I can see a traffic light at the Hereford intersection but not others more locally that I know are in the OSM data. Also, the OSM data has multiple signals at the Hereford junction but only one is displayed in Navigator.
  • @tomas: That is exactly what I reported in the 3.0 test results here
    The hardware renderer does not scale the icons correctly. Not for any POI icon.
  • The problem is gpsbabel. I convert from an .osm format, containing all traffic lights, to gpx. A lot of traffic lights "get lost".
    If I convert to csv they are all in the csv file.

    In other words: I will rewrite the script to output csv, convert the digger config to use csv,  and try again.
  • I rewrote the script and the digger config and I am now rerunning it. Some mca files don't change at all in size. Some are 10 to 60 (!) times bigger.
    For example: France 28KB ->1.1MB
    Germany: 69KB to 3MB (and Berlin now has lots and lots of traffic signs and also the Detmold traffic signs are now appearing)
    Great-Britain: 29 Kb -> 1.0 MB

    (and digger now takes much longer of course)

    To be continued :)

  • Working fine now! Thanks.
    And POI size can be controlled from Settings | Map Customisation | Map Scale > Icon size


  • I know it can be controlled from that setting but on android 5.1 in hardware renderer you need to set the icon size to the max value.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion