LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why would the 'STR to IP' function only find the first 4 ip network addresses? Is there any other way to list all the local IP addresses?

Solved!
Go to solution

Are you able to try the microsoft.com example?  Does it work as expected?

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 11 of 17
(1,318 Views)

Hi Bill, I could try to connect this RT PXI to our corporate network to do the microsoft.com test. I would need to set up proxy server details on the pxi somehow (not sure how to do that yet). Or i could take the box home and try it on my home network. But say it does return more than 4 addresses, what does that tell us?

Ideally someone out there with a PXI running RT has more than 4 ethernet ports and could check the behaviour of the str to ip function?

0 Kudos
Message 12 of 17
(1,304 Views)

@AnthonV wrote:

Hi Bill, I could try to connect this RT PXI to our corporate network to do the microsoft.com test. I would need to set up proxy server details on the pxi somehow (not sure how to do that yet). Or i could take the box home and try it on my home network. But say it does return more than 4 addresses, what does that tell us?

Ideally someone out there with a PXI running RT has more than 4 ethernet ports and could check the behaviour of the str to ip function?


We've already established that the function can return more than four addresses, that much is true.  But establishing that it can or cannot do it within the environment that you are using it in can be very valuable as a troubleshooting starting point.  If you can generate a table showing when it works and when it does not, you can start establishing patterns, and the patterns usually lead you to the root cause of the issue (eventually).

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 13 of 17
(1,297 Views)

Windows 7 x64 LabVIEW 2015 SP1 32-bit returns 5 on my machine for localhost (nothing wired to name just like Altenbach's example) several are virtual adapters.

0 Kudos
Message 14 of 17
(1,278 Views)
Solution
Accepted by topic author AnthonV

Thank you everyone for the suggestions so far.  However I've found an alternative solution to using 'STR to IP'.  I am hoping that someone else will be able to test 'STR to IP' on a RT system with >4 ethernet ports to determine whether it is simply my system causing the unexpected behaviour or if it is a bug in 'STR to IP'.

The alternative solution is to use the example code found in 

C:\Program Files (x86)\National Instruments\LabVIEW 2016\examples\nisyscfg\Network Settings Viewer.vi.

I've successfully tested this on Windows as well as RT.

Message 15 of 17
(1,267 Views)

Glad you found a workaround. There is no LabVIEW limitation on the number of addresses returned by that method on any platform. If the list is being truncated this is most likely happening somewhere in the Pharlap network driver. I spoke briefly with the maintainers of that component and they were not aware of this issue so I filed them a defect report so that this gets followed up on.

Message 16 of 17
(1,251 Views)

@AnthonV wrote:

Thank you everyone for the suggestions so far.  However I've found an alternative solution to using 'STR to IP'.  I am hoping that someone else will be able to test 'STR to IP' on a RT system with >4 ethernet ports to determine whether it is simply my system causing the unexpected behaviour or if it is a bug in 'STR to IP'.

The alternative solution is to use the example code found in 

C:\Program Files (x86)\National Instruments\LabVIEW 2016\examples\nisyscfg\Network Settings Viewer.vi.

I've successfully tested this on Windows as well as RT.


Don't forget to mark your post as the solution so you can save some poor developer some heartache in the future.  😉

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 17 of 17
(1,247 Views)