LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
Luke H

Waveform Autoindexing Output Tunnel

Status: Declined

Any idea that has received less than 4 kudos within 4 years after posting will be automatically declined.

The Problem


Doing a long finite acquisition in DAQmx results in the manner shown below results in a all the data from the acquistion residing in a 2D array of waveforms that the user must rearrange to begin working with.  Since a 2D array of waveforms is not really useful with any processing functions in LabVIEW, why not come up with an automatic way to get the datatype you want (a 1D array of waveforms with the new samples appended to the Y array of the appropriate channel.)

regular tunnel.png


2Dwaveform.png

 

The Solution


Give the user the ability to create a "waveform autoindexing tunnel" via a context menu option.  This tunnel would automatically output the appended waveforms, 1 per channel.  This could be done behind the scenes in the most memory efficient way possible so as to save users the headache of trying to modify the 2D array they currently get.

waveformTunnel.png

 

1Dwaveform.png

 

 

Zoomed in Images


regularZoomed'.png

 

 

waveformZoomed.png

 


3 Comments
GregR
Active Participant

What if the waveforms aren't contiguous or have a different time basis? For this to work (t0 + dt * number of samples) must equal (t0 for the next waveform) for each and every waveform, plus dt must be the same in all. If this is ever not true, then the waveforms cannot be combined. In your specific example this should always be the case, but as a general feature this has problems.

 

If you are going to combine all the data into a single waveform anyway, why would you acquire it in pieces. Just do one big read and avoid the issue. I'm assuming the answer is this is a simplified example where you would normally also be doing something with each buffer as it is acquired. Just thought I'd mention it.

 

I am a proponent of this capability for arrays and strings but I don't think it is appropriate for waveforms because of the time issue. As long as changing your acquisition to use an array instead of a waveform is acceptable, I would be in favor.

Luke H
NI Employee (retired)

Hadn't thought about the fact that sometimes the dt's and t0's wouldn't match up.  You're right though, it may make more sense for arrays and strings.  Maybe call it an "append tunnel" or something.

 

You're also correct in that I might be doing something else with it in the loop.  The simplest example is a 1 minute finite acquisition where you'd like to see real time data once a second.  You have to split up the acquisition into multiple reads, but you'd also like to have the entire minute long waveform in the most memory efficient manner as possible.

 

Take a look at this vi to see what we're currently doing. (It works pretty well, it's just a lot of code for a simple task)

 

DAQmx Waveform Finite Acquisition Memory Efficient.vi

Darren
Proven Zealot
Status changed to: Declined

Any idea that has received less than 4 kudos within 4 years after posting will be automatically declined.