Measurement Studio for .NET Languages

Showing results for 
Search instead for 
Did you mean: 

How to set the MinimumValue and MaximumValue properties when creating an AIChannel?

I am trying to create a voltage channel on an analog input channel for a task. In this case I'm using the CreateVoltageChannelWithExcitation function. There are required properties "MinimumValue" and "MaximumValue". The documentation does not really provide any information at all on these.


What is the purpose/ function of these properties? Why are they required, and how does the task behave differently depending on what these values are set to? To me it seems like the units scale factor and the excitation voltage for the sensor should be all that is needed to configure; I don't really understand what these do.


Anyways, I have set the value of these inputs according to the expected range of output values (in scaled units). When I attempt to verify the task, I consistently receive the error Status Code: 200077 "Requested value is not a supported value for this property. The property value may be invalid because it conflicts with another property". The error also provides the range of allowed values for the 'maximum value' property, which is many orders of magnitude to small. The actual range, in scaled units, should be on the order of 0-300 N. The range of acceptable values given by the error is >489E-6 and <489E-6.


If I do actually set the value of this property to be within this range the task is verified and my task will run. However, it just returns values of zero, no matter what the actual output of the sensor is (and input strain to the sensor).


I have created and assigned an appropriate Scale. I have tried using both a LinearScale and a TableScale, but I run into the same problems when using both of these options.


I have tested and verified that the setup works using the DAQExpress application. The scaled output appears to be correct when a task is run in that application. But the channel and task setup properties in the DAQExpress have no equivalent field to the minimumValue and maximumValue inputs in the DAQmx channel function.

0 Kudos
Message 1 of 1