2.2.3 Frame Format, NACK Frame

NACK, or Negative Acknowledge, frames specify which data frames were expected but were not received by the receiving end of the link. Messages that are not sent reliably MUST NOT generate a NACK.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

flags

extended flags (optional)

messageid

sequence

bytes received

local tick count

NACK MASK (variable)

...

flags (1 byte): A bitmask that contains values from the following table that are combined using the bitwise OR operation.

Note For a description of how these flags determine the frame type, see section 2.

Value

Meaning

0x80

(EXT or EXTENSION) Indicates that the extended flags field is present.

0x40

(BIG) Indicates that big frame format is used. This value MUST be 0 because the big frame format was never implemented.

0x20

(CMD or COMMAND) Indicates that this is a Data Frame. This bit MUST be set for Data Frames. If the EXT bit is also set, the packet MUST be ignored.

0x10

(STA or START) Indicates the start of a message that can span multiple protocol frames.

0x08

(EOM or END OF MESSAGE) Indicates the end of a message that can span multiple protocol frames.

0x04

(SAK or SEND ACKNOWLEDGE) Specifies a request for immediate acknowledgment after this frame is received.

0x02

(ACK or ACKNOWLEDGE) Acknowledges receipt of some frames; might specify the nonreceipt of frames if the extended flags are present.

0x01

(RLY or RELIABLE, ~UNRELIABLE) Indicates that the message is reliable if set and unreliable if not set.

extended flags (1 byte): This field is optional. It is present if the EXT bit is set in the flags field.<5>


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

COMMAND

nNACK

0

COMMAND (5 bits): MUST be 0x00.

nNACK (2 bits): The size, in bytes, of the NACK MASK.

Value

Meaning

0x00

There is no NACK MASK present.

0x01

There is 1 byte of NACK MASK present.

0x02

There are 2 bytes of NACK MASK present.

0x03

There are 3 bytes of NACK MASK present.

0 (1 bit): MUST be 0.

messageid (1 byte): The messageid from the sent data frame.

sequence (1 byte): The sequence ID from the sent data frame. The sequence uniquely identifies which is the first nonreceived frame.

bytes received (4 bytes): Specifies the total number of bytes received on the link at the time that this NACK frame was sent.

local tick count (4 bytes): Specifies the tick count on the local tick clock when the NACK frame was sent.

NACK MASK (variable): A NACK MASK is sent in any message header when packets expected to be in the message stream are not received. The mask of bits specifies which packets have not been received by the receiver.

Creation of the mask is based on the sequence number in the NACK packet, which identifies the first packet that was not received. The bits in the NACK MASK bitmask specify which other packets relative to that sequence number have also not been received. For example, if the sequence number is 7 and the NACK MASK is 0x03, then packets with sequence numbers 7, 8, and 9 have not been received at the receiving end of the link.

The size of the NACK MASK is specified in the nNACK bits of the extended flags field, if that field is present. When nNACK is greater than 0, there is a NACK MASK. When the extended flags field is not present, there is no NACK MASK field.

The NACK MASK field is optional.<6>