Data Transmission and Computer Networks

Slides:



Advertisements
Similar presentations
Synchronous Links/Networks Modems are asynchronous - penalized by start bits and stop bits on each character (and dead time) Synchronous Networks recover.
Advertisements

Data and Computer Communications Digital Data Communications Techniques.
William Stallings Data and Computer Communications 7th Edition
The Data Link Layer Chapter 3. Data Link Layer Design Issues Services Provided to the Network Layer Framing Error Control Flow Control.
5/15/2015© 2008 Raymond P. Jefferis IIILect The Data Link Layer.
Assessment 1 Review Network Layers. Computer 1Computer 2 2.
Framing and Stuffing Advanced Computer Networks. Framing & Stuffing Outline  Synchronous vs Asynchronous Transmissions  Asynchronous Character Transmissions.
Chapter 7 – Data Link Control Protocols
CSC 3352 Computer Communications Chapter 3&41 The Link Layer Has 2 main Components The Data Link Layer Medium Access Control (MAC) Examples:SLIP, PPP,
1 Chapter Six - Errors, Error Detection, and Error Control Chapter Six.
The OSI Reference Model
1 K. Salah Module 4.0: Data Link Layer The Logical Link Control (LLC) sublayer –Framing –Flow Control –Error Control The Media Access Control (MAC) sublayer.
Bit and Byte Stuffing1. 2 Synchronous versus Asynchronous Transmissions There exists a hierarchy of synchronization tasks: –Bit level : recognizing the.
Transmission Characteristics 1. Introduction (Information Interchange codes) 2. Asynchronous and Synchronous Transmissions 3. Error detection (bit errors)
Transmission Modes Different ways of characterizing the transmission.
Networks: Bit and Byte Stuffing
William Stallings Data and Computer Communications 7th Edition Chapter 6 Digital Data Communications Techniques.
Computer Networks: Bit and Byte Stuffing 1 Bit and Byte Stuffing.
1/26 Chapter 6 Digital Data Communication Techniques.
Synchronous - Asynchronous Data Transmission. Asynchronous ► The sender and receiver are not Synchronised. ► The sender sends only one character at a.
Data Link Protocols Asynchronous Protocols Synchronous Protocols
Gursharan Singh Tatla DATA LINK PROTOCOLS 24-Mar
Simplex, Half Duplex & Duplex Serial & Parallel transmission Synchronous & Asynchronous Bit & Baud Rate.
Midterm Review - Network Layers. Computer 1Computer 2 2.
CS 640: Introduction to Computer Networks Aditya Akella Lecture 5 - Encoding and Data Link Basics.
Data Link Control Protocols. 2 Introduction Data link layer –Concerned with the transfer of data over a serial data link Link –Point-to-point physical.
Data Link Layer - 1 Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF.
ECS 152A 4. Communications Techniques. Asynchronous and Synchronous Transmission Timing problems require a mechanism to synchronize the transmitter and.
Data and Computer Communications
CHAPTER 2 HARDWARE BUILDING BLOCK ENCODING FRAMING ERROR DETECTION.
Computer Networks Chapter 11 – Data Link Control and Protocols.
Review:. Chapter 3: The Data Link Layer –achieve reliable, efficient communication between two physically connected machines. –Example problems to be.
Data Link Layer : Services, Framing, Error Detection and Correction2.
The Data Link Layer Goal –As reliable as possible, efficient communication Point-to-Point –single connection –bits arrive in order sent Not necessarily.
UNIT-II Computer Network Data Link Layer. Data Link Layer Prepared by - ROHIT KOSHTA Data Link Layer is second layer of OSI reference model and is placed.
Data and Computer Communications Chapter 6 – Digital Data Communications Techniques.
Data and Computer Communications by William Stallings Eighth Edition Digital Data Communications Techniques Digital Data Communications Techniques Click.
1 Introduction 4 Information transfer between two computers occurs in one of two types signals: digital or analog. Chapter 2 Introduction to Data Communication.
Layer Two Data Link Layer Collects bits from layer 1 and organizes into frames Passes bits that make up frames to layer 1 for transmission Concerned with.
Chapter 11 Data Link Protocols A data link protocol is a set of specifications used to implement the data link layer [A protocol is the set of rules or.
Data Link and Flow Control Networks and Protocols Prepared by: TGK First Prepared on: Last Modified on: Quality checked by: Copyright 2009 Asia Pacific.
Eighth Edition by William Stallings Chapter 7 – Data Link Control Protocols Data Link Control Protocols need layer of logic above Physical to manage exchange.
DATA LINK CONTROL PROTOCOLS. 2 Introduction Data link control layer – often abbreviated simply to data link layer – is concerned with the transfer of.
Data Transmission n Keep errors to an acceptable low probability n Bit-serial transmission n Parallel transmission.
AS Computing Data transmission. Basic data transmission Baud The rate that the voltage changes is called the Baud. If the voltage changes 10 times every.
Unit 1 Lecture 4.
Computer Interfacing and Protocols
1/30/ :20 PM1 Chapter 6 ─ Digital Data Communication Techniques CSE 3213 Fall 2011.
FIT1005 FIT – Monash University
Error Correction and Flow Control Martin Weiss. Slide 2 Objectives of this Meeting u Describe different flow control techniques u Describe the major error.
Framing and Stuffing Advanced Computer Networks. Framing & Stuffing Outline  Synchronous vs Asynchronous Transmissions  Asynchronous Character Transmissions.
Data and Computer Communications Eighth & Ninth Edition by William Stallings Chapter 6 – Digital Data Communications Techniques.
+ PPP Protocol. + Outline WAN Data Link Layer protocols Point-to-point serial communications Transmission Synchronization HDLC.
Chapter Nine: Data Transmission. Introduction Binary data is transmitted by either by serial or parallel methods Data transmission over long distances.
Recap of Layers Application, Data Link and Physical.
Data and Computer Communications Digital Data Communications Techniques + Error Control+ Digital Data Communications Techniques + Error Control+Multiplexing.
Chapter 4 Data Link Layer.
24/11/1013-Datalink1 The Data Link Layer Role Services Functions –Framing –Encapsulation –Addressing –Connection Control –Ordered Delivery –Flow Control.
Serial Communications
Chapter 9: Data Link Control
Data Link Layer.
Data link layer (LLC).
Data Transmission Keep errors to an acceptable low probability
Lecture on Data Link Control
Chapter Nine: Data Transmission
Chapter 4 Data Link Layer.
Networks: Bit and Byte Stuffing
Chapter 9: Data Link Control
Data Link Layer. Position of the data-link layer.
Introduction Communication Modes Transmission Modes
Presentation transcript:

Data Transmission and Computer Networks 6 Data Link Layer

DATA LINK LAYER The Data Link Layer Tasks: The data link layer transmits raw bits into a line that appears free of transmission errors to the network layer. The Data Link Layer Tasks: Bits Error Detection and Corrections Point-to-point Error Control: a frame may be destroyed, an acknowledgement frames may get lost, a duplicate frame may be produced. , a frame may be out of sequence ….etc Point-to-point flow control: mechanism employed to prevent a fast transmitter from drowning a slow receiver in data. Framing: It creates and recognizes frame boundaries.

DATA LINK LAYER The Data Link Layer Tasks: Devices Interfacing Medium Access Control (MAC) To allow multiple devices share a common link Addressing To define address of each device connected to the link Line configurations : To define transmission & communication modes and transmission techniques.

Transmission Techniques 1.Parallel Transmission

2.Serial Transmission Time 1- bit 1 Destination Source DTE Signal Reference 1- bit Time

Communication Modes When data is transmitted between two pieces of equipment, three communication modes of operation can be used. Simplex: Data is to be transmitted in one direction only. Half-Duplex: This is used when two interconnected devices which to interchange information alternately. Duplex or full-Duplex: This is used when data is to be exchanged between two connected devices in both directions simultaneously.

Transmission Modes For the receiving device to interpret the bit pattern correctly, it must be able to determine the following: Bit Synchronization: The start of each bit cell period (in order to sample the incoming signal in the middle of the bit cell). Character Synchronization: The start and end of each character or byte. Frame Synchronization: The start and end of each complete message block (frame). Two transmission modes to accomplish synchronization : 1. Asynchronous Transmission. 2. Synchronous Transmission.

1. Asynchronous Transmission In asynchronous transmission, the receiver clock (R×C) runs unsynchronized with respect to the incoming signal (R×D). Each character (byte) is encapsulated between an additional start bit and one or more stop bits. The state of the signal on the transmission line between characters is idle state.

Standard Interchange Codes 1. American Standards Committee for Information Interchange (ASCII): 1 7 Bit Positions 6 5 2 3 4 p \ P @ SP DLE NUL q a Q A ! DC1 SOH r b R B ” DC2 STX s c S C # DC3 ETX t d T D $ DC4 EOT u e U E % NAK ENQ v f V F & SYN ACK w g W G ’ ETB BEL x h X H 8 ( CAN BS y i Y I 9 ) EM HT z j Z J : * SUB LF { k [ K ; + ESC VT | l L < , FS FF } m ] M = - GS CR ~ n ^ N > . RS SO DEL o _ O ? / US SI

Standard Interchange Codes 1. Extended Binary Coded Decimal Interchange Code (EBCDIC): 1 8 Bit Positions 7 6 5 2 3 4 - & SP DS DLE NUL J A j a / SOS DC1 SOH S K B s k b SYN FS DC2 STX T L C t l c DC3 ETX U M D u m d PN BYP RES PF V N E v n e RS LF NL HT W O F w o f UC EOB BS LC X P G x p g EOT PRE IL DEL Y Q H y q h CAN 9 Z I z r i EM : ! ¢ SM CC SMM # ’ $ . VT @ % * < DC4 IFS FF , ) ( NAK ENQ IGS CR = > ; + ACK IRS SO  ” ? ¬ | SUB BEL IUS SI

1. Asynchronous Transmission Example 3.1: Construct the transmitted frame using asynchronous transmission mode which contains the following data: GO. Assume that the number of stop bits is 2 and parity bit is used. STX P Idle Start of text Start bit Two stop bits Parity Charater P End of text ETX P O Message : GO P G

1. Asynchronous Transmission Example : Construct the transmitted frame using asynchronous transmission mode which contains the following data: YES. Assume that the number of stop bits is 1 and no parity bit is used. STX Idle Start of text Start bit Stop bit Charater End of text ETX S Message : YES Y E

1. Asynchronous Transmission Example : Assuming asynchronous transmission mode is used with 8-bit character, a parity bit, two stop bits, and transfer rate 14400 bps. Calculate the following: 1. Size of the transmitted element (in bits) which contains one character. 2. Time duration for each bit . 3. Maximum number of characters that can be transmitted per second. Solution of Example : 1. Size of transmitted element = 1 + 8 + 2 + 1 = 12 bits. 2. Time duration for each bit = 1 / 14400 sec. 3. Max. number of char per second = 14400 / 12 = 1200 char/sec. 4.0 Efficiency = 8/12 = 66.6 %

1. Asynchronous Transmission Character Synchronization using Asynchronous Transmission: After the start bit is detected, the receiver achieves character synchronization simply by counting the programmed number of bits.

Framing using Asynchronous Transmission: Frame synchronization is used to determine the start and end of frame. Case I: Printable Characters Encapsulate the complete block between two non-printable characters: STX (start-of-text) and ETX (end-of-text). Case II: Binary Data When transmitting binary data, STX and ETX are preceded by another control character known as Data Link Escape (DLE).

Framing Frame Synchronization using Asynchronous Transmission: To transmit binary data: The binary file may contain ETX character which would cause the receiver to terminate reception abnormally. For this , the following steps are taken Step 1: When transmitting binary data, STX and ETX are preceded by another control character known as Data Link Escape (DLE). Step 2: After transmitting the start of frame sequence (DLE-STX), the transmitter inspects each byte in frame prior to transmission to determine if it is a DLE character. If it is, a second DLE character is transmitted before the next byte. Step 3: Step 2 is repeated until the appropriate number of bytes have been transmitted. The transmitter then transmits the unique DLE-ETX sequence. To receive binary data: When the receiver receives a DLE, it checks the next character. If the next character is another DLE, the receiver discards it and waits for the next byte. If it is an ETX, then it terminates reception process.

1. Asynchronous Transmission Frame Synchronization using Asynchronous Transmission: Case I: For Printable Characters

1. Asynchronous Transmission Frame Synchronization using Asynchronous Transmission: Case II: For Binary Data

1. Asynchronous Transmission Example : Construct the transmitted frame using asynchronous transmission mode which contains the following data: A B DLE ETX Z. Assume that the number of stop bits is 1 and no parity bit is used. Start-of-text sequence Idle DLE STX A B DLE DLE End-of-text sequence Start bit Charater Stop bit ETX Z DLE ETX

1. Asynchronous Transmission Example : Construct the transmitted frame using asynchronous transmission mode which contains the following data: R DLE DLE ETX I DLE. Assume that the number of stop bits is 1 and no parity bit is used. DLE Idle Start-of-text sequence Start bit Stop bit Charater STX R ETX I End-of-text

2. Synchronous Transmission The complete block or frame of data is transmitted as a contiguous stream with no delay between each 8-bit element. To enable the receiving device to achieve synchronization: The transmitted bit stream is suitably encoded. All frames are preceded by two or more reserved bytes or characters. The content of each frame is encapsulated between a pair of reserved characters.

Framing in Synchronous Transmission There are two schemes to achieve character and frame synchronization in the synchronous transmission: Character-Oriented Synchronous Transmission Bit-Oriented Synchronous Transmission Both use the same bit synchronization method.

2. Synchronous Transmission I. Character-Oriented Synchronous Transmission: The transmitter adds two or more transmission control characters known as Synchronous Idle or (SYN) characters before each block of characters. SYN characters are used to allow receiver to maintain bit synchronization.

2. Synchronous Transmission I. Character-Oriented Synchronous Transmission: Once this has been done, they allow the receiver to start interpret the received bit stream on the correct character boundaries - Character Synchronization. The frame synchronization is achieved by encapsulating the block of characters between STX and ETX pair for the case of the text transmission, and the start-of-frame sequence (DLE-STX) and the end-of-frame sequence (DLE-ETX) for the case of the binary transmission.

2. Synchronous Transmission I. Character-Oriented Synchronous Transmission: Case 1: Printable characters: Case 2: Binary data:

2. Synchronous Transmission II. Bit-Oriented Synchronous Transmission: Character-oriented transmission is inefficient for transmission binary data because it performs too much DLE stuffing. Therefore, alternative synchronous transmission scheme is used – Bit-Oriented Synchronous Transmission. In Bit-Oriented Synchronous Transmission, the transmitter sends a string of idle bytes (each compromising 01111111) preceding the opening flag (01111110). When the receiver gets the opening flag, the frame contents are read and interpreted on 8-bit boundaries until the closing flag (01111110) is detected. The reception process is then terminated.

2. Synchronous Transmission II. Bit-Oriented Synchronous Transmission:

2. Synchronous Transmission II. Bit-Oriented Synchronous Transmission: To achieve data transparency with this scheme, we must ensure the flag pattern is not present in the frame contents. We can do this by bit Stuffing. The bit stuffing technique is to detect a sequence of 5 contiguous binary 1 digits in the transmitted frame contents, then automatically inserts an additional binary 0 digit. In this way, the flag pattern 01111110 can never be present in the frame contents between the opening and closing flag.

Number of additional bits =322 bits Example : Deduce the number of additional bits required to transmit a text message comprising 100 of 8-bit characters over a data link using each of the following transmission control schemes: Case 1: Asynchronous with two stop bits per character. Stop bits Start bit STX Char 1 Char 2 Char 100 ETX 1 2 1 2 1 2 11-bit 3-bit 3-bit 3-bit 11-bit Number of additional bits =322 bits

2. Synchronous Transmission Example (Continued): Case 2: Synchronous with two synchronization characters. Char 1 SYN STX Char 2 Char 100 ETX 8-bit Number of additional bits = 32 bits

2. Synchronous Transmission II. Bit-Oriented Synchronous Transmission: Example 3.8: Assume Bit-Oriented Synchronous Transmission is to be used. Construct the transmitted frame, which contains the binary data: 1 1 0 1 1 0 0 1 1 1 1 1 1 0 0 1 1 1 1 1 0 1 1. Solution of Example 3.8: 0 1 1 1 1 1 1 0 Opening flag Closing flag 1 1 0 1 1 0 0 1 1 1 1 1 0 1 0 0 1 1 1 1 1 0 0 1 1 Additional zero bits inserted

Transmission Modes (Summary) Synchronous Transmission Asynchronous Transmission Bit Synchronization Frame Synchronization Character Synchronization Bit Synchronization Bipolar Encoding Bit-Oriented Character-Oriented Printable- Character Frame Manchester Encoding Printable- Character Frame Binary Data Frame Differential Manchester Encoding Binary Data Frame

Bit Error Control There are two approaches for achieving bit error control: Forward error control, in which the receiver cannot only detect when error are present but also determine where in the received bit stream the errors are. The correct data is then obtained by inverting these bits. Feedback (backward) error control, in which the receiver detects when errors are present but not their location. A retransmission control scheme is used to request that another copy of information to be sent.

1. Feedback (Backward) Error Control I. Parity:

1. Feedback (Backward) Error Control I. Parity:

1. Feedback (Backward) Error Control II. Vertical Redundancy Check (VRC):

1. Feedback (Backward) Error Control III. Cyclic Redundancy Check (CRC) :

1. Feedback (Backward) Error Control III. Cyclic Redundancy Check (CRC) : Example : A series of 8-bit message blocks (frames) is to be transmitted across a data link using a CRC for error control. A generator polynomial of 11001 is to be used. Use an example to illustrate the following: The FCS generation process. The FCS checking process.

1. Feedback (Backward) Error Control III. Cyclic Redundancy Check (CRC) : Solution of Example : The FCS generation process. M(x) R(x)

1. Feedback (Backward) Error Control III. Cyclic Redundancy Check (CRC) : Solution of Example 3.9: (b) The FCS checking process.