Find DAQmx Resource Name of a Modular Instrument from VISA Alias
Primary Software Version: 3.8
Primary Software Fixed Version: N/A
Secondary Software: Utility Software>>Measurement & Automation Explorer
I am using the NI-SWITCH and the Init with Topology.vi to open up a driver session to my PXI-2532. I would like to use the string “PXI1::5” to open a session to my switch in chassis 1 slot 5. However, the driver throws
According to Knowledge Base 4MJEIND4, VISA aliases such as "PXI::5" are only supported for switches that are programmed with Traditional NI-DAQ. In this case, my switch uses the DAQmx driver and requires the Resource Name of the device. In this case, I am writing code to be distributed to customers who would prefer to use the chassis and slot number to identify their devices. Is there a way that NI-SWITCH functions will accept the “PXI1::5” string?
There is no direct way for the NI-SWITCH driver to accept the address string if you are working with switch hardware addressed by the DAQmx resource name. However, if you are not interested in using the DAQmx resource name, you can programmatically use the chassis and slot number along the with ModInst driver functions to find the DAQmx resource name, as seen in the LabVIEW 2016 VI attached below.
NI-ModInst is a component that you can use to query information about National Instruments modular instruments installed in your system. NI-ModInst provides a programmatic way to determine the number, names, models, and other attributes of devices in your system that are supported by a specified driver. You can use the NI-ModInst API in applications you develop using LabVIEW, LabWindows™/CVI™, Measurement Studio, or ANSI C.
In general, you provide the name of a National Instruments instrument driver to NI-ModInst. Examples of instrument drivers include NI-SWITCH, NI-SCOPE, NI-FGEN, and NI-DMM. NI-ModInst searches the system and finds all the devices that are supported by that driver. You can query NI-ModInst for the number of installed devices, the device names, product models, serial numbers, chassis numbers, slot numbers, bus numbers, and socket numbers. The ModInst functions can be found on the block diagram by navigating to the NI-ModInst VI palette: Functions»Instrument I/O»Instrument Drivers»NI-ModInst The basic process for determining the DAQmx resource name for your MI devices is:
Knowledge Base 4MJEIND4: Error -1074118644 (0xBFFA400C) Using an NI Switch
Knowledge Base 3KK599LE: How Can I Programmatically Get Information from Modular Instruments?
Report Date: 11/07/2008
Last Updated: 07/05/2017
Document ID: 4R6ES99G