LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VI server vi stops working after build

I have a VI that is written to run on two stations, and allow them to share lasers.  When a station wants to use a laser, it checks the front panel of the other station to check the status of the control for that laser.  This works fine as a VI.  When I build it into an EXE, it no longer works.  I get a "connection refused by the server" error.  The ini file shows that the "server.tcp.access=" property has the ip address of both PCs.  The "share" global in the attachment holds the ip address of the PC to be checked.  The "ServerPort" global has the port that the other PC is configured to use in the VI server:configuration.  Since both PCs are running the same EXE, I manually change the server configuration on one of them after starting the program.  I am stumped.
Jim

LV 2020
0 Kudos
Message 1 of 7
(3,121 Views)
Your problem is that the Viserver doesn't allow the client machine to connect,
you have to copy the following line (server.tcp.acl=) from the Labview.ini file and copy in the ini file of your executable.
 
Example :
server.tcp.acl="290000000A000000010000001D00000003000000010000002A10000000030000000000010000000000"
 
 
0 Kudos
Message 2 of 7
(3,103 Views)

Hi Florent,

Thanks for the suggestion.  Unfortunately I have no " server.tcp.acl= " entry in the ini file on any of my systems.  I tried yours, and it didn't work.

Jim

LV 2020
0 Kudos
Message 3 of 7
(3,093 Views)
Jim,

Make sure you have these entries in your INI file:

[App Name]
server.tcp.enabled=True
server.tcp.access=+*
server.tcp.port=8363

where App Name is the name of your EXE without the .exe.

The access and port can be different.  The above entries allow all addresses on port 8363.

Be aware of the fact that if LabVIEW is using the same port number and is open when your EXE starts, the TCP/IP VI Server will not function, as LabVIEW already has the port open.
Message 4 of 7
(3,087 Views)

Hey Matthew,

I don't know what happened.  I know those entries were there at one point, but when I just looked they were gone.  I put them in, and it now appears to work.  One of the KB articles that I  read said that I would have each PC configured to a different port, but right now I have them both on the default 3363 and it appears to work.  Any idea if I should expect future woes with them both on the same port?  And thank you both.

Jim

LV 2020
0 Kudos
Message 5 of 7
(3,078 Views)
As long as they are on differnt PCs, it should be fine.


0 Kudos
Message 6 of 7
(3,073 Views)
Cool.  Thanks again.
Jim

LV 2020
0 Kudos
Message 7 of 7
(3,071 Views)