CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

Hand Shaking in TCP IP

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
2b



Joined: 21 Nov 2007
Posts: 2

View user's profile Send private message

Hand Shaking in TCP IP
PostPosted: Wed Nov 21, 2007 9:18 am     Reply with quote

Hi. I'm very new in communication with TCP/IP protokol and I have a question:
I have a system having a computer and a device that controlled by 18F4620 and communicate over ENC28j60. I'm trying to learn CCS TCP IP samples. How this device colud know that the computer received the message that sent by the device?
Douglas Kennedy



Joined: 07 Sep 2003
Posts: 755
Location: Florida

View user's profile Send private message AIM Address

PostPosted: Wed Nov 21, 2007 2:33 pm     Reply with quote

The packet structure for TCP/IP is in the public domain...a google search should get you what you need. Basically TCP/IP calls for sequence numbers both for the sender and the receiver. The sequence numbers are incremented by the number of bytes in a packet more or less its a bit more complicated since some additional info is also counted. If the receiver got the packet its reply will have the expected increase in sequence number. TCP/IP allows for packets to be received out of sequence but the PIC stack doesn't take care of this. It's rare packets come out of sequence so the code often works.
2b



Joined: 21 Nov 2007
Posts: 2

View user's profile Send private message

PostPosted: Thu Nov 22, 2007 3:21 am     Reply with quote

So you mean i have no need to controll the receiver received the message. if a sender sends its message while connected to receiver, the receiver exactly gets this message. Is it true?
Well, how the PIC stack acts after if the network cable cut off or network socket plugged off while transmission? Does the PIC stack allert any message?

Well, i have another question about UDP. Does any collusion occur, if multiple nodes start to send UDP message to a server node?
Douglas Kennedy



Joined: 07 Sep 2003
Posts: 755
Location: Florida

View user's profile Send private message AIM Address

PostPosted: Thu Nov 22, 2007 10:35 am     Reply with quote

Well TCP/IP has a fair bit of complexity so it makes simple does it or doesn't it type questions inefficient in transferring information about the essence of the protocol. You will need to read up on this to gain an understanding. The sender knows that the receiver got the payload if it replies with the appropriated increased sequence number. A timeout is often used to decide between a busy receiver and a broken connection. The protocol itself doesn't expect collisions due to the fact it relies on a lower layer the MAC layer (Ex. ethernet) it is that layer which is closest to the hardware that will make the allowance for collisions.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group