OpenStreetMap

GeoPaparazzi, a survey tool for OSM (too)

Posted by Cascafico on 10 December 2019 in Italian (Italiano)

Intro

When I first came across GP, I appreciated the fast and simple interface that allows to spare menu navigation time in favour of environment observations. Besides, in GP very few things are predefined, allowing you to customize background maps and forms which are the main features for an efficent survey. What is apparently missing is a compatibility with Openstreetmap: some way to easily get osm-xml format files suitable to be piped to JOSM editor. Of course GP is not an OSM integrated editor such as Vespucci, OSMcontributor, etc. which require stable data connection, but its strength is in flexibility, quickness and simplicity in data gathering.

Form presets

GP forms help to provide a GUI with human readable input and structured output. In order to show you the different recording possibilities, GP comes with predefined forms; these forms define mainly text notes, but also photo and sketch notes Forms are defined in tags.json file (file manager, built-in storage > geopaparazzi folder). The simple trick to have an OSM ready survey tool is customizing tag.json. Starting reading the default one could give you an idea about structure to be used for obtaining OSM xml’s.

OSM customization

Note menu Items menu

To modify tags.json you can use a json editor app (like ie: “Json genie”) directly in your mobile device. This app allowed me to clone and customize several other form items for OSM.
As a starting point I used the following ugly (but working) code:


[   
   {   
      "forms": [   
         {   
            "formitems": [   
               {   
                  "key": "traffic_sign",   
                  "mandatory": "yes",   
                  "type": "string",   
                  "value": "maxspeed"   
               },   
               {   
                  "key": "maxspeed",   
                  "type": "stringcombo",   
                  "values": {   
                     "items": [{ "item": "30" }, { "item": "40" }, { "item": "50" }]   
                  }   
               }   
            ],   
            "formname": "speed traffic signs"   
         }   
      ],   
      "sectiondescription": "record traffic signals",   
      "sectionname": "traffic signs"   
   }   
]   

The first form item defines the mandatory OSM tag traffic_sign=speed, while the second form item allows you to record the sign speed in a set of predefined values via “stringcombo” (drop-down menu). At the bottom the section definition gives the name of buttons in geopaparazzi notes menu. Overwrite tags.json with the lines above. Once GeoPaparazzi is restarted (maybe its cache should be cleaned also) tapping the notes button should display another single “traffic signs” button (the name of the section). Tapping “traffic signs” should display the form in which you can choose the speed of the traffic sign.

If something goes wrong

Don’t worry about overwriting original tags.json: if things start to be messy, delete it and, once restarted, GP will take care to recreate default forms.

Other tags

You can find some other form items with different OSM key-values, combos, dates and check boxes in this tags.json. Hopefully I will start a repo for other OSM themes. Note: I’ve left “AI” section just as a cue for date recording, but section is not fully applicable for OSM k-v.

Then?

Forget about export function for your survey: GP stores the notes also in its project file (whatever.gpap you’ll find with file manager in root built-in storage) which can be converted in a shot by gpap converter by Francesco Frassinelli. Load the resulting osm-xml file in JOSM and you have a layer ready to upload. Of course I suggest a conflation check before going any further.

Android notes

In my Android version GP folder in located in internal storage and it’s called geopaparazzi. For some reason default installation stores project files in root folder, which is rather weird.

Comment from RobJN on 11 December 2019 at 01:14

Interesting. Sounds similar to an app called Input which I’ve been meaning to test for some time. Perhaps I’ll compare both over the holiday break.

Input app: https://www.lutraconsulting.co.uk/products/

Comment from Cascafico on 12 December 2019 at 10:47

Input is similar to Qfield, which I recently tested in extra OSM projects. In my opinion, tranferring surveys in OSM is much quicker if ERSI formats and QGIS are not involved.

Login to leave a comment