11-24-2019 01:47 AM - edited 11-24-2019 01:51 AM
Hi everyone,
do anybody know how to convert the GPIB address to VISA resource name, for exampl I stored the address 20 in a .txt file, In labview I want read the address 20 and config it to a VISA resource name,like GPIB0::20::INSTR.so the VISA Write.VI Can use the address.
how to develop code to do this?
thanks in addvance.
Solved! Go to Solution.
11-24-2019 06:48 AM
You might have some luck using the VISA Find Resource node.
This will return all the resources that match specific patterns (and you can create a pattern to describe your existing GPIB address, perhaps) and then you can pass the resources to VISA Open, for example.
Copying from the bottom of the "Detailed Help" for the function:
LabVIEW lists resources in an I/O control according to the chosen I/O control class type and the Filter VISA Names dialog box, so you might not need to call this function.
All resource strings returned by this function are recognized by VISA Open. However, this function does not necessarily return all strings that you pass to the VISA Open function. This is especially true for network and TCP/IP resources. If a resource does not appear in the list, you can explicitly add the resource in the NI-VISA configuration utility, such as (Windows) Measurement & Automation Explorer, (Linux) visaconf, or (Mac OS X) NI-VISA Configuration. The configuration utility also has options that expand or limit the set of resources that this VI returns.
11-24-2019 08:21 PM
Hi Cbutcher,
thanks a lot, that is what I want, I works very well.