LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Will Shared Variable and Netowk Stream be obsoleted at Next NXG?

I'm developing an application using LabVIEW NXG 4.0.

I have one question, will Shared Variable and Network Stream be obsoleted in near future?

 

Why I have the concern is, those functions are listed in

Data Communication >> Compatibility

I don't know why the pallet has such name. If those functions are official, name of the pallet should be renamed.

If those will be replaced, I don't want to use those in my application.

 

 

In my experience, it was fact that the use of Network Stream had some difficulty,

so if new method will be implemented, it is really good new for me.

Certified LabVIEW Developer
There are only two ways to tell somebody thanks: Kudos and Marked Solutions

GCentral
0 Kudos
Message 1 of 13
(3,651 Views)

If I understood correctly: yes, both will be obsoleted in NXG.

 

Alternatives are promised.

 

As both are networking techniques (at least network bound SVs), the alternatives will be build more openly on those networking techniques already available. At least, that's how I got the message.

 

I'm not sure if automatically converting SV\networkstreams from CG to NXG is on the roadmap.

 

I also hope, but am sceptic, those new libraries will be classes. So if they don't do exactly what I want, I can make a child that does.

0 Kudos
Message 2 of 13
(3,584 Views)

Shared Variables are already replaced by the Tag API.  Based on meetings from many years ago, I believe NI plans to replace the Network Stream with a Stream API eventually.  It should look something similar to the Tag API.

 

Personally, I am not a huge fan of the Network Stream.  I just use the TCP/IP library and usually throw the STM library on top of it.

 

And I still say Network Published Shared Variables are evil.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 3 of 13
(3,548 Views)

@crossrulz wrote:

Personally, I am not a huge fan of the Network Stream.

And I still say Network Published Shared Variables are evil.


Couldn't agree more.

0 Kudos
Message 4 of 13
(3,544 Views)

As a CLA I shared the 'shared variables are evil' thought for years. I don't like them because it seems to rely on black magic. But, I have lab which has run for years with no issues using many shared variables. I have a test system using teststand that has not had a problem in 10 years and it is based on SV's. 

I'm using on a new project and the ease of use with distributed system manager is a great bonus. 

What are the  complaints, any horror stories to share? Thanks!

Will the replacement tag engine be a fit for purpose replacement? 

0 Kudos
Message 5 of 13
(3,538 Views)

@MichaelS78 wrote:

What are the  complaints, any horror stories to share?


Let's be clear that I am talking about Network Published Shared Variables.  I have had no issues with Single Process Shared Variables.  But I have had very interesting race conditions due to NPSVs (write the value and then read it and it is still the old value since the update has not been published).  My biggest issue is the lack of protection for the data (any computer can write to the variable, again causing interesting race conditions).  Every project I have been involved in that used NPSVs suffered from at least one of those conditions.

 


@MichaelS78 wrote:

I'm using on a new project and the ease of use with distributed system manager is a great bonus. 

Will the replacement tag engine be a fit for purpose replacement? 


The new Tags will work with System Link, which I think is also supposed to act as a replacement for DSM (I am not going to swear to that).



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 6 of 13
(3,527 Views)

@MichaelS78 wrote:

What are the  complaints, any horror stories to share? Thanks!

NBSV are globals on steroids. So everything that goes for globals, goes for SV. They're required for FPGA, but other than that, I avoid them.

 

I usually like to have full control, and SV are not that tame. They do as expected, but only if I lower my expectations.

 

Put them anywhere (like normal globals)! But there's no way to find them! See how that works in a (inherited) 3000 VIs application. **

 

I remember the "first read always gives an error" issue. The solution: to put a for loop around the read... Really? **

 

Where to put the SVE? c or PC? What if there are 5 PCs and 5 cRIOs? I really don't want to think about it. **

 

I like my libraries to make simple things easy, and hard things possible. Not easy things easy, hard things impossible. I really don't like the "take it as it is or DIY" character of SVs. DIY it is...

 

Honestly, I gave up on them pretty much immediately. Too complex for me.

 

** Not sure if this got fixed, but I gave up before that.

0 Kudos
Message 7 of 13
(3,508 Views)

Ah, i see. race conditions, hosting and finding, update delays etc...  I agree with all of those.  Thanks for the input.  This info (obsolesence) now gives me a kick in the right direction to move away from Data Dashboard and try out the new web module with tags.  Secureity is a big issue with NPSV's.  I wonder what will happen to DSC? ( I dont care that much, I have never used it)

 

0 Kudos
Message 8 of 13
(3,471 Views)

I'm very surprised my post caused heated discussion about SV and NS.

Of course I don't want to use both method actively on CG and NG. Both cause some unexpected trouble.

Especially NS, there is a lot of difficulty handling network endpoint.

I know global variable has been obsoleted in NG and replaced by Tag, it' good idea I think.

 

There is no alternative at the moment, right? The feature is not required in current but would be in the future.

what is the best way to share data over network. (low level function such as TCP/UDP....? NI doesn't have a plan??)

Certified LabVIEW Developer
There are only two ways to tell somebody thanks: Kudos and Marked Solutions

GCentral
0 Kudos
Message 9 of 13
(3,458 Views)

I don't know -- I had a LabVIEW RT routine that had four Network Streams -- two were Message Handlers connecting a Host QMH with a Remote QMH (so they could exchange Messages, like the Host telling the Remote to start a stimulus Sequence) and two "data" Network Streams, one for DAQmx continuous A/D from Remote->Host (started and stopped by Host->Remote Messages) and the other "Event" data from Remote->Host, which included such things as "Button Presses" and changes to DIO registers (Events consisted of Identifiers, enums, and a millisecond Time Stamp, basically the "real" time since the Remote routine started running).  Worked like a charm.  Was developed originally in LabVIEW 2010, finished in LV 2012.  I also tried to send some low-priority "occasional" information from Remote to Host via some Network Shared Variables, quickly gave it up as quirky and unreliable.

 

Bob Schor

Message 10 of 13
(3,443 Views)