niDCPower_Measure
ViStatus niDCPower_Measure (ViSession vi, ViConstString channelName, ViInt32 measurementType, ViReal64 *measurement)
Purpose
Returns the measured value of either the voltage or current on the specified output channel. Each call to this function blocks other function calls until the hardware returns the measurement. The measurement speed of the device and the NIDCPOWER_ATTR_SAMPLES_TO_AVERAGE attribute dictate the length of time that a measurement takes. To measure multiple output channels, use the niDCPower_MeasureMultiple function.
Parameters
Input | ||||||
Name | Type | Description | ||||
vi | ViSession | Identifies a particular instrument session. vi is obtained from the niDCPower_init or niDCPower_InitWithOptions function. | ||||
channelName | ViConstString | Specifies the output channel to measure. Only one channel can be measured at a time with this function. Use the niDCPower_MeasureMultiple function to measure multiple channels. | ||||
measurementType | ViInt32 | Specifies whether a voltage or current value should be measured.
Defined Values:
Default Value: NIDCPOWER_VAL_MEASURE_VOLTAGE |
||||
Output | ||||||
Name | Type | Description | ||||
measurement | ViReal64* | Returns the value of the measurement, either in volts for voltage or amps for current. |
Return Value
Name | Type | Description |
Status | ViStatus | Reports the status of this operation. To obtain a text description of the status code, call the niDCPower_error_message function. To obtain additional information concerning the error condition, call the niDCPower_GetError function. |