Is it better to use Invoke nodes or property nodes to set/get control values?

I have a series of VI's that run in parallel, each to manage different
functions- pumping, sensing, a fluid flow model, an experiment
These need to exchange data, which I am currently doing using invoke
nodes (that are all in subVIs), using methods "Set control value" and
"Get control value". I find that every now and then (perhaps 1% of the
time) the data isn't exchanged correctly and therefore the system
doesn't work. I can imagine how "set" could go wrong if they happen
simultaneously, and can devise ways of preventing this. However, the
"Get" method suffers from the same problem. This is a major problem,
because I want to leave it running for several hours.
I could in principle achieve the same thing using property nodes and
find myself wondering if this might be more reliable. But I don't want
to change over only to find it makes no difference!
Can anyone advise?
x9561 (148462)
11/24/2003 11:08:49 AM
comp.lang.labview 35204 articles. 1 followers. vasusachin24 (1) is leader. Post Follow

4 Replies

Similar Articles

[PageSpeed] 11

Use functional globals, notifiers or ques.

Try to avoid setting values using property nodes (even locals are
better in most cases). If you ever want to build an application of
your code the set control value method is not supported(!), so go for
functional globals or something that is.
x9561 (148462)
11/24/2003 11:34:52 AM
You can use some kind of syncronization such as queues, occurances, or
notifiers but I think the easiest way would be to create and action
engine.  This was only one action can execute at a time avoiding a
"race condition".  Possibly a write action and a read action might
help.  You also can add queues or notifiers into this concept.  hope
this helps.
x9561 (148462)
11/24/2003 1:56:27 PM
Hi Mads,

the help of LV 6.1 states Get/Set Control Value is available in
runtime. If it really does not work is the help wrong or is it a bug?

x9561 (148462)
11/24/2003 2:43:34 PM
Heey, you are right! I'm outdated:-)

It did not use to be, but I just tested it in LV7 and it works fine.

If it sometimes fail though, as described here...functional globals,
notifiers etc. may still be a better solution.
x9561 (148462)
11/24/2003 3:31:44 PM