Outline - PowerPoint PPT Presentation

1 / 24
About This Presentation
Title:

Outline

Description:

Leased Lines: T1(DS1), T3(DS3), OC-1(STS-1),OC-3(STS-3),OC-48(STS-48,2.48Gbps) ... receiver expecting 7, 0..5, but receives second incarnation of 0..5 ... – PowerPoint PPT presentation

Number of Views:35
Avg rating:3.0/5.0
Slides: 25
Provided by: klp15
Learn more at: http://www.cs.uky.edu
Category:

less

Transcript and Presenter's Notes

Title: Outline


1
11. Physical Layer
  • Outline
  • Building Blocks
  • Shannons Theorem
  • Encoding

2
Building Blocks
  • Node
  • Network Adaptor (memory is the speed bottleneck)
  • Router (input ports, switch fabric, output ports)
  • Links
  • C f ?
  • Cables
  • Leased Lines T1(DS1), T3(DS3),
    OC-1(STS-1),OC-3(STS-3),OC-48(STS-48,2.48Gbps)
  • Last mile links modem, xDSL, ISDN, cable modem

3
Shannons Theorem
  • C B log (1S/N)
  • C channel capacity, in bps
  • B bandwidth, in hertz
  • S average signal power
  • N average noise power
  • dB 10 log (S/N)
  • dB signal-noise ratio expressed in decibels

2
10
4
Shannons Theorem
  • Example
  • B 300 Hz to 3300 Hz
  • N/S 30 dB
  • C 3000 log (1001) 30 Kbps

2
5
Encoding
  • Signals propagate over a physical medium
  • modulate electromagnetic waves
  • e.g., vary voltage
  • Schemes
  • NRZ
  • NRZI
  • Manchester
  • 4B/5B

6
12. Data Link Layer
  • Outline
  • Framing
  • Error Detection
  • Sliding Window Algorithm
  • Token rings (FDDI)
  • Wireless

7
Data Link Layer
  • Data Link Layer
  • Framing
  • Error Detection
  • Sliding Window (reliable transmission, flow
    control)
  • Medium Access Control (MAC) Sub-Layer
  • Token ring (FDDI)
  • Wireless
  • Logical Link Control (LLC) IEEE802.2

8
Framing
  • Break sequence of bits into a frame
  • Typically implemented by network adaptor

9
Approaches
  • Sentinel-based
  • delineate frame with special pattern 01111110
  • e.g., HDLC, SDLC, PPP
  • problem special pattern appears in the payload
  • solution bit stuffing
  • sender insert 0 after five consecutive 1s
  • receiver delete 0 that follows five consecutive
    1s

10
Approaches (cont)
  • Counter-based
  • include payload length in header
  • e.g., DDCMP
  • problem count field corrupted
  • solution catch when CRC fails

11
Approaches (cont)
  • Clock-based
  • each frame is 125us long
  • e.g., SONET Synchronous Optical Network
  • STS-n (STS-1 51.84 Mbps)

12
Error Detection
  • Parity
  • Two-dimensional parity
  • Internet Checksum
  • CRC

13
Cyclic Redundancy Check (CRC)
  • Add k bits of redundant data to an n-bit message
  • want k ltlt n
  • e.g., k 32 and n 12,000 (1500 bytes)
  • Represent n-bit message as n-1 degree polynomial
  • e.g., MSG10011010 as M(x) x7 x4 x3 x1
  • Let k be the degree of some divisor polynomial
  • e.g., C(x) x3 x2 1
  • Modulo 2 operation (XOR)

14
CRC (cont)
  • Transmit polynomial P(x) that is evenly divisible
    by C(x)
  • shift left k bits, i.e., M(x)xk
  • subtract remainder of M(x)xk / C(x) from M(x)xk
  • Receiver polynomial P(x) E(x)
  • E(x) 0 implies no errors
  • Divide (P(x) E(x)) by C(x) remainder zero if
  • E(x) was zero (no error), or
  • E(x) is exactly divisible by C(x)

15
Selecting C(x)
  • All single-bit errors, as long as the xk and x0
    terms have non-zero coefficients.
  • All double-bit errors, as long as C(x) contains a
    factor with at least three terms
  • Any odd number of errors, as long as C(x)
    contains the factor (x 1)
  • Any burst error (i.e., sequence of consecutive
    error bits) for which the length of the burst is
    less than k bits.
  • Most burst errors of larger than k bits can also
    be detected
  • See Table 2.6 on page 102 for common C(x)

16
Sliding Window
  • Stop and wait
  • Selective repeat
  • Go back N

17
Acknowledgements Timeouts
18
Stop-and-Wait
Sender
Receiver
  • Two sequence numbers (0 and 1)
  • Problem keeping the pipe full
  • Example
  • 1.5Mbps link x 45ms RTT 67.5Kb (8KB)
  • 1KB frames imples 1/8th link utilization

19
Sliding Window
  • Allow multiple outstanding (un-ACKed) frames
  • Upper bound on un-ACKed frames, called window

20
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 lt SWS
  • Advance LAR when ACK arrives
  • Buffer up to SWS frames

21
SW Receiver
  • Maintain three state variables
  • receive window size (RWS)
  • largest frame acceptable (LFA)
  • last frame received (LFR)
  • Maintain invariant LFA - LFR lt RWS
  • Frame SeqNum arrives
  • if LFR lt SeqNum lt LFA accept
  • if SeqNum lt LFR or SeqNum gt LFA
    discarded
  • Send cumulative ACKs


RWS


LFR
LFA
22
Sequence Number Space
  • SeqNum field is finite sequence numbers wrap
    around
  • Sequence number space must be larger then number
    of outstanding frames
  • SWS lt MaxSeqNum-1 is not sufficient
  • suppose 3-bit SeqNum field (0..7)
  • SWSRWS7
  • 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 lt (MaxSeqNum1)/2 is correct rule
  • Intuitively, SeqNum slides between two halves
    of sequence number space

23
Selective Repeat
  • At the receiver, it will send an ack for each
    frame received, even if the frame is out of
    order.
  • The sender sets a timeout value for each frame
    sent out, and will resend the frame upon timeout.
    The timeout flag is cleared when an ack for the
    frame is received.
  • Only those frames (or acks for them) are lost are
    retransmitted.
  • The receiver may need a large buffer to hold out
    of order frames.

24
Go Back N
  • At the receiver, it will send an ack for each
    frame received, only if the frame is out of
    order. Out of order frames are discarded. It also
    sends a NAK when it finds a frame is lost.
  • The timer mechanism is the same.
  • The acks are cumulative in the sense that an ack
    indicates that the receiver has got all the
    frames up to the frame acked.
  • The sender will resend all the frames starting
    from the frame for which a NAK is received.
  • The receiver does not need a large buffer to hold
    out of order frames.
Write a Comment
User Comments (0)
About PowerShow.com