LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Graphing with two acquired data streams.

 Total newbie warning. 

Question: I am using a DAQmx to save information from two load cells and two string pots. The block diagram is currently set up to read, adjust, filter, and save data. I aim to maily speed up my post processing. I want to use the data from the two string pots to create one array and use one load cell to make another array to plot an xy graph. Data is currently saved via an on/off switch. When switched on, the data is sampled at 100hz for a size of 2000 samples, averaged, etc... 

The idea is this, when the switch is flipped to save, I want to create an updating plot with a data point generated from averaging the sample size. How is this done?

 

basically make an updating graph everytime I turn on/off the switch. 

0 Kudos
Message 1 of 4
(3,163 Views)

We can get a much clearer idea of what it is you want to do if you attach your VI (not a picture) or a Zip file containing your entire Project (I hope you using LabVIEW Project ...).

 

Bob Schor

0 Kudos
Message 2 of 4
(3,137 Views)

( ͡° ͜ʖ ͡°) Here is the vi. I did attempt to try something in the mean time, that second smaller loop is new. 

0 Kudos
Message 3 of 4
(3,113 Views)

Hello,

 

I don't believe that your example will work because the second While Loop is dependent on the reference from the Write To Measurement File2 express VI. This means the second while loops will not start until the first while loop is finished which is not really want you want. 

 

The better way to do this, is to use queues with the producer consumer architecture. The queue will let you read data in one loop and transfer it to the queue. The second while loop will then write to the file and display the data if you would like. 

 

I have included some documentation below on the producer consumer architecture that I think would be a good start.

 

Application Design Patterns: Producer/Consumer

http://www.ni.com/white-paper/3023/en/

Matt G.
Product Manager
National Instruments
0 Kudos
Message 4 of 4
(3,074 Views)