LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Measure voltage and temperature from one daq card

Solved!
Go to solution

Hi,

I am using a 9211 DAQ card on USB 9162 to measure the heat flux.

A heat flux gauge outputs voltage for heat flux and temperature (Type T) at the same time.

So it has 4 wires (2 for heat flux and 2 for temperature) and I connect 2 wires to channel 2 and the other 2 wires to channel 3.

The labview code measured the temperature and voltage but not at the same time.

When the temperature is recorded, the voltage becomes 0 and vice versa. (Err 50103)

Is it not possible to measure temperature and voltage from a single DAQ card?

Thank you.

0 Kudos
Message 1 of 5
(1,646 Views)

Hi Jim,

 

put both channels into just one DAQmx task to read them both at the "same" time…

 

I hope you are using plain DAQmx functions and not that dreaded DAQAssistent ExpressVI, do you?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 5
(1,631 Views)

Hi GerdW,

 

Thank you for the reply.

I attached my code.

The channel2 is thermocouple of heat flux gage and the channel3 is voltage from the heat flux gage.

I found no mistake in the code.

Could you let me know what is the problem?

Thank you.

 

 

 

 

 

0 Kudos
Message 3 of 5
(1,619 Views)
Solution
Accepted by topic author JimK247

Hi Jim,

 


@JimK247 wrote:

I found no mistake in the code.

Could you let me know what is the problem?


You found no problem, even though I wrote the possible solution in my previous post:

Place both channels into one DAQmx task!

 

Most DAQ devices use only one ADC for several input channels and you cannot share this single ADC between several (DAQmx) tasks. You need to read all channels within one DAQmx task…

 

Like this:

Why did you use the "N channels" when your tasks only contained one channel each?

Why do you fiddle with "wait time" when you could use DAQmxTiming instead?

Why was there a coercion dot at WaitTime?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 5
(1,591 Views)

Hi GerdW,

 

I just couldn't understand your instruction at first.

But now I fully understand and modified the code.

The code can read and output all data properly.

Thank you for the advice!

0 Kudos
Message 5 of 5
(1,576 Views)