The University of Queensland Homepage
UQ VisLab UQ VisLab

 Remote Sensor and Instrument Monitoring in the Access Grid
One of the features of the Access Grid which takes it well beyond videoconferencing on steroids is its ability to share applications. The AG's shared application mechanism passes events and data, as required by a particular application, between all the participants in the shared application. This same mechanism can be used to distribute arbitrary data to shared application participants. A common example of this is the VenueVNC; the VenueVNCServer creates a VenueVNC shared application and stores various connection details. When clients join the shared application session, the stored connection details are retrieved and used to launch a vncviewer application.

Image of WTTCI-MIn this example of remote sensor monitoring, the AG's shared application mechanism is used to distribute live sensor data to the shared application participants. The sensor data consists of temperature outputs from four thermocouples attached to a Weeder Technologies WTTCI-M thermocouple input module, which is connected to a computer via its RS-232 port.

The software on the machine hosting the WTTCI-M board consists of two parts:
  • a python module, Weeder.py, to communicate with the WTTCI-M board via the machine's RS-232 port
  • a python program, VenueThermoServer.py, which
    • creates a shared application in an AG venue (nominated as a startup option)
    • periodically retrieves temperature data from the WTTCI-M board and makes the data available to any participant in the shared application session.

VenueClient showing remote THERMO shared application

The temperature data is now accessible by joining the shared application session in the nominated venue. Note that entry to a venue may be restricted (by SSL certificate for AG3), providing a secure means of making the sensor or instrument data available to a restricted audience.

To join the shared application session as a "client", the VenueThermoClient shared application must first be installed. The shared application is then joined by either double-clicking the session's entry in the VenueClient's "Application Sessions" section, or right-clicking on it and selecting "Open" from the resulting drop down menu. The name of the session is set when the VenueThermoServer is started; if no name is given as a startup parameter, the default name "Remote THERMO" will be used.

A few seconds later, all being well, the VenueThermoClient interface should appear.






VenueThermoClient temperature display
The VenueThermoClient interface consists of a display of the temperature data from each of the four thermocouples attached to the Weeder WTTCI-M board. In the instance shown here, the window frame identifies the thermocouple data as being generated at a machine named seivers.vislab.uq.edu.au. The user is able to select a display of the data in either Celsius or Fahrenheit units. In the status bar at the bottom of the window frame, the thermocouple types are shown on the left. On the right of the status bar, the date and time of the last received data is shown.


Of course we are only monitoring trivial data in this project. However the general methodology used here could apply to almost any instrument or sensor data imaginable. Combined with the AG's video and audio streams, we have a powerful platform for remote instrument and sensor monitoring.

Downloads

Please note that the client software (VenueThermoClient) is most likely all you need.

The server software is only useful if you have a Weeder board to physically connect to and "transmit" data from; in this case, you'll also need the pyserial package - either as a package from your distribution's software repository or via the pyserial website. Additionally, a binary pyserial package for Slackware-12.1 is available here.


VenueThermo downloads for AG Toolkit 3.2
VenueThermoClient:

VenueThermoServer source code:

VenueThermoServer binary packages:



Older versions

Releases for older AG versions are archived here
(however it is recommended to upgrade to the latest version).


Installation

The client software is in the form of an Access Grid Shared Application. It is most easily installed from the command line by changing into the directory where the package has been downloaded and then running the command:
    agpm3.py -p VenueThermoClient.agpkg3

Alternatively, using the VenueClient, you could upload the package into the data section of any AG venue. From there, you can right click on it and select the Open item from the drop down menu.

If you have a Weeder board, the VenueThermoServer can be used from the downloadable binary packages above or build from the source code. The simplest way to build and install from the source code it to unpack the source code bundle, go into the resulting archive directory and run:
    python setup.py install

The binary packages are even easier - please use the usual method for your platform.

In addition to the downloads above, packages for some flavours of Debian, Slackware and Ubuntu are available through their respective AccessGrid repositories at UQVislab. The packages currently available in this way are for Debian etch & lenny, Slackware & Slamd64 12.1, Ubuntu hardy & intrepid. If the UQvislab repository is already set up for your system (as it would be for Access Grid toolkit installation), search for and install the venuethermoserver3 package.


Testing

After the VenueThermoClient is installed, as above, it can be tested by pointing your VenueClient to the Asia Pacific Access Grid Lobby at:
    https://vv3.ap-accessgrid.org:8000/Venues/default
There, in the Application Sessions section, you'll find a "THERMO at UQVislab" entry which can be joined by double-clicking on it or right-clicking and selecting Open from the drop down menu. After a few seconds, a client window similar to the example above should appear. Now you can enjoy monitoring the temperature in the UQVislab machine room (and alert us via an email if you happen to see it go ballistic !-)


Issues

Installing the VenueThermoClient directly from the VenueClient didn't work on my Mac - I had to use the command line method. First set up the correct shell environment by running:
    .  /Applications/AccessGrid3.app/Contents/Resources/setupenv.sh
(note the dot). Then I had to change the first line of the file /Applications/AccessGrid3.app/Contents/Resources/bin/agpm3.py to:
    #!/usr/bin/Python
Then I could install the shared app by running:
    agpm3.py -p VenueThermoClient.agpkg3

Acknowledgements

The VenueThermo project was developed at The University of Queensland Vislab, with assistance from the Queensland Cyber Infrastructure Foundation (QCiF) and the Australian Partnership for Advanced Computing (APAC)


Any comments or suggestions to c.willing (at) uq.edu.au