LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Trouble understanding what data type to pick and how to graph these values

In my VI (attached) I am trying to read in some voltage data from an NI DAQ but I don't know exactly what data type to pick, and I think that this is really screwing up my plotting and data calcs later on. Right now I have 6 channels, and I need to separate them as they come in and do different things with that data. I have tried to do so with the split arrays based on advice given to me on here in the past and it sort of works. 4 channels receive the same treatment so I put those in a for loop to try and clean things up a bit was this wrong? I am under the impression that duplicated calculations are a bad idea and a for loop is a better choice.

 

I need the VI to update once a second as smoothly as possible but the data comes in way faster than I process and display it it seems. For example the 4 stacked plots on the right dont update until 300 samples have been taken (or somewhree around there) But the seconds counter I have and the averages at 30 or 1min come up just fine. But the big rate graph isnt showing anythign! Where is the data going? I have a value showing up in the instant box why is tehre none on the graph?

 

0 Kudos
Message 1 of 3
(2,218 Views)

Since you are only reading 1 sample at a time, you should use a 1D Array of Doubles, not an array of waveforms.

 

Your FOR loop isn't necessary since LabVIEW can act on your arrays.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 3
(2,202 Views)

Well arent i reading 6 samples at a time? one from each channel at that time point? I need to separate those out and group 4 of them. I have probably gone about doing so horribly htough.

 

how can i separate out the data from the array so i can average all samples at once a second? before I send that to the graph that is.

0 Kudos
Message 3 of 3
(2,196 Views)