From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
12-08-2012 10:39 PM
There are many post already on the issue of data exchange between subvi's and main vi but none that I found address my concern when large number (more than 20) of control are in a subvi. The closest I have found is this post:
https://decibel.ni.com/content/docs/DOC-17355. What are recommended ways of data exchange when large number of controls are involved? For my application I need to use many controls.
12-08-2012 10:48 PM
12-10-2012 12:48 AM
Hi aderogba,
Like other friend mentioned, either make bundle or array of similar iterms & pass it, while retrieving use appropriate index to read the values
12-10-2012 01:13 AM
My favorite option is using Functional Global (LV2G) or an Action Engine. Build all the controls into a single cluster and use that in your main vi as well as sub vi.
12-10-2012 10:33 AM
P@Anand wrote:
My favorite option is using Functional Global (LV2G) or an Action Engine. Build all the controls into a single cluster and use that in your main vi as well as sub vi.
Whiel FG or action engines are useful they can be overused. Th eproblem with throwing everything into a single functional global is that all parts of the system will have access to all of the data. While this sounds good it can lead to problems since there is no control or protection of access from specific parts of the system.
12-24-2012 10:14 PM
I like the idea of cluster but instead of using cluster is there a method of contructing action engine/functional global with more than one control?
12-25-2012 02:01 AM
@aderogba wrote:
I like the idea of cluster but instead of using cluster is there a method of contructing action engine/functional global with more than one control?
AEs are data oriented, not control oriented. Please clarify what you have in mind.
12-25-2012 08:50 AM
I am still not completely clear on exactly what you are trying to do.
If you want references to all (or many) of the front panel controls, pass a reference to the front panel of the top level VI to the subVI. In the subVI you can get an array of references to all the controls on the front panel of the main VI. Provided that each control has a unique name, you can determine which reference points to which control by using the Label: Text property.
This can be a powerful technique although property nodes can be slow and may force execution in the UI thread. Often there are better ways to move data around. Can you tell us more about the amount and type of data to be moved?
Lynn
12-30-2012 05:46 PM
What I am looking for is to have a functional global or some other constructs that can manage more than one control. Right now I have some subvi's that needs to share data/control values. What I am doing to meet my need is to save the control values in one subvi to file and read the values in other subvi and vise-versa. I am thinking there should be a better way to manage this type of situation.
12-30-2012 11:56 PM
Its little confusing, you have given to save the control value and the data to be saved to a file. Upto my understanding both are different, data you will get when you run the code but the control value is different which can be loaded/saved at the beggining (Init)/End. Using Functional global is a good method but while doing that you don't need to save it to a file and read it. For the data you need not have a control a terminal/node will provide, so what you need to do here?.. Please clarify