EasyManua.ls Logo

LabJack U12 - 4.35 - Watchdog

LabJack U12
61 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Inputs:
*idnum – Local ID, serial number, or -1 for first found.
demoSend 0 for normal operation, >0 for demo mode. Demo mode allows this function to be called without a LabJack.
modeSpecify SPI mode as: 0=A,1=B,2=C,3=D (0-3).
msDelayIf >0, a 1 ms delay is added between each bit.
husDelayIf >0, a hundred us delay is added between each bit.
controlCS – If >0, D0-D7 is automatically controlled as CS. The state and direction of CS is only tested if control is enabled.
csLine – D line to use as CS if enabled (0-7).
csStateActive state for CS line. This would be 0 for the normal !CS, or >0 for the less common CS.
configDIf >0, state and tris are configured for D13, D14, D15, and !CS.
numWriteReadNumber of bytes to write and read (1-18).
*dataSerial data buffer. Send an 18 element array of bytes. Fill unused locations with zeros.
Outputs:
*idnum – Returns the local ID or 1 if no LabJack is found.
*dataSerial data buffer. Returns any serial read data. Unused locations are filled with 9999s.
ActiveX Function Differences:
The maximum number of bytes to write/read is limited to 5 (numWriteRead should be 1-5). The data array is replaced with pointers
to 5 individual data bytes.
Declaration (ActiveX):
long SynchX ( long FAR* idnum,
long demo,
long mode,
long msDelay,
long husDelay,
long controlCS,
long csLine,
long csState,
long configD,
long numWriteRead,
long FAR* data0,
long FAR* data1,
long FAR* data2,
long FAR* data3,
long FAR* data4,
long FAR* data5 )
4.35 - Watchdog
Controls the LabJack watchdog function. When activated, the watchdog can change the states of digital I/O if the LabJack does
not successfully communicate with the PC within a specified timeout period. This function could be used to reboot the PC allowing
for reliable unattended operation. The 32-bit counter (CNT) is disabled when the watchdog is enabled.
Execution time for this function is 20 milliseconds or less (typically 16 milliseconds in Windows).
If you set the watchdog to reset the LabJack, and choose too small of a timeout period, it might be difficult to make the device stop
resetting. To disable the watchdog, reset the LabJack with IO0 shorted to STB, and then reset again without the short.
Declaration:
long Watchdog ( long *idnum,
long demo,
long active,
long timeout,
long reset,
long activeD0,
long activeD1,
long activeD8,
long stateD0,
long stateD1,
long stateD8 )
Parameter Description:
Returns: LabJack errorcodes or 0 for no error.
Inputs:
*idnum – Local ID, serial number, or -1 for first found.
40

Other manuals for LabJack U12