niModinst Get Installed Device Attribute (poly)

ModInst

niModinst Get Installed Device Attribute (poly)

Returns an attribute (either an integer or a string) specified by the attribute ID parameter for a device specified by the session in and index in parameters.

The session in parameter is expected to be a valid handle returned by niModInst Open Installed Devices Session. Therefore, this parameter acts as a handle to a list of installed devices. The index in parameter specifies the device in the list for which you want the attribute.

Use the pull-down menu to select an instance of this VI.

String

Returns a string attribute specified by the attribute ID parameter for a device specified by the session in and index in parameters.

session in is the NI-ModInst session handle created by niModInst Open Installed Devices Session.
index in is a zero-based index that specifies the device for which you want the attribute.

The index in parameter should be between 0 and (device count – 1), inclusive, where device count is the number of installed devices returned by niModinst Open Installed Devices Session.

attribute ID is the ID of the string attribute you want to query.

Valid Values

Device Name—the name of the device, which can be used to open an instrument driver session for that device

Device Model—the model of the device (for example, NI PXI-5122)

Serial Number—the serial number of the device

error in describes error conditions that occur before this VI or function runs.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a negative error code. If status is FALSE, code is 0 or a warning code.
source identifies where an error occurred. The source string includes the name of the VI that produced the error, what inputs are in error, and how to eliminate the error.
session out has the same value as session in.
index out has the same value as index in.
attribute value returns the value of the requested attribute.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source identifies where and why an error occurred. The source string includes the name of the VI that produced the error, what inputs are in error, and how to eliminate the error.

I32

Returns an integer attribute specified by the attribute ID parameter for a device specified by the session in and index in parameters.

session in is the NI-ModInst session handle created by niModInst Open Installed Devices Session.
index in is a zero-based index that specifies the device for which you want the attribute.

The index in parameter should be between 0 and (device count – 1), inclusive, where device count is the number of installed devices returned by niModinst Open Installed Devices Session.

attribute ID is the ID of the integer attribute you want to query.

Valid Values

Slot Number—the slot (for example, in a PXI chassis) in which the device is installed. This attribute can only be queried for PXI devices installed in a chassis that has been properly identified in MAX.

Chassis Number—the number of the chassis in which the device is installed. This attribute can only be queried for PXI devices installed in a chassis that has been properly identified in MAX.

Bus Number—the bus on which the device has been enumerated.

Socket Number—the socket number on which the device has been enumerated.

PCI Express Link Width—the PCI express link width negotiated between the device and the system.

PCI Express Max Link Width—the maximum PCI express link width supported by the device.

Notes  
  • The bus number and socket number can be used to form a VISA resource string for the device, of the form PXIn::x::INSTR, where n is the bus number and x is the socket number. For example, for bus number 2 and socket number 13, use PXI2::13::INSTR.
  • Traditional NI-DAQ devices do not support the Bus Number and Socket Number attributes.
error in describes error conditions that occur before this VI or function runs.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a negative error code. If status is FALSE, code is 0 or a warning code.
source identifies where an error occurred. The source string includes the name of the VI that produced the error, what inputs are in error, and how to eliminate the error.
session out has the same value as session in.
index out has the same value as index in.
attribute value returns the value of the requested attribute.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source identifies where and why an error occurred. The source string includes the name of the VI that produced the error, what inputs are in error, and how to eliminate the error.