|
UL for Linux
User library to access and control supported MCC hardware over the Linux platform
|
Configure the digital I/O subsystem and acquire or generate data. More...
Functions | |
| UlError | ulDConfigPort (DaqDeviceHandle daqDeviceHandle, DigitalPortType portType, DigitalDirection direction) |
| Configures a digital port as input or output. More... | |
| UlError | ulDConfigBit (DaqDeviceHandle daqDeviceHandle, DigitalPortType portType, int bitNum, DigitalDirection direction) |
| Configures a digital bit as input or output. More... | |
| UlError | ulDIn (DaqDeviceHandle daqDeviceHandle, DigitalPortType portType, unsigned long long *data) |
| Returns the value read from a digital port. More... | |
| UlError | ulDOut (DaqDeviceHandle daqDeviceHandle, DigitalPortType portType, unsigned long long data) |
| Writes the specified value to a digital output port. More... | |
| UlError | ulDInArray (DaqDeviceHandle daqDeviceHandle, DigitalPortType lowPort, DigitalPortType highPort, unsigned long long data[]) |
| Reads the specified digital ports, and Returns the data in an array. More... | |
| UlError | ulDOutArray (DaqDeviceHandle daqDeviceHandle, DigitalPortType lowPort, DigitalPortType highPort, unsigned long long data[]) |
| Sets the values of the specified digital ports. More... | |
| UlError | ulDBitIn (DaqDeviceHandle daqDeviceHandle, DigitalPortType portType, int bitNum, unsigned int *bitValue) |
| Returns the value of a digital bit. More... | |
| UlError | ulDBitOut (DaqDeviceHandle daqDeviceHandle, DigitalPortType portType, int bitNum, unsigned int bitValue) |
| Writes a value to a digital bit. More... | |
| UlError | ulDInScan (DaqDeviceHandle daqDeviceHandle, DigitalPortType lowPort, DigitalPortType highPort, int samplesPerPort, double *rate, ScanOption options, DInScanFlag flags, unsigned long long data[]) |
| Reads a range of digital ports. More... | |
| UlError | ulDInScanStatus (DaqDeviceHandle daqDeviceHandle, ScanStatus *status, TransferStatus *xferStatus) |
| The status of a digital scan operation. More... | |
| UlError | ulDInScanStop (DaqDeviceHandle daqDeviceHandle) |
| Stops the digital input operation currently running. More... | |
| UlError | ulDInScanWait (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 | ulDInSetTrigger (DaqDeviceHandle daqDeviceHandle, TriggerType type, int trigChan, double level, double variance, unsigned int retriggerSampleCount) |
| Configures the trigger parameters that will be used when ulDInScan() is called with the SO_RETRIGGER or SO_EXTTRIGGER ScanOption. More... | |
| UlError | ulDOutScan (DaqDeviceHandle daqDeviceHandle, DigitalPortType lowPort, DigitalPortType highPort, int samplesPerPort, double *rate, ScanOption options, DOutScanFlag flags, unsigned long long data[]) |
| Writes data to a range of digital ports. More... | |
| UlError | ulDOutScanStatus (DaqDeviceHandle daqDeviceHandle, ScanStatus *status, TransferStatus *xferStatus) |
| Returns the status of the digital output operation. More... | |
| UlError | ulDOutScanStop (DaqDeviceHandle daqDeviceHandle) |
| Stops the digital output operation currently running. More... | |
| UlError | ulDOutScanWait (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 | ulDOutSetTrigger (DaqDeviceHandle daqDeviceHandle, TriggerType type, int trigChan, double level, double variance, unsigned int retriggerSampleCount) |
| Configures the trigger parameters that will be used when ulDOutScan() is called with the SO_RETRIGGER or SO_EXTTRIGGER ScanOption. More... | |
| UlError | ulDClearAlarm (DaqDeviceHandle daqDeviceHandle, DigitalPortType portType, unsigned long long mask) |
| Clears the alarm state for specified bits when alarms are configured to latch. More... | |
| UlError | ulDIOGetInfo (DaqDeviceHandle daqDeviceHandle, DioInfoItem infoItem, unsigned int index, long long *infoValue) |
| Use with DioInfoItem to retrieve information about the DIO subsystem. More... | |
| UlError | ulDIOGetInfoDbl (DaqDeviceHandle daqDeviceHandle, DioInfoItemDbl infoItem, unsigned int index, double *infoValue) |
| Use with DioInfoItemDbl to retrieve information about the DIO subsystem. More... | |
| UlError | ulDIOSetConfig (DaqDeviceHandle daqDeviceHandle, DioConfigItem configItem, unsigned int index, long long configValue) |
| Use with DioConfigItem to retrieve information about the DIO subsystem. More... | |
| UlError | ulDIOGetConfig (DaqDeviceHandle daqDeviceHandle, DioConfigItem configItem, unsigned int index, long long *configValue) |
| Use with DioConfigItem to retrieve the current configuration about the DIO subsystem. More... | |
Configure the digital I/O subsystem and acquire or generate data.
| UlError ulDBitIn | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | portType, | ||
| int | bitNum, | ||
| unsigned int * | bitValue | ||
| ) |
Returns the value of a digital bit.
| daqDeviceHandle | the handle to the DAQ device |
| portType | the digital port containing the bit to be read |
| bitNum | the bit number |
| bitValue | the number of the bit within the port specified by portType |
| UlError ulDBitOut | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | portType, | ||
| int | bitNum, | ||
| unsigned int | bitValue | ||
| ) |
Writes a value to a digital bit.
| daqDeviceHandle | the handle to the DAQ device |
| portType | the digital port containing the bit to be written |
| bitNum | the number of the bit within the port specified by portType to be written |
| bitValue | the bit value to write |
| UlError ulDClearAlarm | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | portType, | ||
| unsigned long long | mask | ||
| ) |
Clears the alarm state for specified bits when alarms are configured to latch.
Once the alarm condition is resolved, this function can be used to clear the latched alarm.
| daqDeviceHandle | the handle to the DAQ device |
| portType | the port containing the bit(s) to clear; the specified port must be configurable for alarm output. |
| mask | bit mask that specifies which bits to clear; set to all 1s to clear all bits in the port. |
| UlError ulDConfigBit | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | portType, | ||
| int | bitNum, | ||
| DigitalDirection | direction | ||
| ) |
Configures a digital bit as input or output.
| daqDeviceHandle | the handle to the DAQ device |
| portType | the digital port containing the bit to configure; the port must be configurable. |
| bitNum | the bit number within the specified port |
| direction | the bit direction (input or output) |
| UlError ulDConfigPort | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | portType, | ||
| DigitalDirection | direction | ||
| ) |
Configures a digital port as input or output.
| daqDeviceHandle | the handle to the DAQ device |
| portType | the digital port; the port must be configurable |
| direction | the port direction (input or output) |
| UlError ulDIn | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | portType, | ||
| unsigned long long * | data | ||
| ) |
Returns the value read from a digital port.
| daqDeviceHandle | the handle to the DAQ device |
| portType | the port type |
| data | the port value |
| UlError ulDInArray | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | lowPort, | ||
| DigitalPortType | highPort, | ||
| unsigned long long | data[] | ||
| ) |
Reads the specified digital ports, and Returns the data in an array.
| daqDeviceHandle | the handle to the DAQ device |
| lowPort | the first port in the scan |
| highPort | the last port in the scan |
| data | input data array |
| UlError ulDInScan | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | lowPort, | ||
| DigitalPortType | highPort, | ||
| int | samplesPerPort, | ||
| double * | rate, | ||
| ScanOption | options, | ||
| DInScanFlag | flags, | ||
| unsigned long long | data[] | ||
| ) |
Reads a range of digital ports.
| daqDeviceHandle | the handle to the DAQ device |
| lowPort | the number of the first port in the scan |
| highPort | the number of the last port in the scan |
| samplesPerPort | the number of samples to read from each port |
| rate | the number of times per second (Hz) to read the port. Upon return, this value is set to the actual scan rate. |
| options | scan options |
| flags | reserved for future use |
| data[] | pointer to an array to receive the digital data |
| UlError ulDInScanStatus | ( | DaqDeviceHandle | daqDeviceHandle, |
| ScanStatus * | status, | ||
| TransferStatus * | xferStatus | ||
| ) |
The status of a digital scan operation.
| daqDeviceHandle | the handle to the DAQ device |
| status | the status of the background operation |
| xferStatus | a TransferStatus struct containing fields that return the current sample count, scan count, and buffer index for the specified input scan operation |
| UlError ulDInScanStop | ( | DaqDeviceHandle | daqDeviceHandle | ) |
Stops the digital input operation currently running.
| daqDeviceHandle | the handle to the DAQ device |
| UlError ulDInScanWait | ( | 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 ulDInSetTrigger | ( | DaqDeviceHandle | daqDeviceHandle, |
| TriggerType | type, | ||
| int | trigChan, | ||
| double | level, | ||
| double | variance, | ||
| unsigned int | retriggerSampleCount | ||
| ) |
Configures the trigger parameters that will be used when ulDInScan() is called with the SO_RETRIGGER or SO_EXTTRIGGER ScanOption.
| daqDeviceHandle | the handle to the DAQ device |
| type | the trigger type |
| 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 to acquire with each trigger event; ignored unless the SO_RETRIGGER ScanOption is set for the scan. |
| UlError ulDIOGetConfig | ( | DaqDeviceHandle | daqDeviceHandle, |
| DioConfigItem | configItem, | ||
| unsigned int | index, | ||
| long long * | configValue | ||
| ) |
Use with DioConfigItem to retrieve the current configuration about the DIO subsystem.
| daqDeviceHandle | the handle to the DAQ device |
| configItem | the configuration item to retrieve |
| index | the port index |
| configValue | the specified configuration value is returned to this variable |
| UlError ulDIOGetInfo | ( | DaqDeviceHandle | daqDeviceHandle, |
| DioInfoItem | infoItem, | ||
| unsigned int | index, | ||
| long long * | infoValue | ||
| ) |
Use with DioInfoItem to retrieve information about the DIO subsystem.
| daqDeviceHandle | the handle to the DAQ device |
| infoItem | the digital I/O information to retrieve |
| index | an index into the infoValue, depending on the value of the infoItem argument; usually specifies port direction (DD_INPUT or DD_OUTPUT); ignored when infoItem is set to DIO_INFO_NUM_PORTS and DIO_INFO_HAS_PACER |
| infoValue | the DIO information is returned to this variable |
| UlError ulDIOGetInfoDbl | ( | DaqDeviceHandle | daqDeviceHandle, |
| DioInfoItemDbl | infoItem, | ||
| unsigned int | index, | ||
| double * | infoValue | ||
| ) |
Use with DioInfoItemDbl to retrieve information about the DIO subsystem.
| daqDeviceHandle | the handle to the DAQ device |
| infoItem | the digital I/O information to retrieve |
| index | the port direction (DD_INPUT or DD_OUTPUT) |
| infoValue | the DIO information is returned to this variable |
| UlError ulDIOSetConfig | ( | DaqDeviceHandle | daqDeviceHandle, |
| DioConfigItem | configItem, | ||
| unsigned int | index, | ||
| long long | configValue | ||
| ) |
Use with DioConfigItem to retrieve information about the DIO subsystem.
| daqDeviceHandle | the handle to the DAQ device |
| configItem | the configuration item to retrieve |
| index | the port index |
| configValue | the value to set the specified configuration item to |
| UlError ulDOut | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | portType, | ||
| unsigned long long | data | ||
| ) |
Writes the specified value to a digital output port.
| daqDeviceHandle | the handle to the DAQ device |
| portType | the digital port type |
| data | the port value |
| UlError ulDOutArray | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | lowPort, | ||
| DigitalPortType | highPort, | ||
| unsigned long long | data[] | ||
| ) |
Sets the values of the specified digital ports.
| daqDeviceHandle | the handle to the DAQ device |
| lowPort | the first port in the scan |
| highPort | the last port in the scan |
| data | output data array |
| UlError ulDOutScan | ( | DaqDeviceHandle | daqDeviceHandle, |
| DigitalPortType | lowPort, | ||
| DigitalPortType | highPort, | ||
| int | samplesPerPort, | ||
| double * | rate, | ||
| ScanOption | options, | ||
| DOutScanFlag | flags, | ||
| unsigned long long | data[] | ||
| ) |
Writes data to a range of digital ports.
| daqDeviceHandle | the handle to the DAQ device |
| lowPort | number of the first port in the scan |
| highPort | number of the last port in the scan |
| samplesPerPort | the number of samples per port to write |
| rate | the number of times per second to write to each port (scan rate). Upon return, this value is set to the actual scan rate. |
| options | scan options |
| flags | reserved for future use |
| data[] | a pointer to an array to receive the digital data |
| UlError ulDOutScanStatus | ( | DaqDeviceHandle | daqDeviceHandle, |
| ScanStatus * | status, | ||
| TransferStatus * | xferStatus | ||
| ) |
Returns the status of the digital output operation.
| daqDeviceHandle | the handle to the DAQ device |
| status | the status of the background operation |
| xferStatus | a TransferStatus struct containing fields that return the current sample count, scan count, and buffer index for the specified output scan operation |
| UlError ulDOutScanStop | ( | DaqDeviceHandle | daqDeviceHandle | ) |
Stops the digital output operation currently running.
| daqDeviceHandle | the handle to the DAQ device |
| UlError ulDOutScanWait | ( | 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 ulDOutSetTrigger | ( | DaqDeviceHandle | daqDeviceHandle, |
| TriggerType | type, | ||
| int | trigChan, | ||
| double | level, | ||
| double | variance, | ||
| unsigned int | retriggerSampleCount | ||
| ) |
Configures the trigger parameters that will be used when ulDOutScan() is called with the SO_RETRIGGER or SO_EXTTRIGGER ScanOption.
| daqDeviceHandle | the handle to the DAQ device |
| type | the trigger type |
| 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. |
1.8.8