Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

How do you programmatically define differential thermocouple channels?

Solved!
Go to solution

I am trying to understand how a differential physical "channel" (really channel pair) gets created from a virtual channel. Specifically, I'm trying to acquire from a thermocouple (K) using a differential connection.

 

In AIChannels.CreateAccelerometerChannel, for example, you can specify if you want to create a differential channel or not. In the NI-DAQmx Help file, I see that for M series (what I have), the differential negative physical channel number is 8+ the positive number. And it says to "pass only the name of the positive channel" to the function creating the differential [virtual] channel.

 

In AIChannels.CreateThermocoupleChannel there is no such option to specify differential, single ended, etc. So is it impossible to use CreateThermocoupleChannel and connect the thermocouple for differential mode? In other words, do I have to create a voltage channel and then make the conversion to temperature myself?

0 Kudos
Message 1 of 3
(4,302 Views)
Solution
Accepted by topic author pelesl

Hi pelesl,

 

Most of the parameters to the DAQmx channel creation methods are used to set properties on the newly created channels. You can also get or set the same properties yourself. The terminal configuration parameter in the voltage channel creation method corresponds to the TerminalConfiguration property, so you should be able to do something like this:

 

AIChannel chan = task.AIChannels.CreateThermocoupleChannel(...);

chan.TerminalConfiguration = AITerminalConfiguration.Differential;

 

Brad

---
Brad Keryan
NI R&D
Message 2 of 3
(4,295 Views)

Thanks.

0 Kudos
Message 3 of 3
(4,283 Views)