niSE Open Session VI

NI Switch Executive 2015 Help

Edition Date: August 2015

Part Number: 370404J-01

»View Product Info

Opens a session to a specified NI Switch Executive virtual device. Opens communications with all of the IVI switches associated with the specified NI Switch Executive virtual device. Returns a session handle that you use to identify the virtual device in all subsequent NI Switch Executive VI calls.

Details

niSE Open Session

/images/reference/en-XX/help/370404J-01/cstr.gif

Virtual Device Name (SwitchConfiguration1) is the session referencing this NI Switch Executive virtual device.

/images/reference/en-XX/help/370404J-01/cstr.gif

Option String ("") can be used to pass information to each of the IVI devices on startup. It can be used to set things such as simulation, range checking, and so on. Consult your driver documentation for more information about valid entries for the option string.

/images/reference/en-XX/help/370404J-01/cerrcodeclst.gif

error in (no error) describes error conditions that occur before this node runs. This input provides standard error in functionality.

/images/reference/en-XX/help/370404J-01/cbool.gif

status is TRUE (X) if an error occurred before this VI ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI ran. The default is FALSE.

/images/reference/en-XX/help/370404J-01/ci32.gif

code is the error or warning code. The default is 0. If status is TRUE, code is a non-zero error code. If status is FALSE, code is 0 or a warning code.

/images/reference/en-XX/help/370404J-01/cstr.gif

source describes the origin of the error or warning and is, in most cases, the name of the VI that produced the error or warning. The default is an empty string.

/images/reference/en-XX/help/370404J-01/irn.gif

NISE Session (out) is the session referencing this NI Switch Executive virtual device. Session handles are created through a call to the niSE Open Session VI. This session handle is the copy of the session handle that was passed in and provides for easier wiring between NI Switch Executive VIs.

/images/reference/en-XX/help/370404J-01/ierrcodeclst.gif

error out contains error information. This output provides standard error out functionality.

/images/reference/en-XX/help/370404J-01/ibool.gif

status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.

/images/reference/en-XX/help/370404J-01/ii32.gif

code is the error or warning code. If status is TRUE, code is a non-zero error code. If status is FALSE, code is 0 or a warning code.

/images/reference/en-XX/help/370404J-01/istr.gif

source describes the origin of the error or warning and is, in most cases, the name of the VI that produced the error or warning.

Details

NI Switch Executive uses a reference counting scheme to manage open session handles to an NI Switch Executive virtual device. Each call to niSE Open Session must be matched with a subsequent call to the niSE Close Session VI.

Successive calls to the niSE Open Session VI with the same virtual device name always returns the same session handle.

NI Switch Executive disconnects its communication with the IVI switches after all session handles are closed to a given virtual device.

The session handles can be used safely in multiple threads of an application.

Sessions can only be opened to a given NI Switch Executive virtual device from a single process at a time.

WAS THIS ARTICLE HELPFUL?

Not Helpful