CSS 432 1 CSS432 Point-to-Point Links Textbook Ch2.1.2 – 2.5 Professor: Munehiro Fukuda.

Slides:



Advertisements
Similar presentations
EE 4272Spring, 2003 Chapter 7 Data Link Control Objectives: Effective & reliable data communication between two directly connected transmitting-receiving.
Advertisements

1 Chapter 2 Agenda Announcements / updates Gayle Laakman McDowell, 10/11, 4:30pm, UW2-005 GUIs / IDEs for remotely accessing uw1-320-lab Other references.
Lecture 3, 1Spring 2003, COM1337/3501CCN: Direct Link Networks Direct Link Networks Textbook: Computer Networks: A Systems Approach, L. Peterson, B. Davie,
Spring 2002CS 4611 Outline Encoding Framing Error Detection Sliding Window Algorithm Point-to-Point Links.
Fundamentals of Computer Networks ECE 478/578 Lecture #3: Encoding and Framing Instructor: Loukas Lazos Dept of Electrical and Computer Engineering University.
EE 122: Error detection and reliable transmission Ion Stoica September 16, 2002.
1 Outline Encoding Framing Error Detection Sliding Window Algorithm Point-to-Point Links.
1 Hardware Building Blocks Five Issues –Encoding –Framing –Error Detection –Reliable delivery –Access Mediation Direct Link Networks.
Spring 2004 EE4272 Direct Link Networks (I) Hardware Building Blocks (nodes & links) 5 Issues before Exchanging Packets  Encoding  Framing  Error Detection.
Spring 2003CS 4611 Outline Encoding Framing Error Detection Sliding Window Algorithm Point-to-Point Links.
CS 164: Slide Set 3: Chapter 2 Direct Link Networks.
Error Detection and Reliable Transmission EECS 122: Lecture 24 Department of Electrical Engineering and Computer Sciences University of California Berkeley.
18-Aug-154/598N: Computer Networks Overview Direct link networks –Error detection - Section 2.4 –Reliable transmission - Section 2.5.
CompSci 356: Computer Network Architectures Lecture 4: Link layer: Encoding, Framing, and Error Detection Xiaowei Yang
CS 640: Introduction to Computer Networks Aditya Akella Lecture 5 - Encoding and Data Link Basics.
EE 122: Encoding And Framing Ion Stoica September 9, 2002.
CSCI-1680 Physical Layer Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.
CSE331: Introduction to Networks and Security Lecture 3 Fall 2002.
14-Oct-15Computer Networks1 Reliable Transmission.
1 Outline Encoding Framing Error Detection Sliding Window Algorithm Point-to-Point Links.
Univ. of TehranIntroduction to Computer Network1 An Introduction to Computer Networks University of Tehran Dept. of EE and Computer Engineering By: Dr.
Lecture 7: Reliable Packet Transmission. Cyclic Redundancy Check Add k bits of extra data (the CRC field) to an n-bit message to provide error detection.
Error Coding Transmission process may introduce errors into a message.  Single bit errors versus burst errors Detection:  Requires a convention that.
Univ. of TehranComputer Network1 Computer Networks Computer Networks (Graduate level) University of Tehran Dept. of EE and Computer Engineering By: Dr.
CHAPTER 2 HARDWARE BUILDING BLOCK ENCODING FRAMING ERROR DETECTION.
Advanced Computer Networks Chapter 2: Direct Link Networks.
Lecture 6: Framing and Error Detection-Data Link Layer Functions
27-Oct-15Computer Networks1 Outline Chapter 2: Direct Link Networks Encoding Framing Error Detection Sliding Window Algorithm Point-to-Point Links.
Fall 2000Datacom 11 Outline Hardware Building Blocks Encoding Framing Error Detection Sliding Window Algorithm Point-to-Point Links.
CS3505: DATA LINK LAYER. data link layer  phys. layer subject to errors; not reliable; and only moves information as bits, which alone are not meaningful.
1 CHAPTER 2 HARDWARE BUILDING BLOCK ENCODING FRAMING ERROR DETECTION.
Link Layer Dr. Mozafar Bag-Mohammadi Ilam University.
CSCI-1680 Physical Layer Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.
T. S. Eugene Ngeugeneng at cs.rice.edu Rice University1 COMP/ELEC 429 Introduction to Computer Networks Lecture 12: Reliability Slides used with permissions.
Computer Networks Lecture 2: Data Link Based on slides from D. Choffnes Northeastern U. and P. Gill from StonyBrook University Revised Autumn 2015 by S.
Spring 2001CS 5851 Outline Building Blocks Shannon’s Theorem Encoding 11. Physical Layer.
Data Link Layer (Layer 2, L2) 염익준. 2 Cables Used to connect nodes in the same room or building. CableTypical BandwidthsDistances Cat-5 twisted pair Thin-net.
9-Jan-164/598N: Computer Networks Overview Performance metrics - Section 1.5 Direct link networks –Hardware building blocks - Section 2.1 –Encoding - Section.
An Introduction to Computer Networks
Point-to-Point Links: Framing
Transport Layer: Sliding Window Reliability
1 Chapter 2: Direct Link Networks (Part One) Dr. Rocky K. C. Chang 30 January 2004.
Univ. of TehranIntroduction to Computer Network1 An Introduction to Computer Networks University of Tehran Dept. of EE and Computer Engineering By: Dr.
1 Hardware Building Blocks Five Issues –Encoding –Framing –Error Detection –Reliable delivery –Access Media Direct Link Networks.
1 Point-to-Point Links: Encoding Encoding: Section 2.2 (Section 2.1 read on your own)
Network Layer4-1 Chapter 5: The Data Link Layer Our goals: r understand principles behind data link layer services: m error detection, correction m sharing.
1 Direct Link Networks: Reliable Transmission Sections 2.5.
CSE331: Introduction to Networks and Security Lecture 4 Fall 2002.
Univ. of TehranComputer Network1 Computer Networks Computer Networks (Graduate level) University of Tehran Dept. of EE and Computer Engineering By: Dr.
Univ. of TehranIntroduction to Computer Network1 An Introduction to Computer Networks University of Tehran Dept. of EE and Computer Engineering By: Dr.
Computer Networking Lecture 16 – Reliable Transport.
CS380 Int. to Comp. Networks Data Link Networks - Part II1 Reliable Transmission How to fix corrupted frames. –Error correcting codes too expensive –Should.
Getting Connected (Chapter 2 Part 1)
Data Link Networks Hardware Building Blocks Nodes & Links CS380
Prof. Athirai Irissappane
Advanced Computer Networks
CSS432 Point-to-Point Links Textbook Ch2.1 – 2.5
2. Getting connected (part 1)
Reliable transmission
Point-to-Point Links Outline Encoding Framing Error Detection
Ion Stoica September 6, 2001 EE 122: Lecture 4 Ion Stoica September 6, 2001.
CSS432 (Link Level Protocols) Reliable Transmission Textbook Ch 2.5
Fundamentals of Computer Networks
Hardware Building Blocks
CSE 461: Framing, Error Detection and Correction
Transport Layer Outline Intro to transport UDP
Dr. Mozafar Bag-Mohammadi Ilam University
Home work project #1 Develop and fully debug your program on the Cushing 208 lab. Machines - planet lab machines may not have good development environment.
Error detection: Outline
EECS 122: EE122: Error Detection and Reliable Transmission
Presentation transcript:

CSS CSS432 Point-to-Point Links Textbook Ch2.1.2 – 2.5 Professor: Munehiro Fukuda

CSS Basic Knowledge about Links Full-duplex versus Half-duplex  Full  Half Local cable types  Category 5 twisted pair  Coax  Multimode fiber LED-based, 2km  Single-mode fiber laser-diode-based, 40km Carrier-supported cables/fibers  DS1 (T1): 1.544Mbps, 24-digital voice circuits of 64 Kbps each  DS3 (T3): Mbps, 28 DS1 links  STS-1 (OC-1): Synchronous Transport signal, the base link speed= Mbps  STS-3, 12, 48, 192 (OC-3, OC-12, OC-48, OC-192) at time t at time u

CSS Basic Knowledge (Cont’d) Last-Mile Links  POTS: Plain Old Telephone Service  ISDN: Integrated Services Digital Network  ADSL: Asynchronous Digital Subscriber Line  VDSL: Very high data rate Digital Subscriber Line Wireless Links  AMPS, PCS, GSM: Wide-area analog/digital-based mobile phone services  IEEE : wireless LAN with up to 54Mbps transfer rate  BlueTooth radio interface: 1Mpbs piconet in 10m CODEC Voice line 28.8~56Kbps Digital line Kbps Mbps Kbps STS-N 12.96~ 55.2Mbps

CSS Focusing on ADSL To telephone switch Residence A Residence B 255 frequencies for downstream 31 use for upsreams 2 taken for control Long distance Preparing 286 frequencies and agreeing at the available frequencies between two modems Fitting to most usages where a user tends to retrieve Internet information.

CSS Encoding Signals propagate over a physical medium  modulate electromagnetic waves  e.g., vary voltage Encode binary data onto signals  e.g., 0 as low signal and 1 as high signal  known as Non-Return to zero (NRZ) Consecutive 1s and 0s  Baseline wander: if the receiver averages signals to decide a threshold  Clock recovery: both sides must be strictly synchronized Bits NRZ

CSS Alternative Encodings Non-return to Zero Inverted (NRZI)  Encode 1: make a transition from current signal  Encode 0: stay at current signal to encode a zero  solves the problem of consecutive 1s Signal flips every 1 is encountered. Manchester  Transmit XOR of the NRZ encoded data and the clock  Only 50% efficient.  Used by Ethernet/Token Ring 0 1

CSS B/5B Encoding Every 4 bits of data encoded in a 5-bit code 5-bit codes selected to have  no more than one leading 0  no more than two trailing 0s  See textbook Table 2.4 on page 79 Thus, never get more than three consecutive 0s Resulting 5-bit codes are transmitted using NRZI Achieves 80% efficiency  Because 5 th bit is redundant. Used by FDDI 01??? but not 001?? ??100 but not ?1000

CSS Encoding Example Bits NRZ Clock Manchester NRZI

CSS Framing Break sequence of bits into a frame Typically implemented by a network adaptor Frame Bits Adaptor Node BNode A

CSS Approaches HeaderBody CRC Beginning sequence Ending sequence Sentinel-based  delineate frame with special pattern:  e.g., HDLC, SDLC, PPP  problem: ending sequence appears in the payload  solution: bit stuffing sender: insert 0 after five consecutive 1s receiver: delete 0 that follows five consecutive 1s Counter-based  include payload length in header  e.g., DDCMP Frame error  problem: count field corrupted (frame error)  solution: Wait for the next beginning sequence Catch when CRC fails

CSS Approaches (cont) Clock-based  each frame is 125us long  e.g., SONET: Synchronous Optical Network  STS-n (STS-1 = Mbps ) Interleaved every byte: keep 51Mbps for each STS-1

CSS Error Detections Add k bits of redundant data to an n-bit message  want k << n (i.e. k is extremely small as compared to n)  e.g., k = 32 and n = 12,000 (1500 bytes) in CRC-32 Parity Bit Internet Checksum Algorithm Cyclic Redundancy Check

CSS Parity Odd parity Even parity Two-dimensional parity Parity bits Parity byte Data

CSS Internet Checksum Algorithm View message as a sequence of 16-bit integers; Convert each 16-bit integer into a ones-complement arithmetic Sum up each integer Increment the result upon a carryout Example: u_short cksum(u_short *buf, int count) { register u_long sum = 0; while (count--) { sum += *buf++; if (sum & 0xFFFF0000) { // carry occurred, so wrap around sum &= 0xFFFF; sum++; } return ~(sum & 0xFFFF); } 5: : : : (-3): w/ carry: This corresponds to -8 Ones-complement message What if 5 and 3 were changed In 6 and 2 ?

CSS Cyclic Redundancy Check Represent n-bit message as n-1 degree polynomial  e.g., MSG= as M(x) = x 7 + x 4 + x 3 + x 1 Let k be the degree of some divisor polynomial  e.g., C(x) = x 3 + x sender receive r M(x)2 k – M(x) 2 k % C(x) = C(x)-divisible message: P(x) If P(x) % C(x) == 0 P(x) was sent successfully

CSS CRC (cont) Sender polynomial M(x)  M(x) = , C(x) = 1101, thus k = 3  M(x)2 3 = (<< 3)  M(x)2 3 % C(x) = 101  M(x)2 3 – M(x)2 3 % C(x) = = P(x) Noise polynomial E(x) Receiver polynomial P(x) + E(x)  E(x) = 0 implies no errors (P(x) + E(x)) % C(x) == 0 if:  E(x) was zero (no error), or  E(x) is exactly divisible by C(x) To retrieve M(x): P(x) / 2 3, (truncate the last 3 bits) Just appended The last 3 bits of P(x) eor eor eor eor eor eor

CSS CRC Calculation Using Shift Register sender receive r M(x) CRC CRC + M(x) M(x) CRC’ If CRC == CRC’, no errors x0x0 x1x1 x2x2 x0x0 x1x1 x2x Example: M(x) = C(x) = will be transferred.

CSS Acknowledgements & Timeouts Receiver can’t distinguish if the 1 st and 2 nd frames are identical

CSS Stop-and-Wait Stop a transmission and wait for ack to return or timeout Add 1-bit sequence number to detect a duplication of the same frame Problem: Can’t utilize the link’s capacity Example  1.5Mbps link x 45ms RTT = 67.5Kb (8KB)  If the frame size is 1KB and the sender waits for 45ms RTT 1KB for 45ms RTT 1/8th link utilization SenderReceiver Frame 0 Frame 1 Frame 0 Ack 0 Ack 1

CSS Sliding Window Allow multiple outstanding (un-ACKed) frames Upper bound on un-ACKed frames, called window SenderReceiver T ime … …

CSS SW: Sender Assign sequence number to each frame ( SeqNum ) Maintain three state variables:  Send window size ( SWS )  Last acknowledgment received ( LAR )  Last frame sent ( LFS ) Maintain invariant: LFS - LAR <= SWS Advance LAR when ACK arrives Buffer/Back up to SWS frames for future retransmission  SWS LARLFS ……

CSS SW: Receiver Maintain three state variables  Receive window size ( RWS )  Largest frame acceptable ( LFA )  Last frame received ( LFR ) Maintain invariant: LFA - LFR <= RWS Frame SeqNum arrives:  if LFR < SeqNum < = LFA accept  if SeqNum LFA discarded Send cumulative ACKs  RWS LFRLFRLFA …… Send a comulativeAck discard

CSS Sequence Number Space SeqNum field is finite; sequence numbers wrap around Sequence number space must be larger than # outstanding frames SWS <= MaxSeqNum-1 is not sufficient  suppose 3-bit SeqNum field (0..7)  SWS=RWS=7  sender transmit frames 0..6  arrive successfully, but ACKs lost  sender retransmits 0..6  receiver expecting 7, 0..5, but receives second incarnation of 0..5 SWS < (MaxSeqNum+1)/2 is a correct rule Intuitively, SeqNum “slides” between two halves of sequence number space

CSS Reviews  Encoding (NRZ, NRZI, Manchester, and 4B/5B)  Framing (Sentinel and counter-based)  Error Detections (Parity, Internet checksum, and CRC)  Stop-and-wait  Sliding window Exercises in Chapter 2  Ex. 2 and 5 (4B/5B, NRZI, and bit stuffing)  Ex. 16 (Internet Checksum)  Ex. 18 (CRC)  Ex. 24 (Sliding Window: Apply Ex. 25’s cases (a) and (b) to Ex. 24)