Professional Documents
Culture Documents
Advanced Networks Lectur 5
Advanced Networks Lectur 5
Lecture #5
Instructor: Dr. Niamat Ullah
DirectLinkNetworks - 1
1. PhysicalConnectingHosts
2. Hardware BuildingBlocks (NodesandLinks)
3. Encoding (NRZ, NRZI, Manchester, 4B/5B)
4. Framing
DataLinkLayer
Diferent functionsat the link level
Encoding
Framing
Error detection/correction
Reliabledelivery
Media accesscontrol
Directly-ConnectedNetworks
multiple access
4
PhysicalMedium
Signalstravelthrough the medium andrepresentbits
ShannonsCapacityTheorem
C = B log2(1+S/N)
Defnesthe upper bound on the linkcapacity C in Hz
Can be used toevaluate the error-freebandwidth of aline
5
ShannonsTheorem: Example
dB = 10 xlog10(S/N)
Encoding
Mapbinarybitsintosignals
Example: Lowsignal representsa 0, high signal representsa 1
Non Return-to-Zero (NRZ)
Problem: Longperiodsof silence (zero) orhigh signalsarepossible
Baselinewander (receiverloses trackof referencesig)
Clockrecovery (receiverloses clocksynchronization)
Encoding: MoreSchemes
This solves the problemof consecutive 1s, but obviously doesnothing for
consecutive 0s.
Because both 0sand 1s result ina transition to the signal, theclock can be
efectively recoveredat thereceiver.
TheproblemwiththeManchesterencoding
schemeisthatitdoublestherateatwhichsignal
transitionsaremade onthelink, whichmeansthat
thereceiverhashalfthetimetodetect eachpulseof
thesignal. Therateatwhichthesignalchangesis
calledthelinks baudrate.
In thecaseoftheManchesterencoding, thebit rate
ishalfthebaudrate, sotheencodingisconsidered
only 50% efcient.
4B/5BEncodingScheme
Exampleof 4B/5BEncoding
4-bit data
symbol
5-bit code
4-bit data
symbol
5-bit code
0000
11110
1000
10010
0001
01001
1001
10011
0010
10100
1010
10110
0011
10101
1011
10111
0100
01010
1100
11010
0101
01011
1101
11011
0110
01110
1110
11100
0111
01111
1111
11101
Thus, when sent back-to-back, no pair of 5-bit codes results in more than three
consecutive 0s being transmitted. The resulting 5-bit codes are then transmitted
using the NRZI encoding, which explains why the code is only concerned about
consecutive 0sNRZI already solves the problem of consecutive 1s.
The 4B/5B encoding results in 80% efficiency.
11
Framing
The processofgroupingbitsintoframes (messagesorpackets)
Typicallyimplementedbythenetworkadaptor
Whyframes?
12
Byte-OrientedFraming
BISYNC: Binarysynchronouscommunication
Frame isa collection ofbytes
Needto indicatethebeginning andendof a frame
Sentinel charactersareused
Problem withByte-orientedFraming
ETX may occur in the payload
Precede it with a DLE (data-link-escape) character
Problem propagates, precede DLE with another
DLE (extra overhead)
Point-to-Point (PPP) protocol used by IP
STX: 0111110
Payload: 1,500 bytes
Checksum: 2 or 4 bytes
Byte-countingFraming
Bit-orientedFraming
High-LevelData LinkControl (HDLC)
Sender
ExampleofBit-stufng
1111110111111111110111110
Receiver
11111010111110111110101111100
17
DirectLinkNetworks 11
1. Error Detection
2. Ethernet (IEEE 802.3)
Checksum
802.3 Ethernet
Carrier-sense multiple access with collision detection
(CSMA/CD).
CS = carrier sense
MA = multiple access
CD = collision detection
Base Ethernet standard is 10 Mbps.
100Mbps, 1Gbps, 10Gbps standards came later
Ethernet CSMA/CD
CSMA/CD (carrier sense multiple access with collision
detection) media access protocol is used.
Data is transmitted in the form of packets.
Sense channel prior to actual packet transmission.
Transmit packet only if channel is sensed idle; else,
defer the transmission until channel becomes idle.
After packet transmission is started, the node monitors
its own transmission to see if the packet has
experienced a collision.
If the packet is observed to be undergoing a collision,
the transmission is aborted and the packet is
retransmitted after a random interval of time using
Binary Exponential Backoff algorithm.
CSMA/CD (Ctnd..)
After first collision, each station waits for 0 or 1 slot before
trying again.
After second collision, they pick either 0, 1, 2, or 3 slots at
random to wait.
After 3rd. collision, number of slots to wait is between 0 and 23
-1.
In general, after I collisions, wait is between 0 and 2i 1.
After 10 collisions, randomization interval frozen at 1023
slots.
After 16 collisions, error!
Length
Ethernet
Physical Media :10 Base5
10 Base2
10 BaseT
10 BaseFL
Fast Ethernet
100 Mbps bandwidth
Uses same CSMA/CD media access protocol and packet
format as in Ethernet.
100BaseTX (UTP) and 100BaseFX (Fiber) standards
Physical media :100 BaseTX - UTP Cat 5e
100 BaseFX - Multimode / Singlemode Fiber
Full Duplex/Half Duplex operations.
Fast Ethernet
Provision for Auto-Negotiation of media speed:
10 Mbps or 100Mbps (popularly available for copper
media only).
Maximum Segment Length
100 Base TX - 100 m
100 Base FX - 2 Km (Multimode Fiber)
100 Base FX - 20 km (Singlemode Fiber)
Gigabit Ethernet
1 Gbps bandwidth.
Uses same CSMA/CD media access protocol as in Ethernet
and is backward compatible (10/100/100 modules are
available).
1000BaseT (UTP), 1000BaseSX (Multimode Fiber) and
1000BaseLX (Multimode/Singlemode Fiber) standards.
Maximum Segment Length
1000 Base T
- 100m (Cat 5e/6)
1000 Base SX - 275 m (Multimode Fiber)
1000 Base LX - 512 m (Multimode Fiber)
1000 Base LX - 20 Km (Singlemode Fiber)
1000 Base LH - 80 Km (Singlemode Fiber)
10 Gig Ethernet
10 Gbps bandwidth.
Uses same CSMA/CD media access protocol as in
Ethernet.
Propositioned for Metro-Ethernet
Maximum Segment Length
10GBase-LR
- 10 Km (Singlemode Fiber)
10GBase-ER
- 40 Km (Singlemode Fiber)