01-31-2008 03:06 PM
01-31-2008 03:10 PM
01-31-2008 03:18 PM
01-31-2008 04:08 PM
Hi Jordan
The problem is that I don't know where I could find DNS name. I tried to use DNS IP address, it does not work. The LabVIEW application I have consists of 2 parts. One is GUI part which run in a PC, another part runs in RT target. GUI part receives operator instruction, sends commands to RT and receives status/result continously from RT target. The communication between PC and RT target is through network shared variable. Are these network shared variables associated with RT target IP address?
Jason
01-31-2008 04:46 PM
09-27-2011 06:27 PM
Using the static IP address will fix the problem as many already suggested. However, of someone wants to use DHCP or even change static IP address, he also needs to change the IP address from the LabVIEW project as well. Using windows hosts file can solve the problem. The Hosts file is a common way to resolve a host name to an IP address through a locally stored text file that contains IP-address-to-host-name mappings. If you want to read more about hosts file, use the link http://technet.microsoft.com/en-us/library/bb727005.aspx
A hosts file looks the following
I have added the last line as 192.168.0.4 cRIO-Name. I used “cRIO-Name” as DNS name instead of IP address in the project(Actual IP Address 192.168.0.4). Everytime I need to change the IP addrss of my RT I also change the IP address in the hosts file. That way I don’t need to change the IP address in the project.
A very simple examle is given.
1. Read all IP and MAC addresses
2. Get the MAC address of the RT you are intersted in
3. Change the IP address
4. Open the hosts file located at “C:\Windows\System32\drivers\etc”
5. Read the file. Add or edit the IP address with DNS Name and close the file.