Measurement Studio for VB6

cancel
Showing results for 
Search instead for 
Did you mean: 

VB6 NI-USB-9237 DAQmxCreateAIVoltageChan selected physical channel does not support the measurement type required

Solved!
Go to solution

I have a VB6 program with code that properly reads analog inputs from an NI-USB-6008.

I tried to re-use the code for a strain-gage module NI-USB-9237, but at the DAQmxCreateAIVoltageChan step I get the following error:

"Measurements: Selected physical channel does not support the measurement type required by the virtual channel you are creating.

Create a channel of a measurement type that is supported by the physical channel, or select a physical channel that supports the measurement type."

Should I be calling a function other than DAQmxCreateAIVoltageChan?

If so, what is it, or where can I find the reference for such functions?

Or - if that is the right function, should I pass different arguments?  Currently I'm calling:

DAQmxErrChk DAQmxCreateAIVoltageChan(taskHandle, "Dev1/ai1", "", DAQmx_Val_Cfg_Default, -10, 10, DAQmx_Val_VoltageUnits1_Volts, "")

 

Thanks in advance for your help

-Chris Hardy

0 Kudos
Message 1 of 2
(8,053 Views)
Solution
Accepted by topic author CHardy

I figured it out from 372251a.PDF

First, the correct function is DAQmxCreateAIVoltageChanWithExcit

Second, you can't just ask for one sample on one channel - ask for 2 samples instead.

-Chris Hardy

0 Kudos
Message 2 of 2
(8,051 Views)