circuitcellar.com
Magazine Support   Digital Library   Products & Services   Suppliers Directory 
 
 





 

Issue 107 June 1999
A Web-Based Chart Recorder


by Paul Breed

From needing a forklift to fitting in your pocket, chart recorders have undergone some big changes. Paul’s recorder has something even newer-it accesses up-to-the-minute information using an embedded web server.


Start Web Bowser 101Software Functonality Graph-Drawing Code Sources and PDF

Sixteen years ago I was finishing my engineering degree and working part time at JPL. The engineer that I was working with wanted to record a number of temperatures as we tested a newly repaired microwave instrument. I was instructed to go the equipment depot and get an 8-channel strip-chart recorder.
The only available recorder was a 24-channel unit that was 3' wide and 4' tall, and it weighed far more than I could possibly carry. It was delivered to our building with a forklift.
Over the next few weeks, we ran a forest of paper through that machine, which had the maddening habit of clogging the pen just when the signal was getting interesting. Today, we can do the same job with equipment that fits in our pockets.
Recently, I needed to record some temperatures for an engineering project so I created a virtual strip-chart recorder using a Netburner embedded web server and an RS-232 DVM. Although this is overkill for the application, it illustrates the concepts behind dynamic graphics on a web server.
When I set out to do this project, my goals were to:

• create a virtual strip-chart recorder to record temperatures
• enable the user to scroll and zoom on the chart
• enable the user to change the recording parameters
• do all of this using a standard web browser

Most of these requirements were straightforward, but displaying the chart was the hard part. There were two possible solutions. I could either embed a Java applet in an HTML page and have the Java applet scroll and zoom on the chart, or I could have the embedded web server generate embedded images on-the-fly.
Although Java may be up and coming, it’s difficult to save images to disk or to print from an embedded Java applet. I chose to generate embedded images on-the-fly. 

SYSTEM HARDWARE

The data-gathering front end for this project was a Protek 506 DMM that offers a number of measurement capabilities and an almost RS-232 interface. The brains and web server were implemented on a Netburner development board.
I originally thought that I could just plug the two units together and be done with the hardware design. It is never that simple.
The Protek DMM has an RS-232 interface that doesn’t directly generate RS-232 levels. In its normal application attached to a PC, it seems to steal voltage from the PC’s hardware-flow control lines.
Because the Netburner board only implements the RX and TX lines, no such voltage was available. The quick fix of tying +5 V to pins 6 and 7 of the DVM quickly solved this problem [1].
After the hardware shown in Photo 1 was complete, the rest was a simple matter of software. But, before we can discuss the software, let me provide some web background.

(Click here to enlarge)

Photo 1— A Netburner embedded web server and an RS-232 DVM make a fully functional chart recorder.