LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Continuous graphing of two (or more) signals from the same DAQ

Solved!
Go to solution

Hello,

 

I am very new to Labview (building my first VI) and I could use some help.

 

I am using a PCIe-6321 receiving two analog voltages from a BNC 2090. I have used DAQ assistant to generate continuous waveform charts from each channel and placed them inside while loops.

 

When I run the VI, only one or the other loop runs, seemingly selected at random. I am interested in both why this is happening and, more pressing, how to get both charts to display the waveform concurrently. 

 

Later I will be trying to add more signals in the same way and log the data, but just getting them to work at the same time would be a great start.

 

Thanks

0 Kudos
Message 1 of 3
(2,221 Views)
Solution
Accepted by topic author Dsellers

You cannot create multiple tasks tasks for the same DAQ card and run them at the same time. You have to create a single task using Dev1/ai0:1, and then you will collect the data for all channels in a single place. Both loops are running, but the one which creates the task first wins, and the other one has an error and stops running after a single iteration.

 

I would look through some of DAQ examples and learn how to use the DAQmx API. It's not too challenging, and it will make processing data much easier when you get rid of the dynamic data and use the standard waveform data.

 

Edit: here is a good intro: https://www.ni.com/en/support/documentation/supplemental/06/learn-10-functions-in-ni-daqmx-and-handl...

Message 2 of 3
(2,197 Views)

After looking through this documentation on NI-DAQmx I definitely believe that it's worth investigating, but actually a bit beyond my present labview-competency

 

The solution to my problem was your first suggestion; I added both channels to the same DAQ assistant and then used the split signals function to create two graphs. I now know how to do tdms logging so I'm well on the way to getting all of my pressure readings assembled and recorded in the same VI

 

Thanks a lot!

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