LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using property node

If I am using multiple property nodes of a control or indicator, is it recomended to create a reference of thet particular control or indicator and then use property nodes using the created reference OR can I directly use multiple implicit property nodes instead using reference?
 
Also tell me that if I am using a stacked sequence structure, I create a reference in Sequence 0 to modify a property and then pass the same reference to sequence 1 using a sequence local, will it consume more memory then its consumed when implicit property nodes are used.
0 Kudos
Message 1 of 9
(2,838 Views)

Hi Pritam,

i recommend to use a state machine architecture. If you use it, you don´t need all the property nodes, because you can write the value outside the case structure directly into the indicator.

Hope it helps.
Mike

0 Kudos
Message 2 of 9
(2,834 Views)

The answer to the 2nd question is no.

The first i am not sure i understand. Maybe an example would help.

0 Kudos
Message 3 of 9
(2,825 Views)

Question 1: There is little or no difference in using Property Nodes directly or by using a reference.

Question 2: Stay away from Stacked Structures.  They should be removed from the palette!  Do not using this.

Overall:  Change your architecture to a State Machine and use Shift Registers instead of Property Nodes.

R

0 Kudos
Message 4 of 9
(2,802 Views)
There may be a slight gain in using implicit property nodes vs. references and general nodes, because they really pushed implicit nodes at the NI Dev Day.
0 Kudos
Message 5 of 9
(2,781 Views)
Hi Jeff,
 
I agree there is a slight improvement by using an implicit property node.  They are convenient.
 
However, they may not be necessary (or less needed) when using a state machine where the data is wired to the other stated using shift registers as compared to using stacked sequence structures. 
 
R.
 
0 Kudos
Message 6 of 9
(2,775 Views)
Oh, I wholeheartedly agree that the state machine is the way to go here, I was just trying to clarify the perfomance differences for future, legitimate applications.
Message 7 of 9
(2,766 Views)
We should add that using a reference is useful if you are using a sub-vi that affects the properties of controls within the calling vi. 😉
0 Kudos
Message 8 of 9
(2,758 Views)
I think it depends on the number of controls
or indicators in your vi.

If your main panel has less than 10 or 20
controls or indicators then using implicit
property nodes is the safest method.
Used in conjunction with a state machine and
shift registers, will provide the most
reliable code.

If your panel has more than a couple dozen
controls and indicators, then the diagram
can quickly become unwieldy. You can get
around this by bundling them in clusters,
but then you are limited to keeping the
controls and indicators separate.

You can create a separate vi that contains
clusters of references, then in your main vi,
use unbundle and bundle by name to substitute
the actual control reference for the place holder
reference. Then you have one cluster with all
the references. You can unbundle by name and use
as required in your subvis.
The danger in this method is the dreaded RACE
condition.

There are the vi's that generate an array of
references for all the controls and indicators in a panel and I think it's really elegant code.
But they require a string comparison
per use and using bundle and unbundle by name
builds in readability.

just my $.02
😆
0 Kudos
Message 9 of 9
(2,741 Views)