4.5.3. Csv
The CSV map driver allows reading map items from a CSV file. It is particularly useful for displaying custom points of interes.
4.5.5. Adding map items by osd commands
One can add new items which are saved on exit to a csv map runtime by OSD commands. Please see map_add_curr_pos command in the OSD commands description section for an example.
4.5.5.1. Special Case: IGO8 (speed camera) files
The speed_cam OSD item can use speed camera data from IGO8 files, which are a type of csv file.
If your IGO8 file comes from http://speedcamerapoi.com/download.php, the following line should be used:
<map type="csv" enabled="yes" data="/path/to/igo8/file/speedcam.txt" item_type="tec_common" attr_types="position_longitude,position_latitude,tec_type,maxspeed,tec_dirtype,tec_direction" />
Sometimes, an IGO8 file has an ID column as its first column. Then the following should be used:
<map type="csv" enabled="yes" data="/path/to/igo8/file/speedcam.txt" item_type="tec_common" attr_types="id,position_longitude,position_latitude,tec_type,maxspeed,tec_dirtype,tec_direction" />
4.5.6. The csv File
Contents of an example csv file is shown below, and corresponds to the example line for navit.xml shown above.
01,23.657,-46.7678,The Sunny Hotel
02,23.457,-46.7878,Spa Hotel
03,23.437,-46.2378,The Railway Hotel
Note:
No trailing comma
Each item is defined on a new line
Each column corresponds to the
attr_typesattribute in the<map ...>line in the example above.
4.5.7. Garmin GPX POI
Since the native GPX files (note: only fixed point like POI, not tracks or waypoints) have the same layout as a csv file (without “id” column) and it can be directly loaded using the csv method.
<map type="csv" enabled="yes" data="PATH/TO/poi.gpx" item_type="poi_custom0" attr_types="position_longitude,position_latitude,label" />
Choose any of the poi_customX item_type and define a icon image using the poi_custom0 poi-layer. Keep in mind that you can’t have mixed POI’s in one file, or you have to add a extra column in the GPX file defining the icon-image. Instead use different GPX files for each poi_type and define the corresponding images with the poi_layer.
4.5.8. Android Issues
Currently, the Android builds do not include the required plugin line in navit.xml, although the csv map driver itself is built. To enable csv maps on Android, add the following line into the plugins section of your navit.xml:
<plugin path="$NAVIT_PREFIX/lib/libmap_csv.so" ondemand="no"/>
For more information, see .
4.5.9. WinCE Issues
You will need to use the full path to the CSV file, and not $NAVIT_SHAREDIR
<map type="csv" enabled="yes" data="\SDMMC\navit/maps/speedcam.txt" item_type="tec_common" attr_types="position_longitude,position_latitude,tec_type,maxspeed,tec_dirtype,tec_direction" />