Tips and tutorials for GIS and Remote Sensing…

Tag Archives: OpenLayers

For the visualising data from the SoilSCAPE in-situ network of soil moisture sensors I wanted to use proportional symbols, to provide a visual comparison of the soil moisture from different nodes. The data is received in real time, so I wanted the maps to automatically update and show the current soil moisture. Additionally, as there were three sensors attached to each node I wanted to use three circles, nested within each other, with a different colour for each circle, to show the current moisture for all three sensors, which made it slightly more tricky.

Real time updates – Python

The measurements from the sensors are sent to our lab via SMS and added to a MySQL database. The open layers text file is generated at regular intervals using a Python script to pull data from the database running as a cronjob. This approach is used to create maps of sensor status, with the link to the appropriate colour symbol saved in the open layers file based on the last received measurement. A description is also saved in the file with a link to a plot of measurements (also generated using a Python script running as a cronjob).

Symbols – imagemagick

To create the nested symbols imagemagick is used to create a different symbol for each node, by adjusting the size of three symbols and stacking them together. A Python script is used for this which can be downloaded from SoilSCAPE Utilities on Bitbucket. The script is run using:

More information about the SoilSCAPE project is available on the project website. Data can also be downloaded using the links at the bottom of each map. For more details on the wireless sensor aspect of the project see some of Agnelo Silva’s publications. The project is funded by NASA ESTO.