05-17-2007 07:13 PM
Method of Control.
National Instruments recommends using front panel data binding through the Shared Variable Engine or using the Bind To Network Path method to attach a data connection to a control.
This method allows you to attach a dstp, opc, ftp, http, or file connection to a control. You can add new connections only at edit time. This method is similar to the Data Binding Selection, DataSocket URL, and Mode options on the Data Binding page of the Properties dialog box.
=============
Maybe anyone has found trick to avoid this restriction
The same question for shared variable.
Also I don't understand where can I uses this method?
05-18-2007 09:49 AM - edited 05-18-2007 09:49 AM
Message Edited by Travis M. on 05-18-2007 09:50 AM
05-18-2007 10:04 AM
05-18-2007 02:07 PM
05-18-2007 05:20 PM
Agh ... there is something ... but lets do that more clearly. Acually there are 5 actions. Create variable in DataSocket server, write into variable by my server and client, read from variable by my server and client.
1. My server prepares variables in DataSocket server. I can use the same vi with DataSocket Open.vi I will call some times with slightly different Names (like, dstp://localhost/dev1_wave, dstp://localhost/dev2_wave and so on) and I will have variables in DataSocket server. I hope until I will not close (I suppose - last?) connection DataSocket server will hold variable. But what about connection status - disconnected? How much time does disconnection/reconnection eat?
So I can easy initialize some set of similar variables using just one vi.
2. I don't see problem with server or client writing. I will save Connection ID as string in object and use it.
3. It looks there is not problem with client reading. I can simple read by polling. But also I can catch event when variable value of client's front panel changes. To do that I will change URL.
4. At last moment, server reading. Again polling is not problem. But if in this moment vi connects to dev1_variables then dev2_variables are not connected. So events are losted. And I suppose there is not solution for that?