LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a way to dynamically allocate memory in labview?

In the C programming language, there are malloc() and free() functions which, combined with pointers, allow the user application to dynamically allocate memory.
0 Kudos
Message 1 of 2
(2,782 Views)

LabVIEW does all of its memory management completely automatically, which is almost always an extermely good thing, and you don't have any real way of controlling it. Normally, memory is reused throughout the application and deallocated when the top level VI is closed. You can use the deallocate VI (in the Advanced pallete) to force a deallocation, but this will only help if you finished with the subVI.

The new version 8.0 also includes an option to decide when a subVI will be loaded into memory, which can also help. Normally, real memory problems in LV only occur when you have very large structures because LV needs a contiguous block of memory to hold its data. For most cases, there are various solutions available.

Do you have any specific problems?

To learn more about LabVIEW, I suggest you try searching this site and google for LabVIEW tutorials. Here and here are a couple you can start with. You can also contact your local NI office and join one of their courses.
In addition, I suggest you read the LabVIEW style guide and the LabVIEW user manual (Help>>Search the LabVIEW Bookshelf).


___________________
Try to take over the world!
Message 2 of 2
(2,773 Views)