LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Force Application to choose network interface

Solved!
Go to solution

Hi Everyone,

 

My target computer as two NIC,

Eth1:

IP: 192.168.0.14

Mask: 255.255.255.0

GateWay: 192.168.0.254

 

Eth2:

IP: 10.2.5.168

Mask: 255.255.0.0

Gateway: Blank

 

Eth1 is supposed to be connected to the network, Eth2 is only connected to a camera.

 

I use a Blank String Control connected to the string to IP VI as in the attached pic to retrieve the computer IP address and use it to find the presence of another equipement on Eth1 subnet,

 

Unfortunatly when the Eth2 cam is connected and configured the blank string control gives back the IP of the Eth2.

 

According to this page http://www.ni.com/white-paper/12558/en I have set the right configuration, but I still have this problem.

 

How can I force the soft to use the right NIC

 

I have also read this topic: http://forums.ni.com/t5/LabVIEW-Idea-Exchange/Allow-user-to-select-the-which-NIC-to-use-for-network/... and I don't understand why it has been rejected

 

Thanks a lot,

0 Kudos
Message 1 of 3
(2,914 Views)
Solution
Accepted by topic author Olivioloyer

Right click on string-ip and select multiple output. You should then be able to perform a check on the array to pull out the relevant IP address.

 

edit: Here's a way to show all the IPs as an array of strings. Probably not the most elegant or efficient way to do it though 🙂

show-all-IPs.PNG

Message 2 of 3
(2,902 Views)

Thanks it works

 

 

0 Kudos
Message 3 of 3
(2,874 Views)