06-12-2017 01:13 PM - edited 06-12-2017 01:15 PM
Hi,
I am trying to acquire data at around 50KHz and then output data at the same sampling rate (or lower). I'm using a Producer Consumer design as suggested by others on the forum. Previously, I was getting an issue with DAQmx Write because I did not initialize a buffer for my consumer loop. Now after adding the buffer, the consumer loop doesn't even run/initiate; the consumer loop iteration displays zero. What are some possible explanations for why the consumer loop is not running and how can I fix this?
I have attached the VI. I am using LabView 2015 with the NI USB-6212 BNC.
Thanks
Solved! Go to Solution.
06-12-2017 01:17 PM - edited 06-12-2017 01:20 PM
Hi WCSRI,
What are some possible explanations for why the consumer loop is not running and how can I fix this?
Reason: you didn't implement proper DATAFLOW!
Solution: THINK DATAFLOW! 😄
Better explanation: you tried to reduce local variables by using wires. That's nice! Unfortunately you wired the "samples to read" wire from within the producer loop and then (try to) use this value to initiate the consumer loop. DATAFLOW says: this will only happen AFTER the producer loop has stopped…
(You should have seen this by using highlight execution to debug your VI!)