09-03-2007 01:31 PM
09-03-2007 01:42 PM
09-03-2007 01:58 PM
09-03-2007 02:01 PM
We would probably need more information. Can you post your code or show us a diagram image with "show buffer allocation" enabled?
What is your LabVIEW version?
09-03-2007 02:07 PM - edited 09-03-2007 02:07 PM
Message Edited by JWJ on 09-03-2007 02:11 PM
Message Edited by JWJ on 09-03-2007 02:12 PM
09-03-2007 02:13 PM
@JWJ wrote:
Since my original file is more than 2M and really comlicated, I just make a simple demo file to show my purpose.
Your current code is way too confusing, so I assume that the full code makes more sense. The program is unusable because the main FOR loop gets locked in an inner loop that consumes all CPU doing nothing.
I think that branching the main array into the (1) case structure and (2) inner while loop costs you an extra allocation. Here's a more reasonable way to do things. It elimiates the buffer allocation going into the case structure.
09-03-2007 02:15 PM
do you refer to the fact that the first time you run your AE, then at initiation - read of array AND at shift register the memory is allocated? in this case, the first time you run it the shift register is empty, therefore memory allocation there is minimal.
if you refer to the second (and next..) time of running the case structure, you then have twice memory allocations, i have read that LV became (even more) efficient in that, and doesnt actually allocate memory to the false (not used ) case. maybe Altenbach can confirm that?
09-03-2007 02:17 PM - edited 09-03-2007 02:17 PM
Message Edited by JWJ on 09-03-2007 02:18 PM
09-03-2007 02:25 PM
09-03-2007 02:32 PM
Oh wow! Do we need a pilots license to operate that VI? 😄
Sorry, my monitor is not big enough to successfully find my way around on that diagram. Can you pinpoint the approximate location of the problem code?