From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Analog Inputs

Hi
 
Right now I have about five analog inputs. For two of them, I am collecting multiple samples so that I can measure the frequencies of the waveforms, so I set up a task to do that. For the other 3, I want just want to sample the signal once every second and periodically get a double from each signal. Right now, this is set up as a separate task.
 
So I have a few questions. They are sort of related.
 
1) Is there a way to combine all these readings into one task? I can't find a way to perform different types of 'Read' for a bunch of analog inputs in the same task.
 
2) If I have to keep the tasks separate, is there a way to synchronize the readings so that I can get readings from all five inputs at the same time. Right now I perform one task, then move on to the next task, and I keep doing that periodically to collect data. I'd like to read everything at the same time if I could.
 
Thanks for the help.
0 Kudos
Message 1 of 3
(2,463 Views)
I forgot to mention that this is for the DAQ-MX functions.
0 Kudos
Message 2 of 3
(2,453 Views)

Hi Stove

Thank you for using our discussion forums.

I am assuming that you are using a single DAQ device.

You can add both of your analog input operations into one task, however you cannot have independent timing, in other words you must sample all your channels at the same rate.  Using this method you should be able to do exactly what you described except that you will need to sample your two slower channels at the same rate as the first three channels and discard the extra samples.  I would recommend this method and it is how you can effectively sample at two rates. 

Your current method of performing your acquisition is ok, however with our DAQ devices you can only have one analog input task running at a time on the same device.  Therefore it is not possible to synchronize your operations unless you are using two devices.  If you are using two device it is possible to synchronize both tasks, however there are more considerations, such as sharing sample clocks and start triggers. 

Chris_K

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