FOX Board LX832 is discontinued
To be informed about its availability and prices please CONTACT US
To know more about the new FOX Board G20GO HERE
Build a virtual instrument Macromedia Flash MX
This article shows how to implement a virtual instrument using Flash MX 2004
and how to interface it with a FOX board LX to measure four different voltage levels
Fig. 1 - Virtual voltmeter
On this figure you can see the virtual voltmeter used in this example in action (you need to have a flash player installed on your browser).
Clicking on the grey buttons it simulates a voltage reading and moves the level indicator.
In this demo, the positions are fixed at 0.5 Volt steps for practical reasons and simplicity but the voltmeter is able to show all the intermediate values.
The indicator movements simulates a real analog voltmeter with realistic acceleration and inertia behavior.
A C program daemon will run on the FOX Board LX to reads the voltage values from an A/D converter and push
them, by a XML protocol on a TCP/IP socket, directly inside the virtual instrument.
To read voltage values on the FOX board LX we'll use an A/D converter chip illustrated in this article: Using the I2C bus.
The C code vmeter.c is a modified version of pcf8591nd.c
that can accepts socket connections from the virtual instrument and push continuously the values in XML format.
The XML format we have chosen to transmit the voltage readings is this:
<analog> indentifies the begin and the end of data transmission from the FOX Board.
<input> contents the values read from each A/D chanel. line is the A/D line id (0 to 3)
and value is the value read in the range 0 (0 Volts) to 255 (3.3 Volts).
Run again /mnt/flash/vmeter on the FOX board LX and press the
button Connect on the Flash synoptic so try to rotate the four trimmers
connected to the A/D converter.
The virual voltmeter will report promptly the voltage
changes measured on each A/D chanel.