Cilxs_init – AMETEK Ls Series Driver Manual User Manual
Page 184

IVI Driver Manual
Lx / Ls Series
180
ciLxs_init
ViStatus ciLxs_init (ViRsrc resourceName, ViBoolean IDQuery,
ViBoolean resetDevice, ViPSession instrumentHandle,
ViInt32 baudRate);
Purpose
This function performs the following initialization actions:
- Creates a new IVI instrument driver session.
- Opens a session to the specified device using the interface and address
you specify for the Resource Name parameter.
- If the ID Query parameter is set to VI_TRUE, this function queries the
instrument ID and checks that it is valid for this instrument driver.
- If the Reset parameter is set to VI_TRUE, this function resets the
instrument to a known state.
- Sends initialization commands to set the instrument to the state
necessary for the operation of the instrument driver.
- Returns a ViSession handle that you use to identify the instrument in
all subsequent instrument driver function calls.
Note: This function creates a new session each time you invoke it.
Although you can open more than one IVI session for the same resource, it
is best not to do so. You can use the same session in multiple program
threads. You can use the ciLxs_LockSession and ciLxs_UnlockSession
functions to protect sections of code that require exclusive access to
the resource.
Parameter List
resourceName
Variable Type ViRsrc
Pass the resource name of the device to initialize.
Refer to the following table below for the exact grammar to use for
this parameter. Optional fields are shown in square brackets ([]).
Interface Syntax
------------------------------------------------------
GPIB GPIB[board]::
[::secondary address]::INSTR
Serial ASRL
Use the GPIB keyword for GPIB instruments. Use the ASRL keyword for
serial instruments.