10-31-2016 09:32 AM
HI,
I have wriiten a simple VI to output (00, 01, 10 and 11) to a circuit connected with 4 resistors. Based on what value the ciruit recieves, it passes current through one particular resistor. This is again input to Labview and plotted.
The problem is when i send one particular value (i.e one of 00, 10, 01 and 11) and get it back, it is correct. But when I send and recieve them consectively connected through loop counter, they are incorrect (not synchronized with loop number).
I have made sure that circuit is working fine. it has something to do with loop synnchronization, resetting, clearing value etc may be.
Please Guide...
Solved! Go to Solution.
10-31-2016 09:42 AM
Change your DAQ assistant that reads to be 1 sample on demand.
Right now it is set for continuous samples. And 10 samples at 10 Hz. So it runs and starts. Next iteration, you send a new digital out, but have waited 4 seconds. When you read again, you are getting the next 10 samples that are put in the DAQ buffer, but in that time 40 samples have actually entered the DAQ buffer. In time your DAQ buffer will eventually fill up and throw an error. In the meanwhile, you will continually be reading data that is keeps getting more stale by the iteration.
10-31-2016 09:48 AM
10-31-2016 10:19 AM
Hi GerdW,
i have tried to debug the VI and use probs etc. In the VI you attached as well, when i attach one of the four constants (0,1,2,3) with the output to DAW it works fine.(see the VI attached) When i connect the loop number values are again off. Can u suggest what could be the reason?
10-31-2016 10:27 AM
10-31-2016 10:28 AM
Thanks alott...yes this was the problem and I had no idea about it. I needed 10 samples each time so i chose N samples.
Thanks again. Much appreciated!