### Build and Install uldaq Library Source: https://github.com/mccdaq/uldaq/blob/master/README.md Configures, builds, and installs the uldaq library on the system. ```bash $ cd libuldaq-1.2.1 $ ./configure && make $ sudo make install ``` -------------------------------- ### Execute Analog Input Example Source: https://github.com/mccdaq/uldaq/blob/master/README.md Navigates to the examples directory and executes the AIn example program. ```bash $ cd examples $ ./AIn ``` -------------------------------- ### Install GCC, Make, and LibUSB on OpenSUSE Source: https://github.com/mccdaq/uldaq/blob/master/README.md Installs necessary build tools and the libusb development package on OpenSUSE. ```bash $ sudo zypper install gcc gcc-c++ make $ sudo zypper install libusb-devel ``` -------------------------------- ### Install GCC, Make, and LibUSB on Debian Source: https://github.com/mccdaq/uldaq/blob/master/README.md Installs necessary build tools and the libusb development package on Debian-based Linux distributions. ```bash $ sudo apt-get install gcc g++ make $ sudo apt-get install libusb-1.0-0-dev ``` -------------------------------- ### C Example: Analog Input Source: https://github.com/mccdaq/uldaq/blob/master/README.md A basic C example demonstrating analog input using the Universal Library for Linux. It retrieves device inventory, connects to a DAQ device, and reads data from the first four analog input channels. ```c #include #include "uldaq.h" #define MAX_DEV_COUNT 100 #define MAX_STR_LENGTH 64 int main(void) { unsigned int numDevs = MAX_DEV_COUNT; DaqDeviceDescriptor devDescriptors[MAX_DEV_COUNT]; DaqDeviceHandle handle = 0; int chan = 0; double data = 0; UlError err = ERR_NO_ERROR; // Get descriptors for all of the available DAQ devices ulGetDaqDeviceInventory(ANY_IFC, devDescriptors, &numDevs); // verify at least one DAQ device is detected if (numDevs) { // get a handle to the DAQ device associated with the first descriptor handle = ulCreateDaqDevice(devDescriptors[0]); // check if the DAQ device handle is valid if (handle) { // establish a connection to the DAQ device err = ulConnectDaqDevice(handle); // read data for the first 4 analog input channels for (chan = 0; chan <= 3; chan++) { err = ulAIn(handle, chan, AI_SINGLE_ENDED, BIP5VOLTS, AIN_FF_DEFAULT, &data); printf("Channel(%d) Data: %%10.6f\n", chan, data); } ulDisconnectDaqDevice(handle); ulReleaseDaqDevice(handle); } } return 0; } ``` -------------------------------- ### Install GCC, Make, and LibUSB on Arch Source: https://github.com/mccdaq/uldaq/blob/master/README.md Installs necessary build tools and the libusb development package on Arch-based Linux distributions. ```bash $ sudo pacman -S gcc make $ sudo pacman -S libusb ``` -------------------------------- ### Build Doxygen API Documentation Source: https://github.com/mccdaq/uldaq/blob/master/README.md Commands to build the API documentation using Doxygen if it is installed. ```bash $ cd doc $ doxygen Doxyfile ``` -------------------------------- ### Install GCC, Make, and LibUSB on Red Hat Source: https://github.com/mccdaq/uldaq/blob/master/README.md Installs necessary build tools and the libusb development package on Red Hat-based Linux distributions. ```bash $ sudo yum install gcc gcc-c++ make $ sudo yum install libusbx-devel ``` -------------------------------- ### Install Xcode Command Line Tools and LibUSB on macOS Source: https://github.com/mccdaq/uldaq/blob/master/README.md Installs Xcode command line tools and the libusb package using Homebrew on macOS. ```bash $ xcode-select --install $ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" $ brew install libusb ``` -------------------------------- ### Timer Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for timer operations, including starting, stopping, and checking the status of pulse output. ```APIDOC ## Timer ### Description Functions for timer operations, specifically pulse output. ### Functions - **ulTmrPulseOutStart()**: Starts timer pulse output. - **ulTmrPulseOutStop()**: Stops timer pulse output. - **ulTmrPulseOutStatus()**: Gets the status of timer pulse output. ``` -------------------------------- ### Timer Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for controlling and configuring timer operations, including starting, stopping, and checking the status of pulse outputs, as well as setting triggers. ```APIDOC ## Timer Operations ### Description Provides functions to manage timer-based pulse outputs and triggers. ### Functions - **ulTmrPulseOutStart()**: Starts a timer pulse output. - **ulTmrPulseOutStop()**: Stops a timer pulse output. - **ulTmrPulseOutStatus()**: Retrieves the status of a timer pulse output. - **ulTmrSetTrigger()**: Configures the trigger for timer operations. ### Parameters - **Timer argument**: 0 to 1 - **Options**: ::PO_DEFAULT, ::PO_EXTTRIGGER, ::PO_RETRIGGER - **Frequency**: 0.0233 to 50,000,000 Hz - **Trigger types**: ::TRIG_HIGH, ::TRIG_LOW, ::TRIG_POS_EDGE, ::TRIG_NEG_EDGE, ::TRIG_PATTERN_EQ, ::TRIG_PATTERN_NE, ::TRIG_PATTERN_ABOVE, ::TRIG_PATTERN_BELOW ``` -------------------------------- ### Download uldaq Library for Linux Source: https://github.com/mccdaq/uldaq/blob/master/README.md Downloads the latest version of the uldaq library for Linux using wget. ```bash Linux $ wget -N https://github.com/mccdaq/uldaq/releases/download/v1.2.1/libuldaq-1.2.1.tar.bz2 ``` -------------------------------- ### Download uldaq Library for macOS Source: https://github.com/mccdaq/uldaq/blob/master/README.md Downloads the latest version of the uldaq library for macOS using curl. ```bash macOS $ curl -L -O https://github.com/mccdaq/uldaq/releases/download/v1.2.1/libuldaq-1.2.1.tar.bz2 ``` -------------------------------- ### Device Configuration Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for device configuration, including memory read/write and setting/getting device configuration parameters. ```APIDOC ## Device ### Description Functions for device configuration and memory access. ### Functions - ulFlashLed() - ulMemRead() - ulMemWrite() - ulDevSetConfig() - ulDevGetConfig() - ulDevGetConfigStr() ### Parameters - **Configuration**: Config Item (Get/Set): ::DEV_CFG_CONNECTION_CODE - **Configuration**: Config Item (Get): ::DEV_CFG_IP_ADDR_STR, ::DEV_CFG_NET_IFC_STR ### Settings Memory Map Advanced applications can use the settings memory map for device configuration. Default settings are usually sufficient. InstaCal is the preferred method for changing device settings. ``` -------------------------------- ### Uninstall uldaq Library Source: https://github.com/mccdaq/uldaq/blob/master/README.md Command to uninstall the uldaq library from the system. ```sh $ sudo make uninstall ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Function to flash the device's LED. ```APIDOC ## Device Functions ### Description Function to control the device's LED indicator. ### Functions - ulFlashLed() ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Provides a function to flash the LED on the USB-QUAD08 device. ```APIDOC ## Device ### Description Function to control the device's LED. ### Functions - `ulFlashLed()`: Flashes the device's LED. ``` -------------------------------- ### DAQI Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for DAQI (Data Acquisition Input) scanning, status, stopping, waiting, and trigger configuration. ```APIDOC ## DAQI Functions ### Description Functions for configuring and managing Data Acquisition Input (DAQI) scans, including setting triggers and monitoring status. ### Functions - ulDaqInScan() - ulDaqInScanStatus() - ulDaqInScanStop() - ulDaqInScanWait() - ulDaqInSetTrigger() ### Available Channel Types - ::DAQI_DIGITAL - ::DAQI_CTR16 - ::DAQI_CTR32 - ::DAQI_CTR48 ### Available Scan Options - ::SO_DEFAULTIO - ::SO_SINGLEIO - ::SO_BLOCKIO - ::SO_CONTINUOUS - ::SO_EXTCLOCK - ::SO_EXTTRIGGER - ::SO_RETRIGGER ### Scan Rate Range - 0.02235 to 4,000,000 S/s ### Available Trigger Types - ::TRIG_HIGH - ::TRIG_LOW - ::TRIG_POS_EDGE - ::TRIG_NEG_EDGE ``` -------------------------------- ### Settings Memory Map Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Details the memory map for device settings, intended for advanced applications requiring custom device configuration. Default settings are usually sufficient. ```APIDOC ## Settings Memory Map ### Description This memory map allows for advanced device configuration. Changes to these settings require a device reset or power cycle to take effect. For most applications, default settings are acceptable, and InstaCal is the preferred method for changing device settings. ### Memory Map - **Address 0x00-0x01**: Network options - Bit 0: 0 = DHCP enabled, 1 = DHCP disabled - Bit 1: 0 = Auto IP enabled, 1 = Auto IP disabled - Bit 2-15: Reserved - Default Value: 0x0000 - **Address 0x02-0x05**: Default IPv4 address (e.g., 192.168.0.101) - **Address 0x06-0x09**: Default IPv4 subnet mask (e.g., 255.255.255.0) - **Address 0x0A-0x0D**: Default IPv4 gateway address (e.g., 192.168.0.1) - **Address 0x0E-0x0F**: Reserved - **Address 0x10-0x11**: Reserved - **Address 0x12-0x15**: Connection code, 4 bytes (Default: 0x00000000) - **Address 0x16-0x1F**: Reserved ### Note Settings do not take effect until after the device is reset or power cycled. Refer to the device user's manual for restoring factory default settings if communication is lost. ``` -------------------------------- ### Digital I/O Configuration Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Configuration options and functions for digital input and output on the TC-32 device. Supports multiple ports and bits, with expansion capabilities. ```APIDOC ## Digital I/O ### Description Details the digital I/O ports, bits, and functions available on the TC-32 device. Expansion modules can increase the number of available ports. ### Ports - `::FIRSTPORTA` (Bits 0-7) - `::FIRSTPORTB` (Bits 0-31) - `::SECONDPORTA` (Bits 0-7, with expansion) - `::SECONDPORTB` (Bits 0-31, with expansion) ### Functions - `ulDIn()` - `ulDOut()` - `ulDBitIn()` - `ulDBitOut()` - `ulDIOGetConfig()` - `ulDClearAlarm()` - `ulDevGetConfig()` with `::DEV_CFG_HAS_EXP` to determine port count. ### Configuration Items (Get Only) - `::DIO_CFG_PORT_DIRECTION_MASK ``` -------------------------------- ### Counter Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Provides functions for counter input, reading, loading, clearing, configuration, scanning, and trigger management. ```APIDOC ## Counter Functions ### Description Functions for managing counter operations, including input, reading, configuration, and scanning. ### Functions - ulCIn() - ulCRead() - ulCLoad() - ulCClear() - ulCConfigScan() - ulCInScan() - ulCInSetTrigger() - ulCInScanStatus() - ulCInScanStop() - ulCInScanWait() ### Available Debounce Times - ::CDT_DEBOUNCE_500ns - ::CDT_DEBOUNCE_1500ns - ::CDT_DEBOUNCE_3500ns - ::CDT_DEBOUNCE_7500ns - ::CDT_DEBOUNCE_15500ns - ::CDT_DEBOUNCE_31500ns - ::CDT_DEBOUNCE_63500ns - ::CDT_DEBOUNCE_127500ns - ::CDT_DEBOUNCE_100us - ::CDT_DEBOUNCE_300us - ::CDT_DEBOUNCE_700us - ::CDT_DEBOUNCE_1500us - ::CDT_DEBOUNCE_3100us - ::CDT_DEBOUNCE_6300us - ::CDT_DEBOUNCE_12700us - ::CDT_DEBOUNCE_25500us ``` -------------------------------- ### Event Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for enabling and disabling hardware events. ```APIDOC ## Events ### Description Functions for enabling and disabling hardware events. ### Functions - **ulEnableEvent()**: Enables a specific hardware event. - **ulDisableEvent()**: Disables a specific hardware event. ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for device control, such as flashing an LED. ```APIDOC ## Device ### Description Functions for device control. ### Functions - **ulFlashLed()**: Flashes the device's LED. ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for device control, such as flashing an LED. ```APIDOC ## Device ### Description Functions for device control. ### Functions - **ulFlashLed()**: Flashes the device LED. ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for device-level operations, such as flashing an LED. ```APIDOC ## Device ### Description Functions for device control. ### Functions - ulFlashLed() ### Details - None specified ``` -------------------------------- ### Device Configuration Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt General device configuration functions and settings for the TC-32, including memory read/write and device-specific configurations. ```APIDOC ## Device ### Description Provides functions for general device control and configuration, including flashing an LED, reading/writing memory, and setting/getting device configurations. ### Functions - `ulFlashLed()` - `ulMemRead()` - `ulMemWrite()` - `ulDevSetConfig()` - `ulDevGetConfig()` - `ulDevGetConfigStr()` ### Configuration Items (Get/Set) - `::DEV_CFG_CONNECTION_CODE` ### Configuration Items (Get Only) - `::DEV_CFG_IP_ADDR_STR` - `::DEV_CFG_NET_IFC_STR` - `::DEV_CFG_HAS_EXP ``` -------------------------------- ### Digital I/O Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Provides functions for digital input and output operations on the USB-QUAD08 device. ```APIDOC ## Digital I/O ### Description Functions for configuring and performing digital input and output operations. ### Functions - `ulDIn()`: Reads digital input. - `ulDOut()`: Writes digital output. - `ulDBitIn()`: Reads a single digital bit. - `ulDBitOut()`: Writes a single digital bit. - `ulDConfigPort()`: Configures a digital port. - `ulDConfigBit()`: Configures a single digital bit. - `ulDIOGetConfig()`: Gets the configuration of digital I/O. ### Ports - `::AUXPORT` ### Bits - 0 to 7 ### Configuration - `::DIO_CFG_PORT_DIRECTION_MASK` ``` -------------------------------- ### Analog Input Configuration Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Configuration options and functions for analog input on the TC-32 device. Supports up to 63 channels with an expansion module. ```APIDOC ## Analog Input ### Description Provides configuration details for analog input channels on the TC-32 device. The number of channels can be extended with the TC-32-EXP. ### Functions - `ulTIn()` - `ulTInArray()` - `ulAIGetConfig()` - `ulAISetConfig()` ### Configuration Items (Get/Set) - `::AI_CFG_CHAN_TC_TYPE` - `::AI_CFG_CHAN_TYPE` - `::AI_CFG_OTD_MODE` - `::AI_CFG_REJECT_FREQ_TYPE` - `::AI_CFG_CAL_TABLE_TYPE` ### Configuration Items (Get Only) - `::AI_CFG_CAL_DATE_STR` - `::AI_CFG_EXP_CAL_DATE_STR ### Flags - `::TIN_FF_DEFAULT` - `::TIN_FF_WAIT_FOR_NEW_DATA` - `::TINARRAY_FF_DEFAULT` - `::TINARRAY_FF_WAIT_FOR_NEW_DATA ``` -------------------------------- ### Extract uldaq Tarball Source: https://github.com/mccdaq/uldaq/blob/master/README.md Extracts the downloaded uldaq library tar.bz2 file. ```bash $ tar -xvjf libuldaq-1.2.1.tar.bz2 ``` -------------------------------- ### Counter Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Enables various counter measurement types and configurations for the USB-QUAD08 device. ```APIDOC ## Counter ### Description Functions for counter measurements, including counting, period, pulse width, and encoder modes. ### Functions - `ulCIn()`: Reads counter input. - `ulCRead()`: Reads counter value. - `ulCLoad()`: Loads a value into the counter. - `ulCClear()`: Clears the counter. - `ulCConfigScan()`: Configures counter scan. - `ulCInScan()`: Initiates a counter input scan. - `ulCInSetTrigger()`: Sets the trigger for counter input scan. - `ulCInScanStatus()`: Gets the status of a counter input scan. - `ulCInScanStop()`: Stops a counter input scan. - `ulCInScanWait()`: Waits for a counter input scan to complete. ### Counter Argument - 0 to 7 ### Scan Options - `::SO_DEFAULTIO`, `::SO_BLOCKIO`, `::SO_CONTINUOUS`, `::SO_EXTCLOCK`, `::SO_EXTTRIGGER` ### Scan Rates - 16-bit counter: 0.000011 to 8,000,000 S/s - 32-bit counter: 0.000011 to 2,000,000 S/s - 48-bit counter: 0.000011 to 1,000,000 S/s ### Scan Flags - `::CINSCAN_FF_DEFAULT`, `::CINSCAN_FF_CTR16_BIT`, `::CINSCAN_FF_CTR32_BIT`, `::CINSCAN_FF_CTR48_BIT` ### Trigger Types - `::TRIG_HIGH`, `::TRIG_LOW`, `::TRIG_POS_EDGE`, `::TRIG_NEG_EDGE` ### Counter Measurement Types - `::CMT_COUNT` - `::CMT_PERIOD` - `::CMT_PULSE_WIDTH` - `::CMT_ENCODER` ### Counter Measurement Modes - CMT_COUNT: `::CMM_CLEAR_ON_READ`, `::CMM_NO_RECYCLE`, `::CMM_RANGE_LIMIT_ON`, `::CMM_GATING_ON`, `::CMM_GATE_CONTROLS_DIR` - CMT_PERIOD: `::CMM_PERIOD_X1`, `::CMM_PERIOD_X10`, `::CMM_PERIOD_X100`, `::CMM_PERIOD_X1000`, `::CMM_PERIOD_GATING_ON` - CMT_PULSE_WIDTH: `::CMM_PULSE_WIDTH_GATING_ON` - CMT_ENCODER: `::CMM_ENCODER_X1`, `::CMM_ENCODER_X2`, `::CMM_ENCODER_X4`, `::CMM_ENCODER_LATCH_ON_Z`, `::CMM_ENCODER_CLEAR_ON_Z`, `::CMM_ENCODER_NO_RECYCLE`, `::CMM_ENCODER_RANGE_LIMIT_ON` ### Tick Sizes - `::CTS_TICK_20PT83ns`, `::CTS_TICK_208PT3ns`, `::CTS_TICK_2083PT3ns`, `::CTS_TICK_20833PT3ns` ### Register Types - `::CRT_COUNT`, `::CRT_LOAD`, `::CRT_MAX_LIMIT` ### Debounce Times - `::CDT_DEBOUNCE_500ns`, `::CDT_DEBOUNCE_1500ns`, `::CDT_DEBOUNCE_3500ns`, `::CDT_DEBOUNCE_7500ns`, `::CDT_DEBOUNCE_15500ns`, `::CDT_DEBOUNCE_31500ns`, `::CDT_DEBOUNCE_63500ns`, `::CDT_DEBOUNCE_127500ns`, `::CDT_DEBOUNCE_100us`, `::CDT_DEBOUNCE_300us`, `::CDT_DEBOUNCE_700us`, `::CDT_DEBOUNCE_1500us`, `::CDT_DEBOUNCE_3100us`, `::CDT_DEBOUNCE_6300us`, `::CDT_DEBOUNCE_12700us`, `::CDT_DEBOUNCE_25500us` ``` -------------------------------- ### Analog Output (DT9837A and DT9837C only) Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Details the Analog Output capabilities, which are supported only on the DT9837A and DT9837C models. This includes supported channels, ranges, scan options, scan rates, trigger types, and available functions. ```APIDOC ## Analog Output (DT9837A and DT9837C only) ### Description Provides details on Analog Output functionality, available only for the DT9837A and DT9837C models. ### Channels 0 ### Ranges - DT9837A: ::BIP10VOLTS - DT9837C: ::BIP3VOLTS ### Scan Options ::SO_DEFAULTIO, ::SO_BLOCKIO, ::SO_CONTINUOUS, ::SO_EXTTRIGGER ### Scan Rates - DT9837A: 10,000 to 52,734 S/s - DT9837C: 10,000 to 96,000 S/s ### Trigger Types ::TRIG_POS_EDGE, ::TRIG_RISING ### Functions ulAOut(), ulAOutScan(), ulAOutScanStatus(), ulAOutScanStop(), ulAOutScanWait(), ulAOutSetTrigger() ### Configuration none ``` -------------------------------- ### Counter Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for counter operations, including input, reading, loading, and clearing. ```APIDOC ## Counter ### Description Functions for counter operations. ### Functions - **ulCIn()**: Reads counter input. - **ulCRead()**: Reads the current counter value. - **ulCLoad()**: Loads a value into the counter. - **ulCClear()**: Clears the counter. ``` -------------------------------- ### Counter Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for counter operations, including input, reading, loading, and clearing. ```APIDOC ## Counter ### Description Functions for counter operations. ### Functions - ulCIn() - ulCRead() - ulCLoad() - ulCClear() ### Details - Counter argument: 0 ``` -------------------------------- ### DAQI Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for configuring and managing analog and digital input scans, including setting up triggers and monitoring scan status. ```APIDOC ## DAQI (Data Acquisition Input) Operations ### Description Handles analog and digital data acquisition input scans. ### Functions - **ulDaqInScan()**: Initiates a data acquisition input scan. - **ulDaqInScanStatus()**: Retrieves the status of an input scan. - **ulDaqInScanStop()**: Stops an ongoing input scan. - **ulDaqInScanWait()**: Waits for an input scan to complete. - **ulDaqInSetTrigger()**: Configures the trigger for input scans. ### Parameters - **Channel types**: ::DAQI_ANALOG_DIFF, ::DAQI_ANALOG_SE, ::DAQI_DIGITAL, ::DAQI_CTR32 - **Scan options**: ::SO_DEFAULTIO, ::SO_SINGLEIO, ::SO_BLOCKIO, ::SO_CONTINUOUS, ::SO_EXTCLOCK, ::SO_EXTTRIGGER, ::SO_RETRIGGER - **Scan rates**: USB-1808: 0.0233 to 50,000 S/s, USB-1808X: 0.0233 to 200,000 S/s - **Trigger types**: ::TRIG_HIGH, ::TRIG_LOW, ::TRIG_POS_EDGE, ::TRIG_NEG_EDGE, ::TRIG_PATTERN_EQ, ::TRIG_PATTERN_NE, ::TRIG_PATTERN_ABOVE, ::TRIG_PATTERN_BELOW ``` -------------------------------- ### Analog Output Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for performing analog output operations on supported devices. ```APIDOC ## Analog Output (USB-202 and USB-205) ### Description Functions for performing analog output operations on supported devices. ### Functions - **ulAOut()**: Writes a value to a single analog output channel. ``` -------------------------------- ### Counter Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for interacting with counter hardware. ```APIDOC ## Counter ### Description Functions for interacting with counter hardware. ### Functions - **ulCIn()**: Reads the current value of a counter. - **ulCRead()**: Reads a counter value. - **ulCLoad()**: Loads a value into a counter. - **ulCClear()**: Clears a counter. ``` -------------------------------- ### Timer Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for controlling and monitoring timer pulse output on the USB-QUAD08 device. ```APIDOC ## Timer ### Description Functions for starting, stopping, and checking the status of timer pulse outputs. ### Functions - `ulTmrPulseOutStart()`: Starts timer pulse output. - `ulTmrPulseOutStop()`: Stops timer pulse output. - `ulTmrPulseOutStatus()`: Gets the status of timer pulse output. ### Timer Argument - 0 to 1 ### Options - `::PO_DEFAULT`, `::PO_EXTTRIGGER`, `::PO_RETRIGGER` ### Frequency - 0.0111 to 24,000,000 Hz ``` -------------------------------- ### Counter Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for counter operations, including input reading, loading, and clearing. ```APIDOC ## Counter ### Description Functions for counter operations. ### Functions - **ulCIn()**: Reads counter input. - **ulCRead()**: Reads counter value. - **ulCLoad()**: Loads counter. - **ulCClear()**: Clears counter. ### Counter Argument 0 ``` -------------------------------- ### Counter (DT9837A and DT9837B only) Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Details the Counter capabilities, supported only on the DT9837A and DT9837B models. This includes supported counter arguments, scan options, scan rates, scan flags, trigger types, measurement types, and measurement modes. ```APIDOC ## Counter (DT9837A and DT9837B only) ### Description Provides details on Counter functionality, available only for the DT9837A and DT9837B models. ### Counter Argument 0 to 2 ### Scan Options ::SO_DEFAULTIO, ::SO_SINGLEIO, ::SO_BLOCKIO, ::SO_CONTINUOUS, ::SO_EXTTRIGGER, ::SO_EXTTIMEBASE, ::SO_TIMEBASEOUT ### Scan Rates - DT9837A: 195.313 to 52,734 S/s - DT9837B: 195.313 to 10,546 S/s ### Scan Flags ::CINSCAN_FF_DEFAULT, ::CINSCAN_FF_CTR32_BIT, ::CINSCAN_FF_NOCLEAR ### Trigger Types ::TRIG_POS_EDGE, ::TRIG_RISING ### Counter Measurement Types - Counter 0 to Counter 2: ::CMT_COUNT, ::CMT_PERIOD - Counter 1 and Counter 2 also support ::CMT_PULSE_WIDTH ### Counter Measurement Modes - CMT_COUNT: ::CMM_DEFAULT - CMT_PERIOD: ::CMM_PERIOD_X1 - CMT_PULSE_WIDTH: ::CMM_PULSE_WIDTH_DEFAULT ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for device-level operations. ```APIDOC ## Device ### Description Functions for controlling device-specific features. ### Functions - ulFlashLed() ### Configuration none ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for device-level operations. ```APIDOC ## Device ### Description Provides functions for device-specific operations. ### Functions - ulFlashLed() ### Details - Configuration: none ``` -------------------------------- ### Digital I/O Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for configuring and performing digital input and output operations. ```APIDOC ## Digital I/O ### Description Functions for configuring and performing digital input and output operations. ### Functions - **ulDIn()**: Reads a digital input port. - **ulDOut()**: Writes a value to a digital output port. - **ulDBitIn()**: Reads a single digital input bit. - **ulDBitOut()**: Writes a value to a single digital output bit. - **ulDConfigPort()**: Configures the direction of a digital I/O port. - **ulDConfigBit()**: Configures the direction of a single digital I/O bit. - **ulDIOGetConfig()**: Retrieves the configuration of a digital I/O port. ``` -------------------------------- ### Timer Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for timer operations, including pulse output. ```APIDOC ## Timer ### Description Functions for controlling timer operations, such as pulse output. ### Functions - ulTmrPulseOutStart() - ulTmrPulseOutStop() - ulTmrPulseOutStatus() ### Timer Argument 0 to 3 ### Options - ::PO_DEFAULT ### Frequency 0.0149 to 32,000,000 Hz ``` -------------------------------- ### Analog Input Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for performing analog input operations, including single-channel input, scanning, queue loading, status checks, stopping scans, and setting triggers. ```APIDOC ## Analog Input ### Description Functions for analog input operations. ### Functions - **ulAIn()**: Reads a single analog input channel. - **ulAInScan()**: Performs analog input scanning. - **ulAInLoadQueue()**: Loads the analog input queue. - **ulAInScanStatus()**: Gets the status of an analog input scan. - **ulAInScanStop()**: Stops an analog input scan. - **ulAInScanWait()**: Waits for an analog input scan to complete. - **ulAInSetTrigger()**: Sets the trigger for analog input. ### Channels 0 to 7 ### Input Modes ::AI_SINGLE_ENDED ### Ranges ::BIP10VOLTS, ::BIP5VOLTS, ::BIP2VOLTS, ::BIP1VOLTS ### Scan Options ::SO_DEFAULTIO, ::SO_SINGLEIO, ::SO_BLOCKIO, ::SO_CONTINUOUS, ::SO_EXTCLOCK, ::SO_EXTTRIGGER, ::SO_BURSTIO, ::SO_PACEROUT ### Scan Rates 0.009 to 1,000,000 S/s ### Trigger Types ::TRIG_HIGH, ::TRIG_LOW, ::TRIG_POS_EDGE, ::TRIG_NEG_EDGE ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Function for controlling device-specific features, such as flashing an LED. ```APIDOC ## Device Operations ### Description Provides control over device-specific functionalities. ### Functions - **ulFlashLed()**: Flashes the device's LED. ### Parameters - **Configuration**: none ``` -------------------------------- ### Analog Input Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for performing analog input operations, including single channel input, scanning, and trigger configuration. ```APIDOC ## Analog Input ### Description Functions for analog input operations. ### Functions - **ulAIn()**: Reads a single analog input channel. - **ulAInScan()**: Performs analog input scanning. - **ulAInLoadQueue()**: Loads the analog input queue. - **ulAInScanStatus()**: Gets the status of an analog input scan. - **ulAInScanStop()**: Stops an analog input scan. - **ulAInScanWait()**: Waits for an analog input scan to complete. - **ulAInSetTrigger()**: Sets the trigger for analog input. ``` -------------------------------- ### DAQO Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for configuring and managing analog and digital output scans, including setting up triggers and monitoring scan status. ```APIDOC ## DAQO (Data Acquisition Output) Operations ### Description Handles analog and digital data acquisition output scans. ### Functions - **ulDaqOutScan()**: Initiates a data acquisition output scan. - **ulDaqOutScanStatus()**: Retrieves the status of an output scan. - **ulDaqOutScanStop()**: Stops an ongoing output scan. - **ulDaqOutScanWait()**: Waits for an output scan to complete. - **ulDaqOutSetTrigger()**: Configures the trigger for output scans. ### Parameters - **Channel types**: ::DAQO_ANALOG, ::DAQO_DIGITAL - **Scan options**: ::SO_DEFAULTIO, ::SO_SINGLEIO, ::SO_BLOCKIO, ::SO_CONTINUOUS, ::SO_EXTCLOCK, ::SO_EXTTRIGGER, ::SO_RETRIGGER - **Scan rates**: USB-1808: 0.0233 to 125,000 S/s, USB-1808X: 0.0233 to 500,000 S/s - **Trigger types**: ::TRIG_HIGH, ::TRIG_LOW, ::TRIG_POS_EDGE, ::TRIG_NEG_EDGE, ::TRIG_PATTERN_EQ, ::TRIG_PATTERN_NE, ::TRIG_PATTERN_ABOVE, ::TRIG_PATTERN_BELOW ``` -------------------------------- ### Event Handling Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for enabling and disabling events. ```APIDOC ## Events ### Description Functions for event handling. ### Functions - ulEnableEvent() - ulDisableEvent() ### Parameters - **Event types**: ::DE_ON_DATA_AVAILABLE, ::DE_ON_END_OF_INPUT_SCAN, ::DE_ON_INPUT_SCAN_ERROR ``` -------------------------------- ### Device Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for controlling device-level operations. ```APIDOC ## Device ### Description Functions for controlling device-level operations. ### Functions - **ulFlashLed()**: Flashes the device's LED. ``` -------------------------------- ### Event Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for enabling and disabling events. ```APIDOC ## Events ### Description Functions for managing events. ### Functions - **ulEnableEvent()**: Enables a specified event. - **ulDisableEvent()**: Disables a specified event. ``` -------------------------------- ### Event Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for enabling and disabling events. ```APIDOC ## Events ### Description Provides functions to enable and disable various device events. ### Functions - ulEnableEvent() - ulDisableEvent() ### Details - Event types: ::DE_ON_DATA_AVAILABLE, ::DE_ON_END_OF_INPUT_SCAN, ::DE_ON_INPUT_SCAN_ERROR, ::DE_ON_END_OF_OUTPUT_SCAN, ::DE_ON_OUTPUT_SCAN_ERROR ``` -------------------------------- ### Event Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for enabling and disabling events. ```APIDOC ## Events ### Description Functions to manage event notifications for various operations. ### Functions - ulEnableEvent() - ulDisableEvent() ### Event Types - ::DE_ON_DATA_AVAILABLE - ::DE_ON_END_OF_INPUT_SCAN - ::DE_ON_INPUT_SCAN_ERROR - ::DE_ON_END_OF_OUTPUT_SCAN - ::DE_ON_OUTPUT_SCAN_ERROR ``` -------------------------------- ### Digital I/O Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for digital input and output operations, including port and bit configuration. ```APIDOC ## Digital I/O ### Description Functions for digital input and output operations. ### Functions - **ulDIn()**: Reads digital input from a port. - **ulDOut()**: Writes digital output to a port. - **ulDBitIn()**: Reads a digital input bit. - **ulDBitOut()**: Writes a digital output bit. - **ulDConfigPort()**: Configures a digital I/O port. - **ulDConfigBit()**: Configures a digital I/O bit. - **ulDIOGetConfig()**: Gets the configuration of a digital I/O port. ``` -------------------------------- ### Analog Input Functions Source: https://github.com/mccdaq/uldaq/blob/master/doc/pagesref.txt Functions for performing analog input operations. ```APIDOC ## Analog Input ### Description Functions for reading analog voltage values from the device. ### Functions - ulAIn() - ulAInScan() - ulAInLoadQueue() - ulAInScanStatus() - ulAInScanStop() - ulAInScanWait() - ulAInSetTrigger() ### Channels USB-2623: 0 to 15 USB-2633: 0 to 15 USB-2633: 0 to 63 USB-2637: 0 to 63 ### Input Modes - ::AI_SINGLE_ENDED ### Ranges - ::BIP10VOLTS ### Scan Options - ::SO_DEFAULTIO - ::SO_SINGLEIO - ::SO_BLOCKIO - ::SO_CONTINUOUS - ::SO_EXTCLOCK - ::SO_EXTTRIGGER - ::SO_RETRIGGER - ::SO_BURSTMODE ### Scan Rates 0.0149 to 1,000,000 S/s ### Trigger Types - ::TRIG_HIGH - ::TRIG_LOW - ::TRIG_POS_EDGE - ::TRIG_NEG_EDGE ```