06-03-2015 01:41 PM
Hi all,
I have a VI which uses an event structure within a while loop. One of my events aquires an array of data using a for loop. When I run the event the first time the code responds as i would expect, the for loop runs 10 times and then outputs the expected values. But if I try to run it again, after it has completed the first time, the for-loop seems to have reset its counting and when I click "Calibrate Zeroes" it starts the for-loop at whichever iteration it is currently on. Can anybody help me?
Thanks
06-03-2015 01:54 PM
If you want to maintain a counter over several calls of a loop, use a shift regsiter in the FOR loop as whell as the outermost while loop. Initialize on the outside ith zero an increment inside the FOR loop. (I have not looked at your code).
06-03-2015 01:58 PM
Shouldn't you tell the FPGA when to start sending the data? Otherwise you are probably just getting really old data that is just filling up your DMA FIFOs.
06-03-2015 01:59 PM
OK, looking at your toplevel VI, that's just a general mess: