Presentation is loading. Please wait.

Presentation is loading. Please wait.

CH. 7 Data Link Control. Requirements & Objectives of Data Link Control Frame Synchronization Flow Control Error Control Addressing Control and Data on.

Similar presentations


Presentation on theme: "CH. 7 Data Link Control. Requirements & Objectives of Data Link Control Frame Synchronization Flow Control Error Control Addressing Control and Data on."— Presentation transcript:

1 CH. 7 Data Link Control

2 Requirements & Objectives of Data Link Control Frame Synchronization Flow Control Error Control Addressing Control and Data on Same Link Link Management

3 7.1 Flow Control Definition: –A technique for assuring that a transmitting station does not overwhelm a receiving station with data. Stop-and Wait Flow Control –The sender sends a frame and then waits until the receiver acknowledges the frame. –Works well for large blocks of data--but large blocks are usually broken into smaller blocks. –Does not always perform well for small blocks.

4 7.1 Flow Control (p.2) Characterization of Stop-and-Wait –Let B = length of the link in bits--the number of bits present on the link when a stream of bits fully occupies the link. –Let R =data rate of the link, in bps. –Let d = length, or distance, of the link in meters. –Let V = velocity of propagation, in meters/second. –Then B = R x d/V (Equation 7.1). –Variable a = B/L (Equation 7.2) –Utilization--Fig. 7.2

5 7.1 Flow Control (p.3) Example 7.1 Stop and Wait –a. Fiber Optic Link (d = 200 meters; R = 1 G bps; V = 2 x 10 8 meters/second; 1,000 bytes/frame) B =1,000 bits; L = 8,000 bits; t frame = 8  s. a = 1,000/8,000 =.125 < 1 (see Fig. 7.2b) Total Normalized Time--1 + 2a = 1.25 (10  s) –b. Satellite Relay Link ( d = 2 x 36,000 km; R = 1 M bps; V = 3 x 10 8 meters/second; 1,000 bytes/frame.) B =240,000 bits; L = 8,000 bits; t frame = 8ms. a =30 > 1 (see Fig. 7.2a) Total Normalized Time--1 + 2a = 61 (488 ms).

6 7.1 Flow Control (p.4) Sliding Window Flow Control (Fig.7.3 and 7.4) –Allows more than one frame to be sent at a time. –More than one frame may be acknowledged at a time. –Source A keeps a list of sequence numbers that are allowed to be sent. –Destination B maintains a list of sequence numbers that it is prepared to receive. –If k bit sequence numbers are used, frames are numbered modulo(2 k ) and maximum window size is 2 k -1.

7 7.1 Flow Control (p.5) Example 7.3 Sliding Window –a. Fiber Optic Link Time until ACK for 1st frame was 10  s. t frame was 8  s. A. window size of 2 would be all that is needed for transmission to be continuous. Note W =  Time until ACK/t frame  will be the maximum window needed for continuous transmission. –b. Satellite Link W =  488ms/8ms  =61 for continuous transmission. If W = 7 (3-bit window), sends 7 frames and must then wait for an ACK.

8 7.2 Error Control Two Types of Errors: lost and damaged frames. Elements of Error Control (ARQ) –Error Detection: use a CRC –Positive ACK Destination returns a positive ACK for error-free frames. –Retransmission after Timeout Source retransmits a frame that has not been acknowledged after a predetermined amount of time. –Negative ACK and Retransmission Destination returns a negative ACK for frames in which an error is detected; the source retransmits the frames.

9 7.3 Error Control (p.2) Stop-and Wait ARQ (Fig. 7.5) –Based on stop-and-wait flow control. –Source transmits a single frame and then must wait for an ACK. –If an error is detected a NAK could be sent. –If there is no response, then source times-out and resends the message. –To avoid duplications, 1 bit sequence number could be added to frame and or ACKs. –It is simple but sometimes inefficient.

10 7.3 Error Control (p.3) Go-back-N ARQ (Fig. 7.6a) –Source transmits multiple frames (sliding window) and then waits for ACK (RR). –Destination sends ACKs up to the last correct frame received. –One ACK can acknowledge several frames. –The error frame is retransmitted along with all subsequent frames. Selective-reject ARQ (Fig. 7.6b) –Only error frames are retransmitted.

11 7.3 High Level Data Link Control (HDLC) ISO 3309, ISO 4335. Three Types of Stations –Primary--has the responsibility for controlling the operation of the link. –Secondary--controlled by primary station. –Combination--combines features of primary and secondary

12 7.3 HDLC (p.2) Two Link Configurations –Unbalanced (Primaries and Secondaries) Used in point to point and multipoint operation. –Balanced (Combinations) Used only in point to point operation.

13 7.3 HDLC (p.3) Three Data Transfer Modes –Normal response mode (NRM): unbalanced configuration; poll and selection (used on multidrop lines). –Asynchronous balanced mode (ABM): balanced configuration; either combined station may initiate transmission (used on pt-to-pt lines). –Asynchronous response mode (ARM): unbalanced configuration; secondary may initiate transmission( rarely used).

14 7.3 HDLC (p.4) Frame Structure(Fig. 7.7) –Flag Field (8 bits) 01111110 (Ox7E) Transparency is handled using bit- stuffing. Transmitter will stuff a 0 after 5 1's--see Fig. 7.8. –Address Field (One or more Octets) Used to identify secondary stations

15 7.4 HDLC (p.5) Frame Structure (cont.) –Control Field (8 or 16 bits) Information frames: carry data and ACKs. Supervisory frames: ACKs. Unnumbered frames : supplemental control. –Information Field (variable number of bits) –Frame Check Sequence Field (16 or 32 bits)

16 7.4 HDLC (p.6) HDLC Operations (Fig. 7.9) –Initialization, Data Transfer, Disconnect. –Table 7.1 Commands and Responses Reject supports "Go-Back-N". Selective Reject supports "Selective Reject". Receiver Not Ready, Receiver Ready –Used as ACKs and for flow control. Mode setting commands. Information transfer commands. Recovery commands. –Error types can be reported.


Download ppt "CH. 7 Data Link Control. Requirements & Objectives of Data Link Control Frame Synchronization Flow Control Error Control Addressing Control and Data on."

Similar presentations


Ads by Google