PXI

cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to Use 2 Daqs for 2 separate analog inputs?

I have Labview 7.0, PXI-1042, pxi 6070E, scb-68, windows xp.

I am trying to input 2 analog signals using ai0 and ai1. I am using the external trigger PFI0 for both. I've been unable to trigger/gather both sets of waveforms simultaneously using 2 daqs with 1 analog input each.

I can acquire the data using 1 daq with the two analog inputs.

Why the desire to separate data gathering? Because when I write the data to a .lvm file and access it in excel the analog data for both waveforms are in the same spreadsheet. I wish to have separate data files for the analog inputs.
0 Kudos
Message 1 of 6
(4,136 Views)
It is difficult to know the exact source of the problem since you should be able to trigger both devices simmultaneously. Since you are performing AI on two separate devices, you will need two separate AI "circuits/paths". You will need to call AI config to generate a distinct refnum for each device, and you will need to perform AI Read for each device in your acquire loop (this means you will have two AI Read VIs in your acquire loop). Take a look at the examples for multi-board AI (distributed with LabVIEW) and notice the multiple calls to AI config, AI Start, AI read, AI Clear. You should be able to notice how the "data flow" before, in the acquire loop, and after is sequenced by the error cluster wires (you call AI Read twice - once for each device refnum). Now, th
e same logic applies for writing to two separate files. You simply call File Open twice outside of your loop in order to generate two distinct file refnums. In the acquire loop, wire the output from each AI Read to a different Write VI. At the conclusion of the loop, wire each file refnum to a distinct File Close VI (there will be two). As with the acquire logic, the sequencing is determined by the error cluster wire.
0 Kudos
Message 2 of 6
(4,136 Views)
Thank you for your response. I'm not sure I understand your response. Please allow me to clarify my problem.

I am trying to aquire 2 analog inputs using 1 NI-DAQ system, the PXI-6070E. I am using two separate DAQ assistants to try to acquire 2 different analog signals with the same acquire. I use DAQ assistant1 ai0 for one input and DAQ assistant2 ai1 for the other with PFI0 as the external trigger for both.

I can acquire both anaolog inputs using 1 DAQ assistant; however, I want them separate for data gathering purposes.
0 Kudos
Message 3 of 6
(4,136 Views)
Sorry. I was under the impression that you were using two separate DAQ cards. Since you are just using one device, and that device does not support simultaneous-sample-and-hold, you are limited to acquiring data sequentially (round-robin sampling). The 6070E device has all of the input channels muliplexed through 1 A/D. The only way to acquire two channels of data is with one DAQ call with the read result an array of data for each channel scanned (1-D array for single point multiple channel, 2-D for waveform on multiple channels). If you want to have each waveform stored in a separate file, you will need to use the Index Array function to strip the individual columns from the AI Read VI. Now, using the method I suggested for muliple file I/O, wire ea
ch indexed column to a distinct File Write VI.
0 Kudos
Message 4 of 6
(4,136 Views)
Thanks for the response/suggestion. Will try it in a little bit. I'll let you know how it turns out.
0 Kudos
Message 5 of 6
(4,136 Views)
Avr,

I found the way to do it. I separated the signals by using the split signals functions.
0 Kudos
Message 6 of 6
(4,136 Views)