Вы находитесь на странице: 1из 8

SYNCHRONOUS DATA-LINK CONTROL (SDLC) FRAME FORMAT

There are three frame formats:


1. Information
2. Supervisory
3. Unnumbered

THE CONTROL FIELD

The control field is an 8-bit field that identifies the type of frame (Information, Supervisory, Unnumbered) being
transmitted. The control field is used for polling, confirming previously received frames, and several other data-link
management functions.

1. Information Frame – there must be an INFORMATION FIELD


Control Field 8-bit format: b0 b1 b2 b3 b4 b5 b6 b7

nr P/P ns 0
or F / F

b0 b1 b2 nr – number received
- From 000 to 111 (frame 0 to frame 7)
- used to confirm frames received without errors
- automatically request retransmission of information frames
received with errors
- indicates the number of the next information frame the
transmitting station expects to receive
ex. nr : 011 – may mean one of the following:
- the station received frame 2 without error
- the station is requesting the retransmission of frames from
frame 3 (because the last frame received without error is
frame 2)
- the station is expecting to receive frame 3 (because it has
received frame 2 without error detected)

b3 P/P or F/F
Poll or not-a-Poll, if frame is from Primary
- If b3 is logic 1, it is a Poll – primary is requiring response
from secondary
- If b3 is logic 0, it is not-a-Poll – primary is not requiring a
response from secondary
Final or not-a-Final, If frame is from Secondary
- If b3 is logic 1, it is a Final – secondary is sending the final
frame
- If b3 is logic 0, it is not-a-Final – secondary is not (yet)
sending the final frame
b4 b5 b6 ns – number sent
- From 000 to 111 (from frame 0 to frame 7)
- Indicates the frame number (all information frames must
be numbered)
- The first frame will have ns: 000, the second frame will
have ns: 001… the eighth frame will have ns: 111 then the
count returns to 000
b7 0 (logic 0)– to indicate that the frame is an Information Frame

Example: (from Tomasi, the same image given in DLC 3 Slides)

The image shows the exchange of information frames between Primary Station and Secondary Station. From the figure
Primary Station transmits first with 3 frames.
Re-writing the Control field : 0 0 0 0 0 0 0 0
b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=000 – this is frame 0 from Primary station
b3 : 0 – not-a-Poll, the Primary is not (yet) expecting a response from secondary
b0 b1 b2 : nr=000 – the Primary station is expecting frame 0 from the secondary

Re-writing the Control field : 0 0 0 0 0 0 1 0


b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=001 – this is frame 1
b3 : 0 – not-a-Poll, the Primary is not (yet) expecting a response from secondary
b0 b1 b2 : nr=000 – the Primary station is expecting frame 0 from the secondary
Re-writing the Control field : 0 0 0 1 0 1 0 0
b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=010 – this is frame 2
b3 : 1 – Poll, the Primary is expecting a response from secondary
b0 b1 b2 : nr=000 – the Primary station is expecting frame 0 from the secondary

Since this is a Poll frame, the Primary station stops transmitting and waits for the response of the Secondary station.

This is now the response of the Secondary station:

Re-writing the Control field: 0 1 1 0 0 0 0 0


b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=000 – this is frame 0 from the Secondary station
b3 : 0 – not-a-Final, this is not (yet) the final frame from Secondary station
b0 b1 b2 : nr=011 – the Secondary station is expecting frame 3 from the Primary Station
Secondary station received previous frames until frame 2 without error
Re-writing the Control field: 0 1 1 1 0 0 1 0
b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=001 – this is frame 1 from the Secondary station
b3 : 1 – Final, this is the final frame from Secondary station
b0 b1 b2 : nr=011 – the Secondary station is expecting frame 3 from the Primary Station
Secondary station received previous frames until frame 2 without error

Since this is a Final frame, the Secondary station stops transmitting and waits for the response of the Primary station.

Re-writing the Control field: 0 1 0 0 0 1 1 0


b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=011 – this is frame 3 from the Primary station
b3 : 0 – not-a-Poll, the Primary is not expecting (yet) a response from the Secondary station
b0 b1 b2 : nr=010 – the Primary station is expecting frame 2 from the Secondary Station
Primary station received previous frames until frame 1 without error
Re-writing the Control field: 0 1 0 1 1 0 0 0
b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=100 – this is frame 4 from the Primary station
b3 : 1 – Poll, the Primary is expecting a response from the Secondary station
b0 b1 b2 : nr=010 – the Primary station is expecting frame 2 from the Secondary Station
Primary station received previous frames until frame 1 without error

Re-writing the Control field: 1 0 0 0 0 1 0 0


b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=010 – this is frame 2 from the Secondary station
b3 : 0 – not-a-Final, this is not (yet) the final frame from Secondary station
b0 b1 b2 : nr=100 – the Secondary station is expecting frame 4 from the Primary Station
Secondary station received previous frames until frame 3 without error
Note that the Primary has already sent frame 4, but Secondary is still expecting frame 4. This only
means that frame 4 was received with error detected, so Secondary is requesting retransmission of
frame 4.
Re-writing the Control field: 1 0 0 0 0 1 1 0
b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=011 – this is frame 3 from the Secondary station
b3 : 0 – not-a-Final, this is not (yet) the final frame from Secondary station
b0 b1 b2 : nr=100 – the Secondary station is expecting frame 4 from the Primary Station
Secondary station received previous frames until frame 3 without error

Re-writing the Control field: 1 0 0 1 1 0 0 0


b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=100 – this is frame 4 from the Secondary station
b3 : 1 – Final, this is the final frame from Secondary station
b0 b1 b2 : nr=100 – the Secondary station is expecting frame 4 from the Primary Station
Secondary station received previous frames until frame 3 without error
Indicates that the Primary station replied with 5 frames (frame 4,5,6,7 and 0). All frames indicate that the Primary has
received all previous frames from the secondary until the 4th frame. Primary is expecting frame 5 (nr=5) from Secondary
station.

Re-writing the Control field: 0 0 1 1 1 0 1 0


b0 b1 b2 b3 b4 b5 b6 b7

b7 : 0 - the frame is an Information Frame


b4 b5 b6 : ns=101 – this is frame 5 from the Secondary station
b3 : 1 – Final, this is the final frame from Secondary station
b0 b1 b2 : nr=001 – the Secondary station is expecting frame 1 from the Primary Station
Secondary station received previous frames until frame 0 without error

WHEW!!! That was long. Hope you were able to follow.

Вам также может понравиться