Presentation is loading. Please wait.

Presentation is loading. Please wait.

EEC-484/584 Computer Networks Lecture 12 Wenbing Zhao Cleveland State University

Similar presentations


Presentation on theme: "EEC-484/584 Computer Networks Lecture 12 Wenbing Zhao Cleveland State University"— Presentation transcript:

1 EEC-484/584 Computer Networks Lecture 12 Wenbing Zhao Cleveland State University wenbing@ieee.org

2 2 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Outline Quiz#3 Result Reminder: EEC584 initial draft due midnight today Data Link layer –Data Link Layer Design Issues –Framing –Error Detection and Correction (omitted) EEC484 only: project walk-through DLL Data Link Medium Access Control (MAC) We Cover This SubLayer in this lecture

3 3 EEC484 Quiz#3 Result Average: 80.8, high: 95, low: 57 Q1-37.5, Q2-16.9, Q3-12.9, Q4-13.5 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao

4 4 EEC584 Quiz#3 Result Average: 92, high: 100 (4), low: 80 Q1-44.2, Q2-18.7, Q3-14.8, Q4-14.4 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao

5 5 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Data Link Layer Design Issues Services Provided to the Network Layer –Point-to-point, source-to-destination Framing –Physical bit stream divided up into frames Error Control –Acknowledgements (acks), retransmission, duplicate suppression Flow Control –Throttle sender so sends no faster than receiver can receive them

6 6 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Functions of Data Link Layer Provide a virtual source-to-destination communication channel to the network layer Dealing with transmission errors Regulating data flow

7 7 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Services Provided to Network Layer (a) Virtual communication (b) Actual communication

8 8 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Placement of Data Link Protocol

9 9 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Types of Services Provided to Network Layer Unacked connectionless –Ok if low error rate, real time applications Acked connectionless Unacked connection-oriented Acked connection-oriented

10 10 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Framing DL layer divides physical bit stream into frames Checksum computed by source included in frame Checksum recomputed by destination and checked against checksum included in the frame –Discard/recover bad frame, notify source

11 11 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao How Does DL Layer Form Frames? Insert time gaps between frames: too risky Character count Flag bytes with byte stuffing Starting and ending flags, with bit stuffing Physical layer coding violations –Example: encode 1 bit of data with 2 bits 1 => 10 0 => 01 Can use 00 or 11 to delimit frames

12 12 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Framing Based on Character Count Use field in header to indicate number of characters in frame Problem: Count might be garbled

13 13 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Framing Based on Byte Stuffing Each frame starts and ends with a special flag byte –Problem: flag byte might appear in data –Solution: Source inserts ESC (DL escape) before each flag byte; ESC before each ESC Destination removes inserted ESC bytes Disadvantage: depends on 8-bits characters in ASCII

14 14 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Framing Based on Byte Stuffing

15 15 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Framing Based on Bit Stuffing Each frame begins and ends with special bit patterns, 01111110 (in fact, a flag byte) When source ’ s data contains 11111, stuff 0 When destination receives 111110, deletes 0 Advantages: –Allows arbitrary number of bits per frame –Allows arbitrary number of bits per character

16 16 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Framing Based on Bit Stuffing: Example Original Frame (payload only) Frame after bit stuffing Received Frame after taken stuffed bit out

17 17 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Exercise Q1. The following character encoding is used in a data link protocol: A: 01000111; B: 11100011; FLAG: 01111110; ESC: 11100000 Show the bit sequence transmitted (in binary) for the four- character frame: A B ESC FLAG when each of the following framing methods are used: (a) Character count. (b) Flag bytes with byte stuffing. (c) Starting and ending flag bytes, with bit stuffing

18 18 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Exercise Q2. The following data fragment occurs in the middle of a data stream for which the byte- stuffing algorithm described in the text is used: A B ESC C ESC FLAG FLAG D. What is the output after stuffing?

19 19 6/16/2015EEC-484/584: Computer NetworksWenbing Zhao Exercise Q3. A bit string, 0111101111101111110, needs to be transmitted at the data link layer. What is the string actually transmitted after bit stuffing?


Download ppt "EEC-484/584 Computer Networks Lecture 12 Wenbing Zhao Cleveland State University"

Similar presentations


Ads by Google