acknowledgement question

Thread Starter

bug13

Joined Feb 13, 2012
2,002
Hi guys

I have a question regarding acknowledgement (ACK) between two devices. So my question is: How to tell the ACK is received?

Say I have a Master and a Slave, they need to communicate. That's what would I am planing to do:
Master: send a stream of message with CRC.
Slave: received message and replay with ACK.

So how can the slave tells the master has received the ACK? I can't get the master to reply with another ACK, because if I do, they will go on forever. So how do we handle a situation like this?

Thanks guys!!
 

djsfantasi

Joined Apr 11, 2010
8,396
Are you there?
I'm here and got your question!
Here's my message for you.
I'm here and got your message!
I'm done...
I understand

From the sender's point of view, for each transmission it requires a response (ACK). Sometimes, it takes a few times to "synchronize the communications"... If the sender receives an "I don't understand" (NAK), it retries its last operation.

Are you there?
I don't understand
Are you there?

I don't understand
Are you there?

I don't understand
Are you there?
I'm here and got your question!
Here's my message for you.
I'm here and got your message!
I'm done...
I understand

There are several protocols for communications. That was taken from a description of serial communications and generalized from TCP/IP handshaking. XON/XOFF protocol is similar as well.
 

Papabravo

Joined Feb 24, 2006
18,839
In general:
  1. The receipt of a NAK causes re-transmission.
  2. The lack of an ACK causes re-transmission after a timeout interval.
  3. The receipt of an ACK allows the transmission of the next packet.
 
Top