LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Shared variables on Mac and Linux

Are shared variables supported on Mac and Linux? I saw a thread from 2006 in which people were saying they are not, but I was hoping this functionality would have been implemented by now.

I basically want to port my application to both Mac and Linux but currently it uses shared variables.

 

If they are not supported, how can I use datasocket? I seem like the publisher always has to be running if the client wants to read the published data. Is there any way to simply publish something on the server and it is available even when the publisher stops working?

0 Kudos
Message 1 of 9
(4,877 Views)
The Datasocket API supports NI-PSP on Linux and Macintosh (since LabVIEW 8.5 i think) but hosting of shared variables is still not supported on these OS's.

abdel2 wrote:

If they are not supported, how can I use datasocket? I seem like the publisher always has to be running if the client wants to read the published data. Is there any way to simply publish something on the server and it is available even when the publisher stops working?


No, that's not possible. Because of which it is necessary to host the Shared Variable Engine on a system that is always online. I would recommend that you go through the following document; probably one of the best documents on shared variables:

Using the LabVIEW Shared Variable

Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
0 Kudos
Message 2 of 9
(4,860 Views)

So there is no way to host data on Mac or Linux? I can't use a window or RT system to host shared variables because I want the Mac or Linux to be a standalone system that will support my application.

 

I guess the only other way is to implement a custom TCP/IP server that can HOST data rather than just pass data from publisher to subscriber?

 

0 Kudos
Message 3 of 9
(4,849 Views)

Perhaps if you tell us more about your application, someone can offer a solution which will work on Mac and Linux.  What is the source of your data? How much data is generated and how fast? Is the data shared among separate applications or separate VIs within one application?  One or multiple computers?

 

Lynn 

0 Kudos
Message 4 of 9
(4,846 Views)

The application has two main components: control and data acquisition. The control always runs on the host computer (Windows/Mac/Linux) but data acquisition can either run on the same OS or a RT target.

 

I am developing add-on modules for the application that can be implemented in it. A simple module would be one that has two Vis. One runs on the host computer to change its settings. Other Vi runs on the RT target and uses the new settings to do stuff. Now I need a way to shared data between these two Vis. I could use data socket but settings vi would always have to be running as long as Vi on the RT target is running. I am trying to find a way so the settings can be saved somewhere so the other Vi can access them.

0 Kudos
Message 5 of 9
(4,839 Views)

I just did some more reading on Datasocket and it looks like datasocket server is only available on Windows in Labview 8.5. Is it still the same for the latest version (8.6)?

Other than TCP and UDP, is there any sort of built in data sharing method that works for all the platforms and doesn't require Windows in addition?

0 Kudos
Message 6 of 9
(4,826 Views)

Hi abdel,

 

Datasocket is supported in LabVIEW 8.6 and on Linux and Mac. But shared variables are still not supported on those OS.

Sorry, but nothing else beyond TCP and UDP is supported on Linux and Mac.

0 Kudos
Message 7 of 9
(4,794 Views)
Does it mean I can run datasocket server on Mac or Linux?
0 Kudos
Message 8 of 9
(4,785 Views)
Unfortunately, no. The DataSocket Server was built on Active X technology which is Windows-based. Therefore, the server is only available for Windows environments.
0 Kudos
Message 9 of 9
(4,768 Views)