#include <ljacklm_wrapper.h>
Public Member Functions | |
long | config () |
Configure input/output lines in labjack. | |
long | disableWatchdog (int activeD) |
Disable the watchdog for a D line. | |
long | enableWatchdog (long timeout, int activeD, long state) |
Enable and configure the watchdog. | |
long | readAI (long channel, float *voltage) |
Read the value of one AI line. | |
long | readAIs (long num_channels, long *channels, float *voltages) |
Read the voltage of several AI lines. | |
long | readD (long channel, long *state) |
Read the value of one D line. | |
long | readDifferentialAI (long channel, float *voltage) |
Read the voltage in a differential way of the AI lines. | |
long | readDIOs (long *stateD, long *stateIO) |
Read all the D and IO input lines. | |
long | readDirectionDs (long *directions) |
Read the D line directions (in binary, 0:input and 1:output) | |
long | readIO (long channel, long *state) |
Read the value of one IO line. | |
long | reset () |
Reset the labjack. | |
long | writeAO (int channel, float voltage) |
Write the value of one AO line. | |
long | writeAOs (float voltageAO0, float voltageAO1) |
Write the voltage of AO0 and AO1 lines. | |
long | writeD (long channel, long state) |
Write the value of one D line. | |
long | writeDCONFIG (long channel, long state) |
Write the value of one D line and configure the D lines. | |
long | writeDIOs (long *direcD, long *direcIO, long *stateD, long *stateIO) |
Write and read all D and IO input lines. | |
long | writeDIOsCONFIG (long *stateD, long *stateIO) |
Write and read all D and IO input lines depending on CONFIG_D and CONFIG_IO. | |
long | writeIO (long channel, long state) |
Write the value of one IO line. | |
long | writePulse (long pulse_level, long line, long pulse_time, long line_type) |
Generate the pulse in one the lines D0..D15. |
Definition at line 58 of file ljacklm_wrapper.h.
long LjacklmWrapper::config | ( | ) | [virtual] |
Configure input/output lines in labjack.
Implements LabjackDriverInterface.
Definition at line 34 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::disableWatchdog | ( | int | activeD | ) | [virtual] |
Disable the watchdog for a D line.
activeD | D line to disable (0,1,8). |
Implements LabjackDriverInterface.
Definition at line 423 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::enableWatchdog | ( | long | timeout, |
int | activeD, | ||
long | state | ||
) | [virtual] |
Enable and configure the watchdog.
timeout | time in seconds to reset (1-715). |
activeD | D line to enable (0,1,8). |
state | state of the D line (0-1). |
Implements LabjackDriverInterface.
Definition at line 389 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::readAI | ( | long | channel, |
float * | voltage | ||
) | [virtual] |
Read the value of one AI line.
channel | channel number to read: 0..7. (e.g. to channel=0 => read AI0). |
voltage | read voltage to return. |
Implements LabjackDriverInterface.
Definition at line 255 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::readAIs | ( | long | num_channels, |
long * | channels, | ||
float * | voltages | ||
) | [virtual] |
Read the voltage of several AI lines.
num_channels | number of channels to read: 1, 2 รณ 4. |
channels | array with channels values: channels[num_channels] = {0,..,7}. (e.g. to channels={0,1} => read AI0 and AI1). |
voltages | array with read voltages to return. |
Implements LabjackDriverInterface.
Definition at line 271 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::readD | ( | long | channel, |
long * | state | ||
) | [virtual] |
Read the value of one D line.
channel | line to read: channel >= 0 & channel <= 3. |
state | value of the line state: state > 0 -> high level, state = 0 -> low level. |
Implements LabjackDriverInterface.
Definition at line 177 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::readDifferentialAI | ( | long | channel, |
float * | voltage | ||
) | [virtual] |
Read the voltage in a differential way of the AI lines.
channel | channel number to read: 8..11. (e.g. to channel=8 => read difference between AI0 and AI1, and so on). |
voltages | array with read voltages to return. |
Implements LabjackDriverInterface.
Definition at line 319 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::readDIOs | ( | long * | stateD, |
long * | stateIO | ||
) | [virtual] |
Read all the D and IO input lines.
stateD | D line states (D0-D15). |
stateIO | IO line states (IO0-IO3). |
Implements LabjackDriverInterface.
Definition at line 112 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::readDirectionDs | ( | long * | directions | ) | [virtual] |
Read the D line directions (in binary, 0:input and 1:output)
directions | directions of the D lines. |
Implements LabjackDriverInterface.
Definition at line 523 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::readIO | ( | long | channel, |
long * | state | ||
) | [virtual] |
Read the value of one IO line.
channel | line to read: channel >= 0 & channel <= 3. |
state | value of the line state: state > 0 -> high level, state = 0 -> low level. |
Implements LabjackDriverInterface.
Definition at line 73 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::reset | ( | ) | [virtual] |
Reset the labjack.
Implements LabjackDriverInterface.
Definition at line 60 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writeAO | ( | int | channel, |
float | voltage | ||
) | [virtual] |
Write the value of one AO line.
channel | channel number to assign a voltage: channel=0->AO0, channel=1->AO1 and channel=2->AO0&AO1. |
voltage | value of the voltage to assign: voltage >= 0.0 & voltage <= 5.0. |
Implements LabjackDriverInterface.
Definition at line 335 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writeAOs | ( | float | voltageAO0, |
float | voltageAO1 | ||
) | [virtual] |
Write the voltage of AO0 and AO1 lines.
voltageAO0 | voltage value to assign to AO0 (voltageAO0 >= 0.0 & voltageAO0 <= 5.0). |
voltageAO1 | voltage value to assign to AO1 (voltageAO1 >= 0.0 & voltageAO1 <= 5.0). |
Implements LabjackDriverInterface.
Definition at line 370 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writeD | ( | long | channel, |
long | state | ||
) | [virtual] |
Write the value of one D line.
channel | line to read: channel >= 0 & channel <= 3. |
state | value of the line state: state > 0 -> high level, state = 0 -> low level. |
Implements LabjackDriverInterface.
Definition at line 196 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writeDCONFIG | ( | long | channel, |
long | state | ||
) | [virtual] |
Write the value of one D line and configure the D lines.
channel | line to read: channel >= 0 & channel <= 3. |
state | value of the line state: state > 0 -> high level, state = 0 -> low level. |
Implements LabjackDriverInterface.
Definition at line 217 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writeDIOs | ( | long * | direcD, |
long * | direcIO, | ||
long * | stateD, | ||
long * | stateIO | ||
) | [virtual] |
Write and read all D and IO input lines.
direcD | D lines direction (0=input, 1=output). |
direcIO | IO lines direction (0=input, 1=output). |
stateD | D lines level (D0-D15). |
stateIO | IO lines level (IO0-IO3). |
Implements LabjackDriverInterface.
Definition at line 130 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writeDIOsCONFIG | ( | long * | stateD, |
long * | stateIO | ||
) | [virtual] |
Write and read all D and IO input lines depending on CONFIG_D and CONFIG_IO.
stateD | D lines level (D0-D15). |
stateIO | IO lines level (IO0-IO3). |
Implements LabjackDriverInterface.
Definition at line 156 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writeIO | ( | long | channel, |
long | state | ||
) | [virtual] |
Write the value of one IO line.
channel | line to read: channel >= 0 & channel <= 3. |
state | value of the line state: state > 0 -> high level, state = 0 -> low level. |
Implements LabjackDriverInterface.
Definition at line 92 of file ljacklm_wrapper.cpp.
long LjacklmWrapper::writePulse | ( | long | pulse_level, |
long | line, | ||
long | pulse_time, | ||
long | line_type | ||
) | [virtual] |
Generate the pulse in one the lines D0..D15.
pulse_level | pulse level: 0->high level, 0->low level. |
line | line to use (for lines D:0..15; for lines IO:0..3). |
pulse_time | time in microseconds for a pulse (1..2000000). |
line_type | type of line, 0=D line, 1=IO line |
Implements LabjackDriverInterface.
Definition at line 457 of file ljacklm_wrapper.cpp.