BreakPoint

cancel
Showing results for 
Search instead for 
Did you mean: 

Remote queue, TCP, shared variable >> comparison table

Hi all !

I saw a couple of threads here and there talking about the best way to pass data/commands between a host PC and a RT target.

LV 8 brought shared variable but apparently, they are not "fast" enough to transfert fast data and TCP appears more efficient.
I heard about Remote Queue, an OpenG subpalette for LV 6, but I could find it in the list for LV 7.1.

My final aim is to draw a table like this :

Communication technique :      Advantages :      Weak point/Limitations :      Typical "sensible" use :
remote queue (OpenG, any LV)   ...                           ...                                             ...
shared variables (Lv8)                  ...                           ...                                             ...
TCP
...

Any feedback, thoughs, comments are very welcome !


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

Message 1 of 9
(8,642 Views)

Add to your list VI Server calls.

They have woked very well for me in a bunch of applications.

Typically I'll make "call by reference" calls to an action engine of some type.

I think of them as "TCP/IP" but I let LV handle the session data conversion etc.

They are well suited for changing PID values on the fly.

I suspect they would place below TCP/IP transfers that use an optimized packet size but otherwise they are pretty quick.

Draw backs are you have to understand VI server calls and manage the serving and addressing of the remote calls.

Ben

PS This technology works back to LV 5.1.

PPS Rule out UDP. That is like trying to talk to your boss by using grafetti on busses. Sure the message may get through but you are never really sure.

Message Edited by Ben on 09-04-2006 03:17 PM

Message Edited by Ben on 09-04-2006 03:19 PM

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 2 of 9
(8,632 Views)
Ok, thanks for this Ben.
I'll try to find time to benchmark these techniques and will post the results 😉

Just to know, has anybody ever done such tests Smiley Surprised ?



Ben a écrit:

PPS Rule out UDP. That is like trying to talk to your boss by using grafetti on busses. Sure the message may get through but you are never really sure.



Nice image Smiley Very Happy


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

0 Kudos
Message 3 of 9
(8,602 Views)
Hello all,

Sorry to come back here so late, I've bee quite busy these days Smiley Sad

I still haven't tested everything I wanted but here is a sum up of the feedback I received from a few friends LV developpers :

Remote Q :
    Advantages : not to long to set-up, very handy to manage large amounts of data (much faster than an array !)
    Weak point : VI sever is "dodgy" in multiplatform
    Possible use : manage very large arrays, transfert orders/requests between RT and host

Shared Variables :
    Advantages : Integrated, really easy to develop
    Weak point : "still wet" (means that it needs to be more stable), not really fast > was tested in LV 8.0.1 and not in LV 8.20
    Possible use : transfert data between host and RT at "low" rate, transfert orders/requests

TCP :
    Advantages : Fast, stable, multiplatfrom
    Weak point : Requires quite a bit of code compared to other techniques
    Possible use : Transfer lots of data as fast as possible

VI-Sever calls :
    Advantages : Quite easy to set up, works in LV 4 and maybe even before
    Weak point : VI sever is "dodgy" in multiplatform, references have to be updates everytime you modify the VI that exchange data
    Possible use : Transfer data at "low" rate, transfert orders/requests from host to RT


To be continued... If anybody wants to add a method, an idea, some results or feedback, feel free !

NB :
I haven't performed all the testings myself, some results above are based on the feedback from co-workers and friends developer, many thanks to them !


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

Message 4 of 9
(8,441 Views)
I've just received that one, I haven't tested it myself, I only used it to programmatically reboot a cFP runninng in RT mode from a host PC (see here).


DataSocket :
    Advantages : really easy to set up
    Weak point : you don't really know how it works...
    Possible use : Transfer an image from a CVS to a Host PC


We have two ears and one mouth so that we can listen twice as much as we speak.

Epictetus

Antoine Chalons

Message 5 of 9
(8,419 Views)
I've been performing tests in LV 8.5 to test this exact thing but am only looking at shared vars and TCP.  From what I've seen so far, TCP seems to be much more stable but requires a string data type to be sent over which results in much larger model architectures.  This is the main reason why I've been exploring Shared Variables in the hopes I would see faster loop back times.  I've set up the attached vi but, unfortunately, the times are still random with a large standard deviation for the sample population I used (n=20).  Can someone check my method and see if there's a better way to set this up?  It's a very simple test that only requires that:
 
1.  Send over Boolean to client
2.  Indicator activated client-side to show Boolean was sent over
3.  Send Boolean back to server.
4.  Calculate loop time.
 
I used the tick counter block to calculate the loop time.  You get one tick count at the start of the vi and then the second tick once the signal is sent back.  Subtract the two and you have your loop time.  Is there a better way to do this?  Thanks.
0 Kudos
Message 6 of 9
(7,115 Views)

Ben--

 

Any chance you have an example or reference to demonstrate the comment you made long ago?  You said , "Draw backs are you have to understand VI server calls and manage the serving and addressing of the remote calls."  What should us newbies know to use this approach?

 

Thanks.

0 Kudos
Message 7 of 9
(6,361 Views)
You can see a simplistic example here. Note that you will have to enable VI server TCP access in the Options dialog or in the INI file.

___________________
Try to take over the world!
0 Kudos
Message 8 of 9
(6,346 Views)

STM:

Advantage: Simple to use, Powerful

Disadvantage: Messagebased => can only transfer data in predefined messages

 

Example for "how to use STM": In-Vehicle Datalogger Reference Architecture for CompactRIO

 

hope this helps,

Norbert 

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
Message 9 of 9
(6,334 Views)