|
UL for Linux
User library to access and control supported MCC hardware over the Linux platform
|
Configure the analog input subsystem and acquire data. More...
Functions | |
| UlError | ulAIn (DaqDeviceHandle daqDeviceHandle, int channel, AiInputMode inputMode, Range range, AInFlag flags, double *data) |
| Returns the value read from an A/D channel. More... | |
| UlError | ulAInScan (DaqDeviceHandle daqDeviceHandle, int lowChan, int highChan, AiInputMode inputMode, Range range, int samplesPerChan, double *rate, ScanOption options, AInScanFlag flags, double data[]) |
| Scans a range of A/D channels, and stores the samples in an array. More... | |
| UlError | ulAInScanStatus (DaqDeviceHandle daqDeviceHandle, ScanStatus *status, TransferStatus *xferStatus) |
| Returns the status, count, and index of an A/D scan operation. More... | |
| UlError | ulAInScanStop (DaqDeviceHandle daqDeviceHandle) |
| Stops the analog input operation currently running. More... | |
| UlError | ulAInScanWait (DaqDeviceHandle daqDeviceHandle, WaitType waitType, long long waitParam, double timeout) |
Returns when the scan operation completes on the specified device, or the time specified by the timeout argument elapses. More... | |
| UlError | ulAInLoadQueue (DaqDeviceHandle daqDeviceHandle, AiQueueElement queue[], unsigned int numElements) |
| Loads the A/D queue of a specified device. More... | |
| UlError | ulAInSetTrigger (DaqDeviceHandle daqDeviceHandle, TriggerType type, int trigChan, double level, double variance, unsigned int retriggerSampleCount) |
| Configures the trigger parameters that will be used when ulAInScan() is called with the SO_RETRIGGER or SO_EXTTRIGGER ScanOption. More... | |
| UlError | ulTIn (DaqDeviceHandle daqDeviceHandle, int channel, TempScale scale, TInFlag flags, double *data) |
| Returns a temperature value read from an A/D channel. More... | |
| UlError | ulTInArray (DaqDeviceHandle daqDeviceHandle, int lowChan, int highChan, TempScale scale, TInArrayFlag flags, double data[]) |
| Scans a range of A/D temperature channels, and stores the samples in an array. More... | |
| UlError | ulAIGetInfo (DaqDeviceHandle daqDeviceHandle, AiInfoItem infoItem, unsigned int index, long long *infoValue) |
| Use with AiInfoItem to retrieve information about the AI subsystem. More... | |
| UlError | ulAIGetInfoDbl (DaqDeviceHandle daqDeviceHandle, AiInfoItemDbl infoItem, unsigned int index, double *infoValue) |
| Use with AiInfoItemDbl to retrieve information about the AI subsystem. More... | |
| UlError | ulAISetConfig (DaqDeviceHandle daqDeviceHandle, AiConfigItem configItem, unsigned int index, long long configValue) |
| Use with AiConfigItem to set configuration options at runtime. More... | |
| UlError | ulAIGetConfig (DaqDeviceHandle daqDeviceHandle, AiConfigItem configItem, unsigned int index, long long *configValue) |
| Use with AiConfigItem to retrieve configuration options set for a device. More... | |
| UlError | ulAISetConfigDbl (DaqDeviceHandle daqDeviceHandle, AiConfigItemDbl configItem, unsigned int index, double configValue) |
| Use with AiConfigItemDbl to set configuration options at runtime. More... | |
| UlError | ulAIGetConfigDbl (DaqDeviceHandle daqDeviceHandle, AiConfigItemDbl configItem, unsigned int index, double *configValue) |
| Use with AiConfigItem to retrieve configuration options set for a device. More... | |
| UlError | ulAIGetConfigStr (DaqDeviceHandle daqDeviceHandle, AiConfigItemStr configItem, unsigned int index, char *configStr, unsigned int *maxConfigLen) |
| Use with AiConfigItemStr to retrieve configuration options as a null-terminated string. More... | |
Configure the analog input subsystem and acquire data.
| UlError ulAIGetConfig | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiConfigItem | configItem, | ||
| unsigned int | index, | ||
| long long * | configValue | ||
| ) |
Use with AiConfigItem to retrieve configuration options set for a device.
| daqDeviceHandle | the handle to the DAQ device |
| configItem | the configuration item to retrieve |
| index | either ignored or an index into the configValue |
| configValue | the specified configuration value is returned to this variable |
| UlError ulAIGetConfigDbl | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiConfigItemDbl | configItem, | ||
| unsigned int | index, | ||
| double * | configValue | ||
| ) |
Use with AiConfigItem to retrieve configuration options set for a device.
| daqDeviceHandle | the handle to the DAQ device |
| configItem | the configuration item to retrieve |
| index | either ignored or an index into the configValue |
| configValue | the specified configuration value is returned to this variable |
| UlError ulAIGetConfigStr | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiConfigItemStr | configItem, | ||
| unsigned int | index, | ||
| char * | configStr, | ||
| unsigned int * | maxConfigLen | ||
| ) |
Use with AiConfigItemStr to retrieve configuration options as a null-terminated string.
| daqDeviceHandle | the handle to the DAQ device |
| configItem | the configuration item to retrieve |
| index | either ignored or an index into the configStr |
| configStr | pointer to the buffer where the configuration string is copied |
| maxConfigLen | pointer to the value holding the maximum number of bytes to be read from the device into configStr |
| UlError ulAIGetInfo | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiInfoItem | infoItem, | ||
| unsigned int | index, | ||
| long long * | infoValue | ||
| ) |
Use with AiInfoItem to retrieve information about the AI subsystem.
| daqDeviceHandle | the device the handle to the DAQ device |
| infoItem | the analog input information to retrieve |
| index | either ignored or an index into the infoValue, depending on the value of the infoItem argument. index can also the specify channel mode or channel type for some AiInfoItems (AI_INFO_NUM_CHANS_BY_MODE, AI_INFO_NUM_CHANS_BY_TYPE, and AI_INFO_MAX_QUEUE_LENGTH_BY_MODE) |
| infoValue | the AI information is returned to this variable |
| UlError ulAIGetInfoDbl | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiInfoItemDbl | infoItem, | ||
| unsigned int | index, | ||
| double * | infoValue | ||
| ) |
Use with AiInfoItemDbl to retrieve information about the AI subsystem.
| daqDeviceHandle | the handle to the DAQ device |
| infoItem | the analog input information to retrieve |
| index | either ignored or an index into the infoValue. This argument can also specify the channel mode or channel type for some AiInfoItem values (AI_INFO_NUM_CHANS_BY_MODE, AI_INFO_NUM_CHANS_BY_TYPE, and AI_INFO_MAX_QUEUE_LENGTH_BY_MODE). |
| infoValue | the AI information is returned to this variable |
| UlError ulAIn | ( | DaqDeviceHandle | daqDeviceHandle, |
| int | channel, | ||
| AiInputMode | inputMode, | ||
| Range | range, | ||
| AInFlag | flags, | ||
| double * | data | ||
| ) |
Returns the value read from an A/D channel.
| daqDeviceHandle | the handle to the DAQ device |
| channel | A/D channel number |
| inputMode | A/D channel mode |
| range | A/D range |
| flags | bit mask that specifies whether to scale and/or calibrate the data |
| data | A/D data value |
| UlError ulAInLoadQueue | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiQueueElement | queue[], | ||
| unsigned int | numElements | ||
| ) |
Loads the A/D queue of a specified device.
| daqDeviceHandle | the handle to the DAQ device |
| queue[] | an array of AiQueueElement structs, each of which contains fields specifying channel, range, and mode |
| numElements | the number of elements in the queue |
| UlError ulAInScan | ( | DaqDeviceHandle | daqDeviceHandle, |
| int | lowChan, | ||
| int | highChan, | ||
| AiInputMode | inputMode, | ||
| Range | range, | ||
| int | samplesPerChan, | ||
| double * | rate, | ||
| ScanOption | options, | ||
| AInScanFlag | flags, | ||
| double | data[] | ||
| ) |
Scans a range of A/D channels, and stores the samples in an array.
| daqDeviceHandle | the handle to the DAQ device |
| lowChan | first A/D channel in the scan |
| highChan | last A/D channel in the scan |
| inputMode | A/D channel mode |
| range | A/D range |
| samplesPerChan | the number of A/D samples to collect from each channel in the scan |
| rate | A/D sample rate in samples per channel per second. Upon return, this value is set to the actual sample rate. |
| options | bit mask that specifies A/D scan options |
| flags | bit mask that specifies whether to scale and/or calibrate the data |
| data[] | pointer to the buffer to receive the data array |
| UlError ulAInScanStatus | ( | DaqDeviceHandle | daqDeviceHandle, |
| ScanStatus * | status, | ||
| TransferStatus * | xferStatus | ||
| ) |
Returns the status, count, and index of an A/D scan operation.
| daqDeviceHandle | the handle to the DAQ device |
| status | the status of the background operation (idle or running) |
| xferStatus | a TransferStatus struct containing fields that return the current sample count, scan count, and buffer index for the specified input scan operation |
| UlError ulAInScanStop | ( | DaqDeviceHandle | daqDeviceHandle | ) |
Stops the analog input operation currently running.
| daqDeviceHandle | the handle to the DAQ device |
| UlError ulAInScanWait | ( | DaqDeviceHandle | daqDeviceHandle, |
| WaitType | waitType, | ||
| long long | waitParam, | ||
| double | timeout | ||
| ) |
Returns when the scan operation completes on the specified device, or the time specified by the timeout argument elapses.
| daqDeviceHandle | the handle to the DAQ device |
| waitType | the wait type |
| waitParam | Reserved for future use |
| timeout | the timeout value in seconds (s); set to -1 to wait indefinitely for the scan operation to end. |
| UlError ulAInSetTrigger | ( | DaqDeviceHandle | daqDeviceHandle, |
| TriggerType | type, | ||
| int | trigChan, | ||
| double | level, | ||
| double | variance, | ||
| unsigned int | retriggerSampleCount | ||
| ) |
Configures the trigger parameters that will be used when ulAInScan() is called with the SO_RETRIGGER or SO_EXTTRIGGER ScanOption.
| daqDeviceHandle | the handle to the DAQ device |
| type | type of trigger |
| trigChan | the trigger channel; ignored if type is set to TRIG_POS_EDGE, TRIG_NEG_EDGE, TRIG_HIGH, TRIG_LOW, GATE_HIGH, GATE_LOW, TRIG_RISING, or TRIG_FALLING. |
| level | the level at or around which the trigger event should be detected; ignored if type is set to TRIG_POS_EDGE, TRIG_NEG_EDGE, TRIG_HIGH, TRIG_LOW, GATE_HIGH, GATE_LOW, TRIG_RISING, or TRIG_FALLING. |
| variance | the degree to which the input signal can vary relative to the level parameter; ignored for all types where level is ignored. For pattern triggering, this argument serves as the mask value. |
| retriggerSampleCount | the number of samples per trigger to acquire with each trigger event; ignored unless the SO_RETRIGGER ScanOption is set for the scan. |
| UlError ulAISetConfig | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiConfigItem | configItem, | ||
| unsigned int | index, | ||
| long long | configValue | ||
| ) |
Use with AiConfigItem to set configuration options at runtime.
| daqDeviceHandle | the handle to the DAQ device |
| configItem | the configuration item to set |
| index | either ignored or an index into the configValue |
| configValue | the value to set the specified configuration item to |
| UlError ulAISetConfigDbl | ( | DaqDeviceHandle | daqDeviceHandle, |
| AiConfigItemDbl | configItem, | ||
| unsigned int | index, | ||
| double | configValue | ||
| ) |
Use with AiConfigItemDbl to set configuration options at runtime.
| daqDeviceHandle | the handle to the DAQ device |
| configItem | the configuration item to set |
| index | either ignored or an index into the configValue |
| configValue | the value to set the specified configuration item to |
| UlError ulTIn | ( | DaqDeviceHandle | daqDeviceHandle, |
| int | channel, | ||
| TempScale | scale, | ||
| TInFlag | flags, | ||
| double * | data | ||
| ) |
Returns a temperature value read from an A/D channel.
| daqDeviceHandle | the handle to the DAQ device |
| channel | A/D channel number |
| scale | temperature unit |
| flags | reserved for future use |
| data | temperature value; if an ERR_OPEN_CONNECTION error occurs, the value returned will be -9999. |
| UlError ulTInArray | ( | DaqDeviceHandle | daqDeviceHandle, |
| int | lowChan, | ||
| int | highChan, | ||
| TempScale | scale, | ||
| TInArrayFlag | flags, | ||
| double | data[] | ||
| ) |
Scans a range of A/D temperature channels, and stores the samples in an array.
| daqDeviceHandle | the handle to the DAQ device |
| lowChan | first A/D channel in the scan |
| highChan | last A/D channel in the scan |
| scale | temperature unit |
| flags | reserved for future use |
| data[] | a pointer to an array that stores the data; if an ERR_OPEN_CONNECTION error occurs, the value will be -9999 in the array element associated with the channel causing the error. |
1.8.8