Generating missing tangogps tiles

TangoGPS is nice, but it wants to download tiles. However, I already have a working mapnik setup, so why bother the OpenStreetMap servers with tile requests?

  1. Set up a mapnik environment like I explained with gpsdrive, but use the -m switch to osb2pgsql.
  2. svn co http://svn.openstreetmap.org/applications/rendering/mapnik/
  3. Edit set-mapnik-env to configure it. Make sure that MAPNIK_TILE_DIR points to Maps/OSM as used by TangoGPS.
  4. ./set-mapnik-env ./customize-mapnik-map > osm.xml
  5. Edit generate_tiles.py to customise the area that you want to generate. Make sure that when setting bbox the first latitude is smaller than the second latitude, and the same for longitude.
  6. Run ./set-mapnik-env ./generate_tiles.py and watch it paint your tiles. Note that if a tile has already been downloaded, it will not download it again.