LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I read portions of 2D data from multiple subVI's without creating copys

 
I have a large (2K) 1D Array of I16 data that I must be able to read from many subVI's, but I can not be creating copies of this data.
Also the subVI's must be able to run independently in their own while loops.
Is there a way to directly poke and peek my computers ram from LabView?
0 Kudos
Message 1 of 4
(2,251 Views)
Hi crosss,

no, you can't directly peek and poke (I remember some glorious BASIC programs on C64/Atari800 Smiley Very Happy)

How big is your data set? 2K means 2048 elements? Then you would need 4kB of RAM for each copy of your I16 array - that's not much for modern computers...

Some (general) tips:
-There are application notes on memory efficient programming and how to handle big datasets.
-Try to use shift registers and "Replace Aray elements" in your loops.
-In LV8.5 you find a new "In Place" structure to avoid unneccessary data copies.


Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 4
(2,244 Views)

Sorry for the mistake but I ment 2MBytes total not 2K.

Also I can't use shift reg's or replace in place loops if the data is being used in different while loops running at different speeds.

Thanks

0 Kudos
Message 3 of 4
(2,232 Views)
Hi crosss,

can you attach your vi (maybe a simplified version)?

One more tip:
An "action engine" (aka LV2 -style global) may help you. It will hold the big array, works granular (no simultanous read and write), and you can make it accept parts of the big array as input and may provide subarrays as output...
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 4
(2,216 Views)