LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Application using VI Server suddenly crashes. Why is it ?

Hi everyone !

I´m developing an application which makes extensive use ov VI Server. I´m going to give a short explanation of it before going ahead.

This application is supposed to run, simultaneously, on three different PCs, namely, ESTACAO_A, ESTACAO_B and ESTACAO_C, which share an Ethernet network. One feature of it is that it has a master / client architecture which means that, when one of the named PCs is the master, the others are the slaves. Anytime the user operating a slave PC can require command from that operating the master PC and, if this user acquiesces it, it becomes the new master.

This application communicates with an PLC using LabVIEW DSC and the master / client architecture was necessary because the application must run on three diferent computers, as said before, and each one of the slaves must monitor the state of the process under surveillance. That´s when VI Server gets in ! I found it was easier to implement this architecture using it than if I decided to use the TCP/IP VIs. The problem is that when I run the application on the PCs ESTACAO_A and ESTACAO_B only, ESTACAO_A and ESTACAO_C only and on the PCs ESTACAO_B and ESTACAO_C it works quite well but, when it is executed on the three PCs, and the user of ESTACAO_B requires to become the master, sometimes the application will crash on ESTACAO_B, and that will make the application crash on the other two PCs, since they won´t be able to communicate with the PC which was supposed to become the new master, in this case, ESTACAO_B. For the sake of information I tell you that when I ping the other machines on ESTACAO_B it takes a longer time to respond than that taken when I ping the other machines on ESTACAO_A and ESTACAO_C. I´m beginning to think it has something to do with it.

Any help will be deeply appreciated.
0 Kudos
Message 1 of 3
(2,517 Views)
Hi,

I had run into something similar with my labview application. My application was running on two different PCs but failed whenever I had to switch one of the PCs from master to slave. The two PCs were communicating over the ethernet network and I was using VI server in my application.

One of the PCs was set to braodcast and the other was set to read the data braodcast by the other PC. These settings were done using the windows network settings for the IPX/SPX protocol used by the hardware in my application and whenever the PC broadcasting the data was told to read the data, the application crashed.

I suspect someting similar happening with your application.
For example, assume A is reading while B and C are broadcasting. When you change B from slave to master, the network settings are still probably set to broadcast while it is supposed to be set to read.

So checking your network settings might help in finding a solution to your problem.

deepak
0 Kudos
Message 2 of 3
(2,504 Views)
Thanks a lot for your interest in helping me marooner but, what do you mean when you suggested me to change the network settings ? I see I can change some TCP/IP settings, such as IP address, subnet mask, default gateway, DNS, etc but nothing related to the parameters you talked about.

In my application one of the machines is the master while the other ones are the slaves. The slave machines use VI Server to read the values of the controls and indicators of the application running on the master machine, controls and indicators that correspond to variables of the process under surveillance; to change the value of a variable on the master application that indicates which one of the slave machines requested command of the process and to identify which one of the three machines is the actual master. The master uses VI Server to run the applications running on the slave machines and to stop its execution, by changing the state of a variable which controls the While loop of the implemented state machine, because the Tag Engine can only be stopped if an application which uses it is stopped.











.

PS :

The Windows version of the machines is Windows 2000.
0 Kudos
Message 3 of 3
(2,488 Views)