From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

transmitting multiple queues on tcp/ip protocol

hello everyone,

i am stuck at somepoint please guide me for the said matter

what am i doing is , i have multiple VI's having data in string format and i put that data in a queue for each VI, and all these VI's are running on the same machine.now i have successfully received that data in an other VI and dequeue that data. lets call this VI as dequeue.vi again running on the same machine.

now what my objective is to  implement a tcp/ip connection in the dequeue.vi 

and send those acquired multiple queues over this tcp/ip connection. 

now here are my questions

1. is there a possible wayout to implement multiple queue transmission over single tcp open connection and subsequently tcp write function. if yes then i need ur valueable guidence

2. this is going to be 2 way client model which will get data from multiple queues and then send these queues priodically to some other server running on the other machine.

3. is there any other relaible and suphisticated data transfer protocol between VIs running on same machine.jusy like queues and network streams.

may be i am not much good to explain but u can ask if u dont understand my point.

thanks in anticipation

0 Kudos
Message 1 of 10
(3,406 Views)

1/2. I assume you can e.g. Prepend your message with queue name to identify where they should land on the target side. Since you're making the program you'll have to decide on how your messages will be formed.

3. Can't Network streams be used between separate programs? Network shared variable is a possible, but probably bad option. Else you've mentioned them all, unless you start looking at 3rd party solutions, like RabbitMQ, which is a network queue solution.

/Y

 

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
Message 2 of 10
(3,353 Views)

In my blog "Reach Out and Touch Some VI" (found here)...

 

Touch_a_VI.jpg

 

I talk about how to use VI Server to handle cross platform connectivity. I include figure 18 from that blog below.

 

Fig18_Cross_Platform_Queue.jpg

 

I will not repeat what I wrote there but I invite you to consider using VI Server.

 

 

Spoiler

Yamaeda,

I was away on vacation or maybe just asleep but that is a new look for you is it not?

 

 

 

 

Ben

 

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 3 of 10
(3,333 Views)

@Ben yes, the helmet was getting too common so i decided to upload one of my favorite goat pictures. 🙂

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
Message 4 of 10
(3,320 Views)

Many, many years ago I found this coded posted either here or on LAVA. Over the years I have made some improvements. This is a network queue which works identical to the native queue but works over TCP.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 5 of 10
(3,287 Views)

hello mark, i am really sorry to inform u that ur posted VI is in LV 18 whereas i am working on LV 12 due to which ur VI can not be opened in my LV. so please if u have some older version then either share that  with me or give me solution to open these VI in my current version. 

Regards

0 Kudos
Message 6 of 10
(3,251 Views)

thanks ben, but if u pin point my questions then it would be a great favor. because i think u have understood my problem and u can guide me in righr direction with ur valueable suggestions.

0 Kudos
Message 7 of 10
(3,247 Views)

@hassan2019 wrote:

thanks ben, but if u pin point my questions then it would be a great favor. because i think u have understood my problem and u can guide me in righr direction with ur valueable suggestions.


I am not sure what you are trying to say.

 

VI server goes way back to at least LV 6i. What I wrote about in that blog was more of a reminder of what has been available for a long time.

 

Not that I claim to be wise but the quote;

 

"A wise man goes into his storehouse and brings forth treasures both old and new."

 

VI server is the "Old treasure".

 

Ben 

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 8 of 10
(3,223 Views)

@hassan2019 wrote:

thanks ben, but if u pin point my questions then it would be a great favor. because i think u have understood my problem and u can guide me in righr direction with ur valueable suggestions.


Please read this message

Message 9 of 10
(3,216 Views)

Here you go. You may need to fix a couple of VIs. I have updated the version of the VI that I use to set disable the Nagle algorithm on the TCP connection. I am not sure if the updated version works in LV 2012 so I also included a copy of the old version. You would just to need to replace the TCP_NoDelay VI in three of the VIs in the Network Clue class.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 10 of 10
(3,203 Views)