LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

TCP Read/Write

Hi,
 
How TCPread and TCPWrite VIs work?
 
Does TCPread VI send Ack after receiving the  data? And does TCP send VI wait for the Ack for sending the next packet?
Or those Acks should be handled outside the VIs?
 
 Do they handle Ack number and seq numbers?While sending, what Ack and Seq Numbers TCPWrite use? Is it from recently received packet?
 
 
0 Kudos
Message 1 of 11
(4,332 Views)

Your interaction with the TCP primitives is on the application layer, so you have no option of handling the TCP implementation details. I'm not even sure whether LV or the operating system is the one responsible for handling the TCP implementation, but in any case, you should not have to worry about it. You can have a look at the TCP examples in the example finder to see how it works. If you have a specific problem, supply more details.

To learn more about LabVIEW, I suggest you try searching this site and google for LabVIEW tutorials. Here, here, here, here and here are a few you can start with and here are some tutorial videos. You can also contact your local NI office and join one of their courses.
In addition, I suggest you read the LabVIEW style guide and the LabVIEW user manual (Help>>Search the LabVIEW Bookshelf).


___________________
Try to take over the world!
0 Kudos
Message 2 of 11
(4,321 Views)

Hi..

I am using FPGA and PC as two ends of TCP/IP communication. On PC side I am using these VIs.

I am sending the data from FPGA and I am waiting for the Ack. After I get the Ack,  I am sending the second the next data.

So, I need to know whether TCPread VI  will send Ack for every received data.If it is not sending the Acks, Ineed send Ack  by using TCPWrite VI.

In that case, the Ack I am sending sholuld be like reply. so, I should take care of seq Num and Ack num. If TCP write take care of these numbers depending on previous received data, I can send the ACk, using TCP write VI.

That is the problem of mine.

 

 

 

0 Kudos
Message 3 of 11
(4,316 Views)

I did not understand your actual problem, but in any case, you don't have to manage the actual TCP communication details. This is done either by LV or the OS. You just need to send your data on one side and read it on the other side. Again, have a look at the examples to see how this is done.

Of course, if you have a message based protocol and you want to make sure that messages (not TCP packets) arrived, then you will have to manage that as well.


___________________
Try to take over the world!
0 Kudos
Message 4 of 11
(4,313 Views)

II am sending the data from FPGA and I am waiting for the Ack to send the next data.

So, I need to know whether TCPread VI  will send Ack for every received data.

Can I get this clarified?

0 Kudos
Message 5 of 11
(4,309 Views)

I am sending the data from FPGA and I am waiting for the Ack to send the next data.

So, I need to know whether TCPread VI  will send Ack for every received data.

Can I get this clarified?

0 Kudos
Message 6 of 11
(4,311 Views)
This is just a link to the start of the origional post thread for 080 5120 8600.
Read here to get the origional question...
 
080 5120 8600, now that the question is on the correct board, you should get more help to these questions that have started to get beyond my experience.
0 Kudos
Message 7 of 11
(4,301 Views)
As stated earlier, the LabVIEW TCP Read VI does not directly interact with the Ethernet port on the PC, but only passes data to and receives data from the network driver/stack on your PC.
 
As such all low level details of the network traffic including sending the ACK is handled by the network driver. The network driver will receive a message/segment from the FPGA, and automatically send the ACK. It then places the data from the message/segment into a buffer. The next time you call TCP Read in LabVIEW, the driver retrieves the data from the buffer and returns it to LabVIEW.
authored by
Christian L, CLA
Systems Engineering Manager - Automotive and Transportation
NI - Austin, TX


  
0 Kudos
Message 8 of 11
(4,282 Views)

Thanks for the information.

Should I handle any timing issues here?

 

0 Kudos
Message 9 of 11
(4,257 Views)
I'm not sure what you mean by 'timing issues'. Can you elaborate what you are concerned about.
authored by
Christian L, CLA
Systems Engineering Manager - Automotive and Transportation
NI - Austin, TX


  
0 Kudos
Message 10 of 11
(4,197 Views)