Professional Documents
Culture Documents
Reference Manual
HydroloGIS S.r.l.
Revision 5.3.0
2017-02-26
Table of Contents
................................................................................................................ vii
1. Because not all paparazzis are evil! ........................................................ 1
2. Installation ............................................................................................. 3
2.1. From Google Play ....................................................................... 3
2.2. Manual Installation ...................................................................... 4
3. The Main View ..................................................................................... 11
3.1. Action Bar ................................................................................. 12
3.2. The panic button ....................................................................... 13
3.3. The dashboard buttons .............................................................. 14
3.3.1. Notes ............................................................................. 14
3.3.2. Project Information .......................................................... 18
3.3.3. Gps Logging ................................................................... 19
3.3.4. Map View ....................................................................... 21
3.3.5. Import ............................................................................ 21
3.3.6. Export ............................................................................ 26
4. The Main View Menu ........................................................................... 29
4.1. Select tile source ....................................................................... 30
4.2. Create a new project ................................................................. 32
4.3. Load an existing project ............................................................. 33
4.4. GPS Status ............................................................................... 33
4.5. Exit ........................................................................................... 33
5. The Map View ..................................................................................... 35
5.1. Map view tools .......................................................................... 36
5.2. Map navigation .......................................................................... 37
5.3. Add Notes ................................................................................. 39
5.4. The Notes List .......................................................................... 39
5.5. Add Bookmark .......................................................................... 42
5.6. The Bookmarks List ................................................................... 44
5.7. Gps log analysis tool ................................................................. 44
5.8. Measure tool ............................................................................. 45
6. The Map View Menu ............................................................................ 47
6.1. Gps data list ............................................................................. 48
6.2. Spatialite data list ...................................................................... 50
6.3. Go to ........................................................................................ 51
iii
Geopaparazzi Reference Manual
iv
Geopaparazzi Reference Manual
v
vi
vii
viii
1
Because not all paparazzis are evil!
Even if the main aim is in the field of surveying, it contains tools that can be of great
1
use also to OpenStreetMappers as well as tourists that want to keep a geo-diary.
1
http://www.osm.org
1
• fits in any pocket and can be always at hand, when needed
• gives the possibility to take georeferenced and possibly orientated pictures
during a survey, with further possibility to import them into GIS applications
2
like gvSIG
• is able to easily exploit an internet connection, if available
• is extremely easy to use and intuitive, providing just few important
functionalities
• georeferenced notes
• georeferenced and oriented pictures
• gps track logging
• form-based data surveys
• easy export of collected data
• a map view for navigation with support for raster tiles and spatialite vector data
2
http://www.gvsig.org
2
2
Installation
1
https://play.google.com/store
3
Manual Installation
The following example explains how to install version 4.4.0. We suggest to always
use the latest version available.
2
• from your devices visit the geopaparazzi releases page making sure to load
the desktop site (not the mobile site).
• select the releases tab and pick the last available release:
2
https://github.com/geopaparazzi/geopaparazzi
4
Manual Installation
5
Figure 2.3. Geopaparazzi github page.
Manual Installation
6
Manual Installation
7
Figure 2.4. The releases panel.
Manual Installation
8
Manual Installation
9
Figure 2.6. The download dialog.
Manual Installation
10
3
The Main View
All the features that need to be quickly accessed, such as toggling GPS on and
off, creating a note or taking a picture, as well as visualizing the current position
on a map, are accessible from the dashboard.
11
Action Bar
The action bar, from right to left, presents the following functions:
The info button shows information about the current selected map and the status
of the gps. If the gps has acquired a fix, information about the position is given:
12
The panic button
At the bottom of the view the orange Panic Button is visible. Once pushed it leads
to the panic! view, which presents two buttons:
The panic button sends a request for help sms with the last available GPS position
to a phone number that can be configured in the [settings] of geopaparazzi.
13
The dashboard buttons
The just send position button opens up the sms dialog directly filling in the position
without any request for help message. It is meant for quick sending the current
position via sms so that it can be opened from Geopaparazzi.
3.3.1. Notes
• text notes
• picture notes
• sketch notes
• form-based notes
To access them you can tap on the first icon of the dashboard, the take notes
icon. Once you tap on it, the take notes dialog appears:
14
Notes
The switch button at the top of the view gives the possibility to choose whether
the note will be inserted in the current gps position (in case gps is on) or in the
the center of the map (the crossfade).
At the right end of the actionbar the quick note buttons are placed. From left to
right:
• The Quick text note button, which opens a simple dialog, inside which the
text note can be written. Want to save the note? Tap on the ok button. Want
to trash it? Tap on the cancel button.
15
Notes
• The Quick picture note button, which will launch the camera application
that comes with your android system which gives lots of possibilities of
customization of the images size, focus and so on. This has one drawback,
which is the fact that we are not able to pick the azimuth of the camera shot at
the exact moment it is taken. The azimuth is therefore recorded at the moment
the camera application is closed. That means that to have a realistic azimuth,
you need to take the picture and stay with the device in the same position of
the snapshot until you have closed the camera app.
• The Quick sketch note button, which allows you to draw on a small panel and
save your sketch. One can change stroke style, color, and width. The sketch
1
panel comes from the open source app Acrylic Paint .
1
https://github.com/valerio-bozzolan/AcrylicPaint
16
Notes
Form based notes are complex notes that allow for better surveys. Some
examples are available in the base installation of geopaparazzi.
The example button in particular shows all the possible form widgets available:
17
Project Information
To understand how to create forms, have a look at the section dedicated to ???.
It shows:
Apart of the dates, that are set by the system, all data can be changed and saved
through the save button.
It is also possible to add additional metadata to the project information. The plus
button at the right side of the actionbar openes an input dialog that allows to define
a key, a labell and a value for the new metadata entry:
18
Gps Logging
To start logging, the user simply has to push the logging button.
Once it is tapped, the user is prompted to insert a name for the log
or to accept the one generated based on the current date and time
( log_YYYYMMDD_HHMMSS ).
It is also possible to attach the new log to the last created log by checking the
box: Continue last log. In that case the proposed name of the log (or any user
inserted) is ignored, since no new log is created.
19
Gps Logging
Figure 3.11. The new log dialog. From here it is possible to continue the last log.
Once logging has started, the logging button will turn orange and the gps status
icon blue.
Figure 3.12. The stop logging button with its red sign.
To stop logging, the same button is used. Once tapped, the user is prompted to
verify the action.
20
Map View
The map view presents a map and a set of tools that can be used to navigate the
map, make measurements or edit datasets. The various tools are presented in
the section dedicated to the Section 3.3.4, “Map View”.
3.3.5. Import
21
Import
• gpx datasets
• bookmarks
• WMS
• mapurl configuration files for online tiles
• default spatialite databases
• geopaparazzi cloud projects
GPX
By tabbing on the GPX icon, the user is taken to a simple file browser.
The browser only shows folders and files with gpx extensions. On selection, the
file is imported.
Bookmarks
Bookmarks can be imported from csv files that must be placed in the root of
the sdcard and the name of which has to start with the part bookmarks and to
end with the extension .csv.
Geopaparazzi will let the user select the files to import if more than one are
available and load the bookmarks from there and import only those that do not
exist already.
22
Import
The format of the csv is: NAME, LATITUDE, LONGITUDE as for example:
WMS
2
It is possible to import basemap configurations from WMS getCapabilities URLs.
Once the getCapabilities URL is inserted and the refresh button is tapped, the list
of available layers is presented. The selected layer is then imported in the list of
available tile sources.
Mapurls
Since the creation of a mapurl configuration file for WMS services is complex, a
small service has been created, that automatically generates mapurls for known
services.
2
https://en.wikipedia.org/wiki/Web_Map_Service
23
Import
If requested, the service will consider the device’s position to gather only dataset
in that area. Also some minor text filters can be added.
The service can then simply be downloaded. It will install the mapurl inside your
system. The user is prompted for a custom name to name the service after, else
the original name will be used. Since the original name could be duplicated in
different services, the prefix tanto_ will be added in that case.
This service is in an experimental state right now, but it works fairly well. If you
3
experience problems, please report them at the homepage of the service .
The same link also contains instruction about how to suggest to suggest new
WMS services.
3
http://tanto.github.io/geopapurls/
24
Import
Default databases
When tapping the default database import button, the user is asked to name the
new database to create. Let’s use the default name proposed based on the current
date and time:
The newly created database is editing ready and contains a layer of each type.
Since it is a template db, the attributes table have been created as generic fields
with names from field1 to field10. It is very generic and simple, but still of use
when you have to quickly collect some data with attributes and have no database
prepared..
25
Export
3.3.6. Export
• kmz
• gpx
• bookmarks
• images
• geopaparazzi cloud projects
KMZ
In the export:
• the notes are placed as red pins having the first letters of the text content as
label
• the images are placed as yellow pins
4
http://earth.google.com/
26
Export
GPX
The lines and notes data are exported to gpx, creating tracks and waypoints.
Bookmarks
Geopaparazzi will write to the file only those bookmarks that do not exist already
in the csv.
Images
Since images are kept inside the database, this export is handy if the user needs
to use the images inside a different software. In this case all the images of the
project are exported inside a folder and a popup message shows the folder path.
27
28
4
The Main View Menu
• Select tile source: allows the selection of a map tile source to be used as base
map
• Create new project: this will create a new project on the sdcard. A timestamp
based name is proposed to the user
• Load existing project: gives the possibility to browse the filesystem to select an
existing geopaparazzi project folder (the one with the database in it) to load it
• GPS Status: opens a GPS status application to check on satellites visibility
• Advanced: shows some advanced user options such as the application log or
custom database queries
• About: visualises the about page, which contains infos, links and
acknowledgements
• Exit: shuts down geopaparazzi properly. This is important, because
geopaparazzi is meant to continue logging also in background. Therefore, if
one uses the android home button to exit the app, it will continue to work in
background, most probably draining your battery through GPS use.
29
Select tile source
From the main menu, when pushing the tile source button, the list of available tile
sources are presented, divided by folder:
Each map source has a name and a type description between brackets.
30
Select tile source
• Map
• Mapurl
• MBTiles
• RasterLite2
The supported datasets section lists and describes all supported map types.
Through the button at the top of the view the user can filter the source types to
show.
Figure 4.3. The map type filter dialog, set to only show MBTiles sources.
which makes searching simpler when a lot of sources are present on the device.
31
Create a new project
Basemaps can be loaded from the device storage through the two buttons at the
bottom of the view. The right one allows to pick a single file to add it as a basemap,
while the left one allows to bulk load a complete folder of maps.
When a new project is created, the user is prompted to insert a name for the new
project file. This is the name that will be given to the database file that contains
all data surveyed in Geopaparazzi.
32
Load an existing project
Once the name is defined, an new empty database is created and Geopaparazzi
is restarted and opened loading the new created project.
Existing projects can be loaded using a simple file browser from within
Geoapaparazzi. The Geopaparazzi project files are visualized with a different icon
to help the user to choose the proper files.
1
The GPS status entry launches the open source application GPS test . The app
shows the current status of the satellites fix and a skymap. This often helps to
understand why the GPS is not working.
4.5. Exit
1
https://play.google.com/store/apps/details?id=com.android.gpstest
33
Exit
The exit button closes Geopaparazzi and stoppes any ongoing logging and sensor
activity.
This might seem obvious, but it is important to note that this is the only way to
properly close Geopaparazzi. Pushing the home button of the device will not
close Geopaparazzi, which will continue any activity started. This is important,
because it makes very long loggings possible even if interrupted by phone calls
or other uses of the device.
Often users that ignore this, after pushing the home screen and thinking that
Geopaparazzi has been closed, experience a faster battery drop, because of the
active application in the background.
34
5
The Map View
The map view is the central view of the application. It can be used to view the
current gps position overlayed on maps and vector datasets.
1
The map engine comes from the mapsforge project.
The supported datasets section lists and describes all supported map types. Just
to cite a few, one can view:
1
http://code.google.com/p/mapsforge/
35
Map view tools
2
• OpenStreetMap maps both when online (downloading new tiles) and offline
(visualizing those that were cached during online mode)
3
• mbtiles databases
4
• local and remote TMS tiles
• mapsforge vector files
The map view has a set of tools that can be exploited to interact with the map.
When first launched, the tools are already visible on the map. To have a cleaner
mapview, the user can long-tap on the upper right menu button to toggle the
visibility of the tools.
◦ add note (the same that is accessed from the dashboard) and list notes
(long tap)
2
http://www.openstreetmap.org/
3
http://www.mapbox.com/developers/mbtiles/
4
http://wiki.osgeo.org/wiki/Tile_Map_Service_Specification
36
Map navigation
◦ battery status
◦ center screen on GPS position and GPS status button
◦ editing tools
Figure 5.3. The map view with all map tools visible.
The navigation of the map is probably the most basic and important part.
• pan: panning of the map, i.e. moving the map around is simply done by
dragging the map with a finger. While panning, the current longitude and
latitude of the map center are displayed.
37
Map navigation
• zoom: zoom in and out can be done in different ways. There are the zoom in/
out buttons at the lower right part of the map. It is also possible to zoom in
by double-tapping on the map. Zoom in and out can also be achived through
5
pinch-zoom gestures .
• center on gps: through the lower center button it is possible to center the map
on the gps position. The button also shows the status of the GPS the same
way as the icon on the main view’s action bar.
5
https://en.wikipedia.org/wiki/Multi-touch
38
Add Notes
The add notes button opens the same notes view as the button on the dashboard.
There is only once difference. Since notes can be added both in the gps position
and in the middle of the map, to open the add note view from the dashboard, the
GPS is required to have a fix.
Instead from the map view the user can open the add note view even without
GPS signal, in which case he will be allowed to insert notes only in the map center
position.
For further information about taking notes, visit the notes section.
The notes list shows all the available notes, both text and image notes.
39
The Notes List
The icon on the right side of the actionbar allows the user to sort the notes by
different modes:
40
The Notes List
In the upper part of the view there is a textbox that helps to filter out a particular
note based on its name.
At the right side of the list 2 icon are available. The left one positions the map on
the selected note’s position while the rigth one opens a menu:
41
Add Bookmark
Bookmarks are in a layer on their own, that contains saved settings of the current
map view. When a bookmark is added, the user is prompted to insert a name for
the bookmark or leave the generated name based on the current time and date.
42
Add Bookmark
When a bookmark is added, a small star is added on the map in the center of
the screen.
Also the map bounds and zoom are saved. That way one can return to the
scenario that the bookmark represents in any moment.
43
The Bookmarks List
In the upper part there is a textbox that helps to filter out a particular bookmark
based on its name.
The user has 4 options, as the icons on each bookmark entry shows:
The log analysis tool allows to analyze the various positions of a gps log.
Once enabled, one can simply touch the screen near a gps log and information
about the nearest log point will be shown. Also the color of the text will be the one
of the currently queried log:
44
Measure tool
Activating the measure tool puts the app in measure mode. This mode disables
the ability to pan the map while enabling the possibility to draw a line on the map
and measure the line drawn.
When active, the measure tool has a red colored icon, when inactive the icon is
green instead.
45
Measure tool
46
6
The Map View Menu
The map menu gives the possibility to access some additional map tools:
1
http://www.mixare.org/
47
Gps data list
The gps data list shows the data surveyed, both points and tracks.
In the actionbar there are possibilities to select all, unselect all and merge selected
logs. The first icon from left is the notes properties button. From there some
properties of the notes can be set.
48
Gps data list
Notes can be visualized as icons or as circular shapes. The size, color and opacity
can be customized by the user. This can be usefull in those cases in which many
notes have to coexist in a small space for better readability.
It is also possible to show the label for the note and customize its size and halo.
The list of gps logs gives the possibility to customize the logs. It is possible to
change the visibility of the single track using the checkbox. The icon on the rigth
side of each entry opens the gps log properties panel:
49
Spatialite data list
The spatialite data list view holds the list of loaded spatialite databases. For each
database its spatial tables are shown and each table can be made visible or
hidden through the checkbox on each entry.
The rendering order can be changed through a combobox at the left side of each
entry.
50
Go to
New databases can be added throught the 2 buttons at the bottom of the view,
by single file or folder.
At the right part of each entry a menu is available, which allows the user to change
the style and labelling of the features in the layer, as well as its stroke dash and
zoomlevel visibility. It is also possible to zoom to a given layer extent.
6.3. Go to
• go to coordinate
• use geocoding and/or routing
51
Go to
Through geocoding it is possible to insert some address and find its location (uses
google maps geocoding).
52
Share position
From the same panel it is possible to create a route from the current position to
the inserted location.
2
The routing service used is OSRM .
Once the OK button is tapped, the route is calculated by the service starting from
the current map center to the destination point. The route is then downloaded and
placed in the gps logs tracks.
The share position entry opens the usual sharing dialog of Android:
2
http://project-osrm.org/
53
Import mapsforge data
3
If for example telegram is chosen, the sent link will look like:
The mapsforge tiles are generated on the device from a particular vector format.
This means that there are information available in the database. Problem is that,
very very simply put, the information contained is extracted differently at different
zoom levels, because in fact the library and the format have been done that way
to allow best rendering performance.
Let’s see how this works. For this to work it is mandatory that the loaded
background map is of type "map". Assume you have a job to do, are out in
the field and want view information overlayed on the ortofoto pictures from the
local WMS service.
Well, the map file you get from mapsforge looks like the following:
Once the import mapsforge data has been chosen, its panel appears:
3
https://telegram.org/
54
Points
From the view you can see that 2 types of data can be imported: points and ways.
6.5.1. Points
Since the points are often visible on a different zoomlevel then the current, also 3
zoomlevels below the current are investigated to extract data and double points
are not considered. So if you start this at zoomlevel 16, you will also get 17, 18,
19. Since the same are at a different zoomlevel will have many more tiles, about
10000 tiles are read to import the data.
You can add a filter text to import only tags containing a given text or exclude all
those containing the text.
Points are imported in the current projectdatabase and saved as forms notes
containing all the values Openstreetmap has. As such they can also be edited.
All imported notes have a (MF) in their name. That is done so one can quickly
select and remove them. Believe us, that is a feature you want to have since such
imports can generate very crowded notes lists.
55
Ways
6.5.2. Ways
Many types of ways are stored in the mapsforge map files and many of them are
actually related to areas.
Since these data are heavy, the data are imported into a dedicated
spatialite database. A database for mapsforge extracted data is automatically
created if there is none present. You will find a database named
mapsforge_extracted.sqlite always present in your maps folder. And you will
find 3 layers always present in the spatialite data layers: osm_waterlines,
osm_roads and osm_contours.
56
Ways
Figure 6.9. The mapsforge database and layer that host imported data.
Just select the data you want to import and push the start button. In the case you
selected all data types, you should see first an import dialog like this:
57
Ways
Depending on what has been imported first, the labels might not be coming from
the right osm field. In that case it can be simply changed in the spatialite layer
settings. Refer to the spatialite data list section.
58
7
Vector Editing
to be done
59
60
8
Settings & Preferences
61
Gps Settings
• define the time interval for taking a point when in logging mode
• define the minimum distance in meters, within the taken gps point is not added
to the gps log. This is useful for example in the case in which the user stops
during logging and the gps continues to supply points (due to the inaccuracy),
while instead the user stands still in a point.
• have the mapview recentered on the gps position when the position reaces
the screen border (usefull while driving)
• use network based position instead of GPS position. This can be useful for
testing purposes. The network based position is by no means precise!
62
Sms Settings
GEOPAP
If such a message comes in, the phone answers with an SMS to the incoming
number by sending the last known position.
From here it is also possible to insert the panic numbers(s), i.e. the numbers to
which a status update is sent when the panic button is pushed.
63
Screen Settings
• change the map center cross properties (size, color, stroke width)
• change the mapsforge map text size factor (normal is 1. To make text bigger,
increase the value)
• enable the always screen on mode
• toggle the use of metric/imperial units
• enable settings to optimize rendering for high density displays
64
Spatialite Settings
When a new Database has been added and the geometry does not show up, the
preference needs to be activated and Geopaparazzi restarted.
This can be used for those devices that have more than one external storage
recognized by the device.
Use it at your own risk. We use it regularly, but it needs to be done properly.
The locale of Geopaparazzi can be changed regardless of the locale used for
Android.
65
Cloud Projects Sync Settings
This setting opens a menu in which a locale can be chosen between the available
ones:
After that, each newly loaded view will be in the new locale.
This setting allows the user to set a server with user and password, to which
upload and from which download geopaparazzi projects.
1
• gvSIG Desktop with the hydrologis4gvsig plugins installed
• gvSIG Online
1
http://www.gvsig.org
66
9
Supported datasets
The following sections will detail various map source types. In case you want
to prepare tailored map datasets as map sources in one of below map formats,
please refer to the data preparation section.
9.1. Basemaps
• mapurls
• mbtiles
• mapsforge maps
• rasterlite2
67
Mapurls: Custom tiles based maps
Mapurl files are simple text files containing definitions of tile sources, either local or
remote. A mapurl file must have the file extention/suffix .mapurl to be recognised
by Geopaparazzi.
url=http://tile.openstreetmap.org/ZZZ/XXX/YYY.png
minzoom=0
maxzoom=19
center=11.42 46.8
type=google
format=png
defaultzoom=13
mbtiles=defaulttiles/_mapnik.mbtiles
description=Mapnik - OpenStreetMap and contributors, ODbL.
68
Mapurls: Custom tiles based maps
1
• the type fo tile server. Currently both standard TMS and google based
numbering of the tiles is supported by the line:
◦ type=tms
◦ type=google
• the backup mbtiles path. This one is used to save downloaded tiles in the local
mbtiles database
url=http://sdi.provincia.bz.it/geoserver/wms?
LAYERS=inspire:OI.ORTHOIMAGECOVERAGE.2011&TRANSPARENT=true&FORMAT=image/
png&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application/
vnd.ogc.se_inimage&SRS=EPSG:4326&BBOX=XXX,YYY,XXX,YYY&WIDTH=256&HEIGHT=256
• SRS=EPSG:4326
• BBOX=XXX,YYY,XXX,YYY
Just like your mapurl configuration may reference an online/remote tile sources,
your mapurl setting may reference a local tile source for offline use. This way it’s
possible to load on any smarthphone complex maps as for example the following
map that has a technical basemap with shapefiles overlayed in transparency
To be able to load such maps, one needs to prepare the tiles properly. This can
be done via in several ways as explained in the data preparation section.
1
http://en.wikipedia.org/wiki/Tile_Map_Service
69
MBTiles
The tile folder have then to be loaded in the same folder as the description of the
tile source:
url=mytilesfolder/ZZZ/XXX/YYY.png
minzoom=12
maxzoom=18
center=11.40553 46.39478
type=tms
Nothing changes against the description for the remote source apart of the url.
The url in this case represents the relative path of the tiles folder.
9.1.2. MBTiles
MBTiles is a file format for storing map tiles in a single file. It is, technically, a
2
SQLite database. See the openstreetmap wiki for more information.
The mapsforge project provides free and open software for the rendering of maps
based on OpenStreetMap. It developed an efficient binary format for storage
of OSM map data (usually with file extension .map), and is offering country
specific .map files for download. Geopaparazzi is able to render map tiles locally
from .map files and will cache rendered tiles in a local MBTiles store.
Apart from Mapsforge itself, openandmaps is also offering .map files but with a
different data bias and different render theme.
2
http://wiki.openstreetmap.org/wiki/MBTiles
70
Mapsforge maps
mapsforge
These are the standard maps generated, maintained and distributed by the
3 4
mapsforge team and can be downloaded from their server .
openandromaps
5
Openandromaps generates maps following the opencycle theme, with isolines
and more hiking related stuff. The map files are larger but worth every byte. Their
6
download area is here .
With the Oruxmaps theme that is available from the download area, the maps
look like:
3
https://github.com/mapsforge/mapsforge
4
http://download.mapsforge.org/
5
http://www.openandromaps.org
6
http://www.openandromaps.org/en/download.html
71
RasterLite2
italy_cycle.map
and a:
italy_cycle.xml
render theme file in the same folder as the map file itself.
9.1.4. RasterLite2
7 8
RasterLite2 is a raster format implemented in the spatialite database .
7
https://www.gaia-gis.it/fossil/librasterlite2/wiki?name=librasterlite2
8
https://www.gaia-gis.it/fossil/libspatialite/index
72
Overlay maps
The only datasets that can be overlayed on top of basemaps are vector maps
9
coming from a spatialite database .
9
https://www.gaia-gis.it/fossil/libspatialite/index
73
74
10
Handling datasets from and for
Geopaparazzi
• gvSIG
• STAGE
• Spatialite GUI
• GDAL
75
Installation
10.1.1. Installation
1
STAGE can be downloaded from the github releases page .
Steps:
1
http://git.io/stage_releases
76
MBTiles creation
For the creation of an MBTiles file from a set of GIS data, as shapefiles and tiff
rasters, select the module: GeopaparazziMapsCreator
77
Converstion of Geopaparazzi data to GIS data
◦ jpg: this should be used when photographic data are used (ex. aerial
images)
◦ png: this should be used when images are used (ex. technical maps)
• the output folder, inside which the database will be created
Once the parameters are set, the module can be launched by pushing the green
play button in the top right toolbar.
In case of big data the user should consider to set the memory put available to
the run module. This is done in the lower left combobox labeled Memory [MB].
The number to set is considered to be MegaBytes. A safe value to use is a bit
less than the amount of RAM available on the computer.
For windows 32bit machines it is not possible to use more than 1000 MB due to
technical limitations of Java itself.
78
Spatialite GUI
The only parameter to set are the input Geopaparazzi database path and the
output folder. It is also possible to toggle the creation of some of the data contained
in the database.
How are the data are exported from the Geopaparazzi database? The following
is created:
The Spatialite GUI can be used to create spatialite databases from shapefiles.
79
Spatialite GUI
You can find the application on the spatialite homepage, at the time of writing a
2
good version for windows is version 1.7.1 available in this download area .
We now create a new empty database in which to load the shapefile data:
You will be asked to save the database somewhere on disk. Once done, you
should find yourself with something like this, but with different path:
2
http://www.gaia-gis.it/gaia-sins/windows-bin-amd64-prev
80
Spatialite GUI
3
In this example I will import a set of shapefiles from the Natural Earth dataset ,
in particular the following ones:
3
http://www.naturalearthdata.com/
81
Spatialite GUI
4
that can be found here .
The import dialog is the important one to fill the right way:
The really important things to take care of, are underlined in red:
• the SRID, i.e. the EPSG code of the data projection. If that one is not right,
then you will not be able to see the data in geopaparazzi. Don’t even hope
in miracles!
• the Charset Encoding. Make sure to choose the right one. For example
Japanese people might want to choose SHIFT_JIS if they want to see the
labels rendered properly
• force the creation of the spatial index
If you then the push the ok button, you should find yourself with an ok message
like this after the import:
4
http://www.naturalearthdata.com/downloads/10m-cultural-vectors/
82
Spatialite GUI
Right-click on the database name and select the Update Layer Statistics
command.
Depending on the amount of data it should keep your harddisk working for a bit.
Don’t think it finished unless you see a result like the following:
Move the spatialite database to your device, fire up geopaparazzi and go directly
to the spatialite data view and load the database.
83
OGR
10.3. OGR
5
OGR2OGR can be used to create Spatialite databases supported by
geopaparazzi using different datasources.
6
More info available here
10.4. GDAL
Geopaparazzi does not support reprojecting raster data sources on-the-fly, so the
file must be warped to the proper projection before using it. To do it you can use
7
gdalwarp command.
The target projection must be Google Web Mercator (EPSG code 3857); you must
know also the source projection of the raster you are converting. As an example,
if you have a WGS 84 projected (EPSG code 4326) input file, you will run this
kind of command:
8
To create the tiles you can use gdal2tiles.py script, using as input your
Google Web Mercator projected raster file
gdal2tiles.py output.tif
5
http://www.gdal.org/ogr2ogr.html
6
https://trac.osgeo.org/gdal/changeset/37715
7
http://www.gdal.org/gdalwarp.html
8
http://www.gdal.org/gdal2tiles.html
84
GDAL
It generates directory with TMS tiles, that you can use in Geopaparazzi. In the
root of the this directory you will find "tilemapresource.xml" file which contains all
the information to build the .mapurl file:
Note that the BoundingBox and Origin values created by gdal2tiles are have x
and y values switched against how we need them:
minx="11.28858223249814"
miny="46.39742402665929"
maxx="11.37616698902041"
maxy="46.45081836101696"
x="11.28858223249814"
y="46.39742402665929"
85
86
11
Geopaparazzi & gvSIG
to be done
87
88
12
Using form based notes
Geopaparazzi supports complex notes called form based notes. To use them,
a tags.json file needs to be created and placed inside the geopaparazzi folder
1
inside the sdcard. In that file a json format description of the wanted tags and
forms needs to be placed.
1
http://en.wikipedia.org/wiki/JSON
89
Supported tags (via the example form)
2
A good online tool to at least validate your json form is the Json Lint Validator .
Make sure it passes that test before putting it on the device and test it in
geopaparazzi.
The example form that is available by default shows all the possible options
available.
12.1.1. Text
"formname": "text",
"formitems": [
{
"key": "some text",
"value": "",
"type": "string"
}
]
2
http://www.jsonlint.com/
90
Multiple Text
In simple forms the key element is also used as label for the widget (ex. some
text in the text note). Some charactersets are not suitable to be used as keys for
a database, so in that cases the user should consider to define both the key (ex.
in English) and the label (in the own language). Here an example:
91
Numbers
{
"key": "the_key_used_to_index",
"label": "the label used to describe",
"value": "",
"type": "string"
}
]
12.1.4. Numbers
92
Date
To use one of the values as label in the map view add the islabel tag:
12.1.5. Date
"formname": "date",
"formitems": [
{
93
Time
12.1.6. Time
"formname": "time",
"formitems": [
{
"key": "a time",
"value": "",
"type": "time"
}
]
94
Labels
12.1.7. Labels
"formname": "labels",
"formitems": [
{
"value": "a simple label of size 20",
"size": "20",
"type": "label"
},{
"value": "a underlined label of size 24",
"size": "24",
"type": "labelwithline"
},{
"value": "a label with link to the geopaparazzi homepage",
"url": "http://www.geopaparazzi.eu",
"size": "20",
"type": "labelwithline"
}
]
95
Checkbox
12.1.8. Checkbox
"formname": "boolean",
"formitems": [
{
"key": "a boolean choice",
"value": "",
"type": "boolean"
}
]
96
Combos
12.1.9. Combos
"formname": "combos",
"formitems": [
{
"key": "a single choice combo",
"values": {
"items": [
{"item": ""},
{"item": "choice 1"},
{"item": "choice 2"},
{"item": "choice 3"},
{"item": "choice 4"},
{"item": "choice 5"}
]
},
"value": "",
"type": "stringcombo"
},{
"key": "a multiple choice combo",
"values": {
"items": [
{"item": ""},
97
Combos
98
Pictures
12.1.10. Pictures
"formname": "pictures",
"formitems": [
{
"key": "a picture archive",
"value": "",
"type": "pictures"
}
]
99
Sketches
12.1.11. Sketches
"formname": "sketches",
"formitems": [
{
"key": "a sketches archive",
"value": "",
"type": "sketch"
}
]
100
Map screenshot
"formname": "map",
"formitems": [
{
"key": "an image of the last seen map",
"value": "",
"type": "map"
}
]
12.2.1. hidden
Not shown in the gui, but useful for the application to fill in infos like the GPS
position:
101
primary_key
12.2.2. primary_key
12.2.3. Constraints
Constraints are conditions that are checked when the ok button of the form is
pushed.
mandatory
"mandatory": "yes"
range
To peform a range check on a numeric field you can add something like:
"range":"[0,10)"
which would check that the inserted number is between 0 (inclusive) and 10
(exclusive).
12.3.1. Sections
Every form is composed of sections, each of which create a button in the add
notes view. We want to create a form for a fountain, so one section is enough.
The blueprint for such a form, i.e. the empty button shell starts with:
102
Form subsections
{
"sectionname": "fountain",
"sectiondescription": "fountain",
"forms": [
]
}
]
Each section can contain several sub-forms, that will create a tab each.
{
"formname": "General data",
"formitems": [
]
},
Note that the comma at the end is only needed if more than one sub-form is added.
To add content to the sub-forms, any of the tags described in the supported tags
section can be used.
For example lets add two textfields to prompt the user for a name and street. Also
the name should then be the label rendered in the map view.
{
"key": "name",
"value": "",
103
Finalize the form
"islabel": "true",
"type": "string",
"mandatory": "yes"
},
{
"key": "street",
"value": "",
"type": "string",
"mandatory": "no"
}
This is everything that needs to be done. Let’s also add some technical data in a
dedicated tab and also a tab for media, inside which it is possible to take pictures.
104
13
The Geopaparazzi Database
The Geopaparazzi project database is a plain sqlite database with the extension
.gpap.
1
All data are saved in WGS84 .
_id unique id
lon longitude of the
note
lat latitude of the
note
altim elevation
ts timestamp
description description of the
note
text text of the note
1
http://gisgeography.com/wgs84-world-geodetic-system/
105
Database tables described
_id unique id
lon longitude of the
image
lat latitude of the
image
altim elevation
ts timestamp
azim azimuth
text text of the note
isdirty is dirty field (0 =
false, 1 = true)
note_id an optional note
id, to which it is
bound to
imagedate_id id of the
connected image
data
_id unique id
data the image data
thumbnail the image
thumbnail data
106
Database tables described
_id unique id
lon longitude of the
bookmark
lat latitude of the
bookmark
zoom the zoom of the
bookmark
north the north bound
of the bookmark
south the south bound
of the bookmark
west the west bound of
the bookmark
east the east bound of
the bookmark
text the name of the
bookmark
_id unique id
startts log start
timestamp
endts log end
timestamp
lengthm the length in
meters
isdirty is dirty field (0 =
false, 1 = true)
text name of the log
_id unique id
107
Database tables described
_id unique id
logid id of the log the
properties are
part of
color the color to use to
draw the log
width the width to use
to draw the log
visible flag that defines
if the log is visible
at the time given
108
14
Use case: Use of Geopaparazzi in
Egypt to create a map to improve the
management of small wastewater
treatment plants.
14.1. Introduction
Have you ever tried to type in google: sanitation maps, sanitation coverage,
sanitation or inventory tracking?
When you think of a small village, a rural setting with a few houses and lots of
animals, or a peri-urban area that grew quickly and without any planning or again
neighboring communities linked by a waterway that carries waste from upstream
109
Introduction
to valley, it is not immediat to think that all these places (due to the presence
of man and animal) are a source of biomass. They are a sources of waste and
organic material that often brings a high and invisible pathogenic charge.
The target C of the seventh Millennium Development Goal aimed to halve by 2015
the proportion of people without sustainable access to safe water and basic health
services. The assessment tool implemented in recent years has been the count
of the percentage of population using the health service.
But:
1
http://www.unhcr.org/pages/49c3646cef.html
2
http://www.wssinfo.org/about-the-jmp/introduction/
110
Monitoring activities
It is clear that to get a complete picture of this kind takes time, lots of data
collection, laboratory tests, and then hypothesis, correlations, ideas and
possible strategies.
It is now well known that from a technical standpoint there are no prepackaged
solutions exportable in contexts with very different boundary conditions. Some
causes may seem trivial, but if underestimated they end up affecting the efficiency
of the treatment.
It should be enough to say that there are places in the world where the toilet paper
is not thrown into the toilet; there are places where after defecation you clean up
with your hand; others where even plastic, cloth and diapers are thrown into the
toilet and places in which under the sink there is a shredder and everything ends
up into the sewer system.
These are information that decide the diameter of the pipes even before the type
of treatment and planting. And if the diameter of the tubes is wrong the whole
system becomes meaningless.
How many socio-cultural aspects exist in the various regions of the world that we
do not know, that we can’t even imagine, that can make you smile or frighten,
but that in the construction of a plant have the same weight as the distribution
of BOD5?
There is no doubt that a tool that allows you to collect data of this kind, to catalog
them, and most important geotag them to make them visible on a map and return
the state of the existing as well as facilitates the correlation is crucial in the whole
process of planning and improvement of health services in developing contexts.
During fall of 2010 Geopaparazzi has been used in the monitoring of small waste
water treatment plants in decentralized communities of the Nile Delta, in a
thesis project in Environmental Engineering within a larger project of technical
3
development cooperation (ESRISS project ).
The idea was to be able to do an effective analysis and mapping of the plants in
the area of the Nile Delta to compare different types of treatment and analyze
3
http://www.eawag.ch/forschung/sandec/gruppen/sesp/esriss/index_EN
111
Monitoring activities
To give an idea, information about the available data are shown for some of the
plants:
Figure 14.1. The El Moufty plant, the one with most available information.
112
Technical background
Based on the available data a dedicated form has been designed to collect in a
standardized way as much data as possible.
113
Technical background
Once the form has been loaded into Geopaparazzi, it has been possible to access
it from the add notes view.
The form has been divided into 5 main sections to make it easier to read:
• General data
• Construction info
114
Technical background
• Technical data
• Lab data: this section has been added even if it is quite impossible to gather lab
data in the field. But since the form based notes can be opened and modified
at any time, the section has been added for further update
115
Acknowledgement
• Media
14.4. Acknowledgement
This usecase is a very small and superficial extract of the Geopaparazzi related
part from the master thesis of Vania Zillante: ANALISI DI TECNOLOGIE PER LA
DEPURAZIONE DEI REFLUI DOMESTICI IN COMUNITÀ DECENTRATE DEL
DELTA DEL NILO E PROPOSTA PER IL TRATTAMENTO DELLA FRAZIONE
ORGANICA. APPLICAZIONE DI UN SOFTWARE OPEN SOURCE PER LA
GEOREFERENZIAZIONE DEGLI IMPIANTI ESISTENTI..
116
Acknowledgement
Focus has been put only on the data collection and form creation. It is beyond
the scope of this document to describe or comment any other of the contents of
Vania’s thesis.
Vania’s thesis also won the scolarship prize by ABL Premio Giovanni Lorenzin.
117
118
15
Projects that base on Geopaparazzi
1
https://bitbucket.org/moovida/gasdroide
119
Disaster Management Information System
The same team has also been responsible for the Japanese translation of
Geopaparazzi. Kudos!
15.3.1. TrashMapper
The TrashMapper is a tool used to keep information about the waste management
of a town. Through it it is possible to sample and update information out in the
field and then syncronize the data with a central database/webgis.
120
Trackoid
15.3.2. Trackoid
trackoid mobile
trackoid server
If you are using Geopaparazzi in any flavour we would be happy to list it here with
some screenshot. Just drop us a note!
121
122
16
Appendix
[
{
"sectionname": "fountain",
"sectiondescription": "fountain",
"forms": [
{
"formname": "General data",
"formitems": [
{
"key": "name",
"value": "",
"islabel": "true",
"type": "string",
"mandatory": "yes"
},
{
"key": "street",
"value": "",
"type": "string",
"mandatory": "no"
}
]
},
{
"formname": "Technical data",
"formitems": [
123
The finalized tags.json of the Forms section
{
"key": "protected",
"value": "true",
"type": "boolean",
"mandatory": "no"
},
{
"key": "type",
"values": {
"items": [
{
"item": ""
},
{
"item": "manual"
},
{
"item": "electrical"
},
{
"item": "gravity"
}
]
},
"value": "manual",
"type": "stringcombo",
"mandatory": "no"
},
{
"key": "PH",
"values": {
"items": [
{
"item": ""
},
{
"item": "PH < 5"
},
{
"item": "5 < PH < 7"
},
{
"item": "PH > 7"
}
]
124
The finalized tags.json of the Forms section
},
"value": "PH < 5",
"type": "stringcombo",
"mandatory": "no"
},
{
"key": "number of served people",
"value": "",
"type": "double",
"mandatory": "no"
},
{
"key": "is working",
"value": "true",
"type": "boolean",
"mandatory": "no"
},
{
"key": "needs",
"values": {
"items": [
{
"item": ""
},
{
"item": "nothing"
},
{
"item": "maintainance"
},
{
"item": "rehabilitation"
}
]
},
"value": "nothing",
"type": "stringcombo",
"mandatory": "no"
}
]
},
{
"formname": "Media",
"formitems": [
{
125
Complete tag.json for the Egypt usecase
"key": "Images",
"value": "",
"type": "pictures",
"mandatory": "no"
}
]
}
]
}
]
{
"sectionname": "WWT-plant",
"sectiondescription": "WWT-plant",
"forms": [
{
"formname": "General data",
"formitems": [
{
"key": "Plant name",
"value": "El Moufty Plant",
"islabel": "true",
"type": "string",
"mandatory": "yes"
}
,
{
"key": "Local Responsible Admin",
"value": "Kafr el Sheikh",
"type": "string",
"mandatory": "no"
}
,
{
"key": "District",
"value": "Sidi Salim",
"type": "string",
126
Complete tag.json for the Egypt usecase
"mandatory": "no"
}
,
{
"key": "Village",
"value": "El Moufty",
"type": "string",
"mandatory": "no"
}
]
}
,
{
"formname": "Construction info",
"formitems": [
{
"key": "WWTP technology",
"values": {
"items": [
{"item": ""},
{"item": "Stabilization ponds (GTZ model)"}
]
},
"value": "",
"type": "stringcombo",
"mandatory": "no"
}
,
{
"key": "Designed by",
"value": "Prof M.Abdel Azeem",
"type": "string",
"mandatory": "no"
}
,
{
"key": "Year of construction",
"value": "",
"type": "date",
"mandatory": "no"
}
,
{
127
Complete tag.json for the Egypt usecase
"key": "Startup",
"value": "",
"type": "date",
"mandatory": "no"
}
]
}
,
{
"formname": "Technical data",
"formitems": [
{
"key": "Served population [inhab]",
"value": "3000.0",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Plant capacity [m3/d]",
"value": "450.0",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Surface [m2]",
"value": "6000.0",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Pro capita inflow [m3/inhab d]",
"value": "0.066",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Pro capita water use [l/inhab d]",
"value": "111.0",
"type": "double",
"mandatory": "no"
128
Complete tag.json for the Egypt usecase
}
,
{
"key": "Inflow [m3/d]",
"value": "200.0",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Outflow quality analysis",
"values": {
"items": [
{"item": ""},
{"item": "monthly"},
{"item": "yearly"} ]
},
"value": "",
"type": "stringcombo",
"mandatory": "no"
}
]
}
,
{
"formname": "Lab data",
"formitems": [
{
"key": "PH",
"values": {
"items": [
{"item": ""},
{"item": "PH < 5"},
{"item": "5 < PH < 7"},
{"item": "PH > 7"} ]
},
"value": "PH < 5",
"type": "stringcombo",
"mandatory": "no"
}
,
{
"key": "BOD in [mg/l]",
129
Complete tag.json for the Egypt usecase
"value": "",
"type": "double",
"mandatory": "no"
}
,
{
"key": "BOD out [mg/l]",
"value": "",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Coliforms in [mg/l]",
"value": "",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Coliforms out [mg/l]",
"value": "",
"type": "double",
"mandatory": "no"
}
,
{
"key": "COD in [mg/l]",
"value": "",
"type": "double",
"mandatory": "no"
}
,
{
"key": "COD out [mg/l]",
"value": "",
"type": "double",
"mandatory": "no"
}
,
{
"key": "Suspended solids in [mg/l]",
"value": "",
"type": "double",
"mandatory": "no"
130
Complete tag.json for the Egypt usecase
}
,
{
"key": "Suspended solids out [mg/l]",
"value": "",
"type": "double",
"mandatory": "no"
}
]
}
]
}
]
131
132