LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to display double type data in waveform graph?

Solved!
Go to solution

Hello,

 

I am new to LabVIEW and now trying to make a VI about data collecting and measuring.

The output data from the previous VI is a double type data and what I want to do is to make a VI that can capture N times of this data and display it in a waveform graph (not a chart). After this, I want to sample the values from the waveform and output them in double type data, just like the data type from the previous VI.

 

Can anyone give me some advice and help?

Thank you very much! 

0 Kudos
Message 1 of 5
(1,110 Views)

How long does it take to collect the data? That determines if you need to see the data as it is generated or if you can wait for all data to arrive and only then display it.

Once you know N, you can use a FOR loop and either auto index at the output tunnel or build it in a shift register. The wire is the data, so just branch it to the graph and to the save tools. No need to "sample" from another indicator, whatever that means.

0 Kudos
Message 2 of 5
(1,105 Views)

The time interval between two data is 100ms and the N I want to use is 1000.

What will be the difference if I use N as 100, 1000 and 10000? Does it slow down the waveform update speed?

0 Kudos
Message 3 of 5
(1,092 Views)
Solution
Accepted by topic author HeavenYin

No, 100ms is a very, very long time for a computer, sufficient to do almost anything. It also means that your recording is many second, so you might want to update the graph as it is acquired. Also 10000 is quite small.

 

From a memory handling standpoint, I would recommend to allocate the final size in a shift register with NaN, then replace with real data as it arrives. After the loop, you can save the data. (NaN will not show on a graph)

 

Here's how that could look like. At the end it saves it as one column.

 

altenbach_0-1667748995434.png

 

(Notice that I am kind enough to show you the full code picture.)

 

0 Kudos
Message 4 of 5
(1,061 Views)

Thank you for your advice and code!

I will try to write a VI myself and go test it.

0 Kudos
Message 5 of 5
(1,049 Views)