LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

function varible with data search

This seem quite scary I had a vi which searched a [two dimetional] arry for data. this vi is used as a sub vi within acase statement scructure. the array was wired into the case sturcture in the conventional manner, I wanted to modify the data elsewhere in the project so I considered usung a functional varible the ratherscary Idea came to me of combinig the two as on super fuctial varible. How does this compare with wired data stuctures with shif registers. Will Labview use less memory this way as th edata arry will nothave to ba passed trogu vi calls or will a new copy be madeofthe data each time this vi is called? 

0 Kudos
Message 1 of 4
(2,391 Views)

Before we proceed, have you read the de-facto thread on Action Engines? See Here.

Richard






0 Kudos
Message 2 of 4
(2,378 Views)

This nugget seems to answer part of my question in that my vi is "good labview code" what I was also considering was the relative efficemcy with regadrs to time & memory use beteewn usuing a fucional varible / action emgine approach or passing the array into each stage of the state machine ie case stement within a while loop

0 Kudos
Message 3 of 4
(2,361 Views)

Yes, I think your code looks fine.

I would not sweat the performance issue. However, I think if you can do it with a S/R, you should. The advantage of the Action Engine is that it can be used like a Global, to broadcast data to another VI or another loop.

Richard






0 Kudos
Message 4 of 4
(2,353 Views)