Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Can the USB-6008 process an analog input and output task simulataneously?

Hello,

 

My goal is to have LabView 2013 generate a voltage output from a DAQ USB 6008's analog output channel ao1 while reading in a voltage input from the device's ai0. This is to simultaneously read in a pressure measurement and externally trigger a camera to snap a frame. Separately, the code for reading in the ai0 input and writing it to a measurement file is able to produce a text file with pressures recorded at the specified log time. The code that generates the voltage output from ao1 sends out the right voltages regardless of whether it is run as isolated code or with the analog input code.

 

Currently, the problem is that the measurement file (from Write to Measurement File.VI) seems to record the ai0 input at shorter intervals than specified. I do not have this problem when the analog trigger part of the code is absent. When I specify the Time to Log as 10 sec/logged measurement, the output text file shows not 10 seconds but a shorter time spacing of 7 seconds b/t measurements. How do I fix this? Is the USB 6008 appropriate for running two simulatenous analog tasks?

 

My code is included below, with a snapshot. Any advice is appreciated. Thanks!

Download All
0 Kudos
Message 1 of 5
(4,686 Views)

That device cannot do multiple I/O at once. 


The 600x line is low-cost data acquisition.  With performance, comes cost.

 

You can get a 2nd 600x, while you're still limited to software-timed I/O at least you can sample simultaneously with that.

 

Or step up to a better DAQ.  621x might do what you need; any of the X-series DAQs can do that for sure.

0 Kudos
Message 2 of 5
(4,645 Views)

That's not true, you can run analog input and analog output at the same time on the 6008.  The analog output is always software-timed but it can be run alongside a hardware-timed analog input task.  You cannot synchronize the analog output to the analog input however, since the 6008 only has software-timed analog output.

 

 

Best Regards,

John Passiak
Message 3 of 5
(4,637 Views)

With a simulated 6008, I don't see any problems. The DAQmx Read is in continuous mode and the DAQmx Write is in on-demand sampling so I don't quite see why it should not work. Attach the file where you think the timestamps are wrong.

 

p.s. I ran the VI at 1000S/s and 100 samples.

0 Kudos
Message 4 of 5
(4,636 Views)

Hi all,

 

Thanks for the suggestions. Our strategy was actually a little different. We switched out the DAQ assistant for a few low-level DAQmx VIs (AO Voltage, Analog DBL 1Chan1Samp, to name a few). We consolidated the two case structures so that the camera trigger (analog output) and voltage measurements (analog input) were in one case structure. The DAQ assistant seems to be pretty sophisticated and contains more bells+whistles that we didn't need for this experiment. With the low-level DAQmx VIs we were able to read an analog in voltage and send an analog out voltage.

 

 

0 Kudos
Message 5 of 5
(4,592 Views)