LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

common variables between user interface script and vi's

Hi all,

We're planning on developing a system bench.  The idea is to use Labview vi's for reading from/writing to the hardware, and to use a scripting language (TDB) for the user interface.  To pass data between them, we'd like to use common variables, i.e.  script <-> common variables <-> vi's.  These common variables would likely be stored in another file.  Is it possible and how? 

For example:  we have variables called voltage_a and voltage_b. Also, we have a vi that uses voltage_a as input and produces voltage_b as output.
So, when we specify in the script something like:  set voltage_a  = 5, we can then, at a later time, read variable voltage_b to determine the result.  Is this possible?

Thanks,
-Ep




0 Kudos
Message 1 of 3
(2,726 Views)
Out of curiosity, why not build the user interface in Labview considering this is one of its strengths?
 
To answer your question (and there are many ways to answer this question) yes it is possible. You could simply write variables to data files (text files if you wish) and read these files using Labview. You could create some kind of database and have Labview query it to load variables. You could also skip the intermediate file and sent data between the programs using UDP or TCP protocols directly.
0 Kudos
Message 2 of 3
(2,725 Views)
Thanks, Grayham.
The user interface is still TDB.  I'm new to labview, so I don't know what labview can or cannot do.  Is it possible to write a script like I mentioned in my earlier posting in labview?
Can you point me to examples/tutorials on this, i.e. script/user_interface <-> data file <-> labview?

Regards,
-Ep
0 Kudos
Message 3 of 3
(2,713 Views)