|
-
August 7th, 2015, 07:16 AM
#9
Re: sendto sending UDP packets twice
Just throw out the second packet, you said you have a sequence number, so you know that packet was already processed. Its either that or better yet, you can implement modbus over UDP, or add some other protocol overtop like SCTP over UDP. OReubens is right about this. UDP is the wild wild west of uncontrolled network communications, raw speed and throughput like a wild mustang. Great if you want a fast stream of data such as a live video feed, but not so great if you want flow control and other features, since it is up to you to implement them. UDP definitely has its uses, but without work, precision isn't one of them.
Have a look at SCTP, there is stuff already out there that you can bolt on. Link to your project and run with it.
Last edited by ahoodin; August 7th, 2015 at 11:13 AM.
Reason: encourgement
ahoodin
To keep the plot moving, that's why.

Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|