LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem Sharing Variables between 2 machines

I am having problems trying to create a project that would share variables between multiple computers. I am using Labview 8.2.1 (I am new to 8.2.1 and Shared Variable).

here is what i did:
1. I created the project with Client and Server VI's and a library containing shared variables, which both of them call
2. I placed this project onto 2 computers (XP on a local workgroup, no firewall, see each other).
3.  On one of the computers I bound all shared variables to their counterparts on the other computer

The system is "almost working"

The problems are:
- I initially used wrong type variables for few items. I then modified the variables in both VI's and Shared Variable libraries and repeated the Steps 1-3 above.
But the sysrtem has some sort of a buffer somwhere, because it keeps bringing the old types of shared variables back (when I monitor them using Shared Variable Monitor).
- When I do binding to source, the system shows wrong variable types (for example DBL instead of U8).
- It takes almost a second to write and read shared variable (my network is quite fast)

I saw that the Labview Example with Server and multiple Clients uses 2 sets of shared variable and they bind - separate sets (different names) fro client and server within the same project. Do I have to do this or is this done just to simplify bindinga nd future distribution?

Is there a buffer/setup/file that I need to clear to get rid of "old" shared variable assignements? (I tried undeploy/deploy - does not help...)

Thank you very much,

Gleb.
0 Kudos
Message 1 of 3
(2,383 Views)

Hi Gleb,

 

It sounds like the shared variable is not getting completely undeployed from the shared variable engine.  I would recommend opening the shared variable manager and undeploying the library from there just to see that it is no longer in the engine.  Then, redeploy the library and rebind your variables to the host library that you have deployed.

 

It is not necessary to have different sets of variables for client and host.  The important part of the variable is what it is bound to, not necessarily what it is named.  So just undeploy your variable, double check the settings of the host variable, then redeploy using the variable manager and rebind your client variables. 

 

I hope this helps,

Brian Coalson

Software Engineer
National Instruments
0 Kudos
Message 2 of 3
(2,344 Views)

Thank you, Brian.

I tried that few times and it did not work. I decided that the SV library file may have somehow gotten corrupted (I don't understand what that means anyway). I have deleeted and crated a new SV library file, and now it works.

Thanks for help and suggestions.

Gleb

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