From 11:00 PM CDT Friday, Nov 8 - 2:30 PM CDT Saturday, Nov 9, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabWindows/CVI Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
0 Kudos
Wolfgang

Function to find instrument​s on a LAN

Status: New

Hi,

 

it's an old question, see here, but so far I have not heard about a practical solution. The quest is to find all instruments on a local LAN that are switched ON (and connected to the LAN, of course). Unfortunately, viFindRsrc does not work. Pinging all possible addresses seems not a viable solution due to the required time, either. So it's possible to detect all serial instruments, all instruments connected via GPIB, but until now there is no standalone solution (i.e.without involving NI-MAX) to detect instruments on a local LAN... Smiley Sad

 

Thanks,

Wolfgang

 

 

4 Comments
LuisG
NI Employee (retired)

Hi Wolfgang,

 

Have you looked into the NI System Configuration library? It should get installed to your CVI library menu when you install NI-MAX (so, yes, you can't completely avoid NI-MAX).

 

There is a function in that API (NISysCfgFindSystems) which you can use to discover devices in a subnet.

 

There are some caveats, though. From what I understand, this library uses other NI drivers internally (e.g. NI-VISA and NI-488.2) to do its work so, depending on the device, you might still have to configure them in MAX ahead of time. For example, if a device is not a LXI device, I think VISA only recognizes it if you have explicitly added it to MAX.

Wolfgang
Trusted Enthusiast

@luis wrote:

... 

For example, if a device is not a LXI device, I think VISA only recognizes it if you have explicitly added it to MAX


 

Yes, that is exactly my problem / wish... I do not have LXI instruments, but newer instrumentation usually comes with LAN capabilities (instead of serial or GPIB). While ten years ago I could use viFindRsrc to detect this instrument (then with serial), now I miss a possibility to detect this instrument which is connected to my local LAN.

 

I have modern hardware but need to configure it manually...this is odd.

 

There is some software available to detect instruments on a LAN, but I did not want to use an extra program but a simple function call within C...

 

LuisG
NI Employee (retired)

Okay, I see.

 

My only advice, at this time, is that you resubmit this suggestion in this board instead, which is the one that NI system configuration folks monitor, otherwise it would lead a lonely, ignored existence in the CVI forum Smiley Wink

 

Luis

Wolfgang
Trusted Enthusiast

I have re-posted the suggestion as requested. What should I do to help my other lonely, ignored suggestions? Smiley Wink