PCI 6023E does not support unipolar ranges. there are only bipolar ranges:
+- 10V
+- 5V
+- 500mV
+- 50 mV
therefore, the parameter "Polarity" set to unipolar leads to the error
InvalidValue. another point is, that AI-Configure only lets
choose you between 20, 10 and 5 for input range. i dont know what
happens if you choose 5, but 20 is +-10V and 10 is +-5V.
Norbert B.
Norbert ---------------------------------------------------------------------------------------------------- CEO: What exactly is stopping us from doing this? Expert: Geometry Marketing Manager: Just ignore it.
There's another thing you should be aware of: the basic input range of the board is +-5V. The +-10V range is achieved by applying a "gain" of 0.5 to the input signal. Your call to the configuration function should specify 10V bipolar range.
To get +-10V range, you must use -1 as the gain argument when you scan or read the analog inputs.
Confusing, eh?
You might want to look into using NI-DAQmx if you can (that is, if you're programming for Windows).
John Weeks
WaveMetrics, Inc. Phone (503) 620-3001 Fax (503) 620-6754 www.wavemetrics.com
DAQmx doesn't do a configuration as such. When you set up a channel for analog input (or output) you tell the driver the expected (or desired) range of your signals, and the driver picks the best device configuration for that range.
If you need to know the gain selected by the driver, or the voltage range, you can query the driver for that information.
DAQmx takes some getting used to- it's quite different from traditional NI-DAQ, but once you get past the learning curve, it's much easier to use.
John Weeks
WaveMetrics, Inc. Phone (503) 620-3001 Fax (503) 620-6754 www.wavemetrics.com