WANDER: a Portable Linux Data-Collection System
One of the most entertaining aspects of spending an otherwise exhausting decade conjuring a geeked-out, canoe-scale, Linux-based, amphibian pedal/solar/sail trimaran, is that every new twist in the project involves steep learning curves and, in many cases, spin-offs. Usually these manifest themselves as publications and other obvious ways of piping ideas back into the Open Source community that has done so much to make the Microship adventure possible, but occasionally something utterly unexpected falls out of the boat lab.
The WANDER Project certainly fits this category. A couple of years ago, I was contacted by Dave Hughes of the NSF Wireless Field Test Project and enjoined to ``clone'' the Microship core Linux system for use as a ruggedized field data-collection tool. This seemed like an easy and productive technology-transfer project, so I quickly agreed.
Naturally, it was not to be so simple; there was an almost immediate divergence between the boat system design and that of the WANDER box. The former was becoming more and more wrapped around a rich user interface that could migrate transparently among wireless handhelds running VNC clients, with applications ranging far beyond data collection to include active control, security and communications. The latter, meanwhile, was becoming ever more focused on the problem of deploying a flexible database-centric tool into harsh environments, scriptable by moderately technical end users, able to inhale readings from multiple sensor channels, associate them with time and GPS coordinates, and then eventually transmit accumulated data via Globalstar satellite phone. It also would have to be power-efficient enough to allow unattended solar operation, so WANDER took on a life of its own.
We wanted to allow the user (typically a scientist doing environmental field research) to install a variety of sensors and configure the system accordingly--a somewhat nontrivial problem, as we can't very well anticipate every arcane serial protocol or sensor characteristic that might be encountered. A data-collection process launches a collection task for each channel, which in turn stores a time- and location-stamped reading at specified intervals into a database (using Berkeley DB). This process can be started and stopped manually, via a cron job or under control of a separate microcontroller-based, power-control processor that can wake the system at arbitrary intervals. An LCD display on the front panel summarizes activity. All this can take place without the connection of standard peripheral devices, although connectors are included for keyboard, mouse and VGA display to simplify development and maintenance. It is also possible to connect to the unit with an Ethernet cable and gain full access via the LAN.
At any time, the database can be queried by means of a variety of methods, including transmission of accumulated results via FTP over the satellite link, sending same via e-mail or browsing through the unit's internal web server (with tabular or graphic display). The tools are standard, allowing researchers to create new utilities for examining and manipulating the results; the whole front end is implemented with a handful of CGI scripts, and all internals are written in Perl.
Having said all that, we also should note that this is primarily a development system; it is relatively large and heavy, and operates primarily through a browser interface. We envisioned the primary uses as being field application development, feasibility tests for data-collection systems, data concentration from other devices and a test platform for software that is subsequently ported into miniature sealed systems with wireless links to a host. Because it's all built on a standard embedded Linux platform, code developed on WANDER should be portable into tiny, cheap, field-deployable sensor nodes.
We wrapped the system around an industrial-grade 133MHz Octagon PC-500 single-board computer with loads of I/O capability, then packaged it inside a sealed Pelican case along with a battery management system, hard disk, support for external Globalstar satellite phone, internal Garmin-25 GPS with an antenna in the case lid, a simple menu-driven local user interface and an Ethernet port that supports laptops or LAN connection for detailed configuration or software development.
Survival in an outdoor environment defined the overall shape and feel of this box; this called for a gasketed Pelican case and sealed connectors. When the lid is closed, it can handle rain, dirt and high ambient moisture--although we wouldn't recommend total immersion or extended operation in a saltwater environment.
Opening the box reveals a hinged silk-screened panel, carrying a small Matrix Orbital LCD and a 20-button Grayhill keypad, along with mini-DIN connectors for a PC keyboard and mouse, auxiliary serial port, video display, external power input and Ethernet. This panel in turn opens to reveal the internal hardware: the PC-500 card, 4.5GB IBM hard disk drive, a seven amp-hour sealed lead-acid battery, a Calex DC/DC converter that generates five volts and the custom power-management board. The latter is always alive and, in addition to handling battery charging from the external Solarex photovoltaic panel, it can send a brownout signal to the Linux board to allow graceful shutdown and reawaken the board when power returns (with suitable hysteresis to prevent flailing on and off, of course). This ``power control handshaking'' also allows the data system to shut itself down and schedule a return to life at any point in the future--useful for low-bandwidth data collection when power is scarce.
The Octagon PC-500 was chosen for this application because of its substantial suite of I/O hooks with human-scale connectors (compared, say, to a laptop board, which may be tempting for power-efficiency reasons but is a major pain to hack). It is based on a 133MHz 5x86 CPU, with 48MB of EDO RAM, a Flash filesystem, support for M-Systems Disk-On-Chip, APM-flavored power-saving options, floppy and hard disk ports, SCSI-2, Ethernet interface, flat panel and SVGA support, and efficient single-supply operation. The I/O includes five serial ports, a normal PC parallel port plus 24 lines of configurable digital I/O, and the endless variety of third-party options available via the PC/104 interface (this is not currently in use, but will become valuable if WANDER users wish to add analog inputs, signal conditioning, speech synthesis, relay outputs or whatever).
Now, let's take a look under the hood and see what it takes to make WANDER dance.
Webinar: 8 Signs You’re Beyond Cron
On Demand NOW
Join Linux Journal and Pat Cameron, Director of Automation Technology at HelpSystems, as they discuss the eight primary advantages of moving beyond cron job scheduling. In this webinar, you’ll learn about integrating cron with an enterprise scheduler.View Now!
|Non-Linux FOSS: Vienna, Not Just for Sausages||Jun 02, 2015|
|June 2015 Issue of Linux Journal: Networking||Jun 01, 2015|
|June 2015 Video Preview||Jun 01, 2015|
|My Humble Little Game Collection||May 28, 2015|
|New Linux Based OS Brings Internet of Things Closer to Reality||May 27, 2015|
|Non-Linux FOSS: All the Bitcoin, None of the Bloat||May 26, 2015|
- Non-Linux FOSS: Vienna, Not Just for Sausages
- June 2015 Issue of Linux Journal: Networking
- Dr Hjkl on the Command Line
- New Linux Based OS Brings Internet of Things Closer to Reality
- Initializing and Managing Services in Linux: Past, Present and Future
- Using Hiera with Puppet
- My Humble Little Game Collection
- Gartner Dubs DivvyCloud Cool Cloud Management Vendor
- Infinite BusyBox with systemd
- Goodbye, Pi. Hello, C.H.I.P.