Slides Chapter 2
Slides Chapter 2
LayerChapter 2
• Theoretical Basis for Data
Communications
• Guided Transmission Media
• Wireless Transmission
• Communication Satellites
• Digital Modulation and Multiplexing
• Public Switched Telephone Network
• Mobile Telephone System
• Cable Television
Revised: February
2018
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
The Physical
Layer
Foundation on which other layers
build
• Properties of wires, fiber, Applicatio
wireless limit what the n
network can do Transport
Network
Link
Key problem is to send Physical
(digital) bits using only
(analog) signals
• This is called modulation
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Physical Layer
Issues
• Media: wires, fiber, satellites, radio
• Signal propagation: bandwidth, attenuation,
noise
• Modulation: how bits are represented as voltage
signals
• Fundamental limits: Nyquist, Shannon
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Abstract Model of a
Link
Channel: bit rate, delay, error
Sender rate Receiver
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Bandwidth-Delay
Product
• Bits have a physical size on the channel!
• Storage capacity of a channel is: bit rate x
delay
• Example:
• 100 Mbps 5000-km fiber, delay = 50
msec
• In 50 msec we can pump out 5 million
bits
• So the fiber can store 5 million bits in
5000 km
• 1 km holds 1000 bits so a bit is 1 meter
long
• CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Signal Propagation over a
Wire
• The signal has a finite propagation speed
(2/3 c)
• The signal is attenuated per km
• Frequencies above a cutoff are strongly
reduced
• Noise is added to the signal
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Theoretical Basis for Data
Communication
Communication rates have fundamental
limits
• Fourier analysis
• Bandwidth-limited signals
• Maximum data rate of a channel
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Sine
wave
g(t) = A sin (2 π f t
+ ϕ)
(Volts)
A
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Fourier
Analysis
A time-varying periodic signal can be
represented as a series of frequency
components (harmonics):
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Bandwidt
h
• At the signal level, bandwidth is cutoff
frequency (HZ)
• For data transmission it is bits/sec
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Bandwidth-Limited
Signals
Having less bandwidth (harmonics) degrades the
signal
8 harmonics
Lost!
Bandwidth
4
harmonics
Lost!
2
harmonics
Lost!
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Maximum Data Rate of a Channel -
Nyquist
Nyquist’s theorem relates the data rate to the
bandwidth (B) and number of signal levels (V) on a
noiseless channel:
Max. data rate = 2B log2V
bits/sec
• Examples
– 3000 Hz channel (tel. line), binary signals = 6000
bps
– 3000 Hz channel (tel. line), 4-level signals =
12,000 bps
– 3000 Hz channel (tel. line), 16-level signals =
48,000 bps
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Nyquist vs.
Shannon
• Nyquist:
- For noiseless channel
- Depends on number signal levels per
symbol
• Shannon
- For noisy channel
- Depends on S/N ratio, not bits/symbol
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Guided Transmission (Wires &
Fiber)
Media have different properties, hence
performance
• Reality check
– Physical transport of storage media
• Wires:
– Twisted pairs
– Coaxial cable
– Power lines
• Fiber cables
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Transporting Physical
Media
• AST 1990: Never underestimate the
bandwidth of a station wagon full of
tapes hurtling down the highway.
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Kinds of
Wire
• STP = Shielded Twisted Pair
• UTP = Unshielded Twisted
Pair
- Cat 3: Home telephone
lines
- Cat 5: Fast Ethernet (100
Mbps)
- Cat 5e: Gigabit Ethernet
(1 Gbps)
- Cat 6: 10-Gigabit
Ethernet (10 Gps) up to
100 m
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Connecto
rs
RJ11 – 4 RJ45 – 8
wires wires
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Link
Terminology
Simplex link
• Only one fixed direction at all times; not
common
Half-duplex link
• Both directions, but not at the same time
• e.g., senders take turns on a wireless
channel
Full-duplex link
• Used for transmission in both directions at
once
• e.g., use different twisted pairs for each
direction
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Wires – Coaxial Cable (“Co-
ax”)
Also common. Better shielding and more
bandwidth for longer distances and higher
rates than twisted pair.
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Wires – Power
Lines
Household electrical wiring is another example
of wires
• Convenient to use, but poor for sending data
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Fiber Optics
(1)
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Fiber Cables
(2)
Common for high rates and long distances
• Long distance ISP links, Fiber-to-the-
Home
• Light carried in very long, thin strand
of glass
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Fiber Cables
(3)
Fiber has enormous bandwidth (THz) and tiny
signal loss – hence high rates over long
distances
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Fiber Cables
(3)
Single-mode
• Core so narrow (10um) light
can’t even bounce around
• Used with lasers for long
distances, e.g., 100km
Multi-mode
• Other main type of fiber
• Light can bounce (50um core)
• Used with LEDs for cheaper,
shorter distance links
Fibers in a
cable
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
TAT-14 TransAtlantic
Cable
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Wireless
Transmission
• Electromagnetic
Spectrum
• Radio Transmission
• Microwave
Transmission
• Light Transmission
• Wireless vs. Wires/Fiber
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Electromagnetic
Spectrum (1)
Different bands have different
uses:
– Radio: wide-area broadcast; Infrared/Light: line-
of-sight
– Microwave: LANs and 3G/4G; Networking
focus
Microwave
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Electromagnetic
Spectrum (2)
To manage interference, spectrum is carefully
divided, and its use regulated and licensed,
e.g., sold at auction.
300 3
MHz GHz
WiFi (ISM
3 Source: NTIA Office of Spectrum Management, bands) 30
2003
GHz GHz
Part of the US frequency
allocations
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Electromagnetic
Spectrum (3)
Fortunately, there are also unlicensed (“ISM”)
bands:
– Free for use at low power; devices manage
interference
– Widely used for networking; WiFi, Bluetooth, etc.
802.1 802.11a/g/
1 n/ac
b/g/n
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Radio
Waves
• Radio waves have a frequency, f, in
Hz
• They have a wavelength, λ in meters
• λf = c in vacuum
• Speed of radio/light = 1 foot/nsec
• For microwaves, megahertz x meters
= 300
– 300 MHz waves are 1 meter long
– 1 GHz waves are 30 cm long
– 2.4 GHz waves are 12.5 cm long
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Radio
Transmission
Radio signals penetrate buildings well and
propagate for long distances with path loss
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Microwave
Transmission
Microwaves have much bandwidth and are
widely used indoors (WiFi) and outdoors (3G,
satellites)
• Signal is attenuated/reflected by everyday
objects
• Strength varies with mobility due multipath
fading, etc.
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Light
Transmission
Line-of-sight light (no fiber) can be used for
links
• Light is highly directional, has much
bandwidth
• Use of LEDs/cameras and
lasers/photodetectors
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Wireless vs.
Wires/Fiber
Wireless:
+ Easy and inexpensive to deploy
+ Naturally supports mobility
+ Naturally supports broadcast
– Transmissions interfere and must be managed
– Signal strengths hence data rates vary greatly
Wires/Fiber:
+ Easy to engineer a fixed data rate over point-
to-point links
– Can be expensive to deploy, esp. over distances
– Doesn’t readily support mobility or broadcast
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Communication
Satellites
Satellites are effective for broadcast
distribution and anywhere/anytime
communications
• Kinds of Satellites
• Geostationary (GEO) Satellites
• Low-Earth Orbit (LEO) Satellites
• Satellites vs. Fiber
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Kinds of
Satellites
Satellites and their properties vary by altitude:
• Geostationary (GEO), Medium-Earth Orbit
(MEO), and Low-Earth Orbit (LEO)
Sats needed
for global
coverage
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Geostationary Satellites
(1)
GEO satellites orbit 36,000 km above a fixed
location
• VSAT (computers) can communicate with the help
of a hub
• Up and down time is about 250 msec
• Big problem for voice
GEO satellite
VSA
T
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Geostationary Satellites
(2)
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Low-Earth Orbit Satellites
(2)
Relaying in
space.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Low-Earth Orbit Satellites
(3)
Relaying on the
ground
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Satellite vs.
Fiber
Satellite:
+ Can rapidly set up anywhere/anytime
communications (after satellites have been
launched)
+ Can broadcast to large regions
– Limited bandwidth and interference to manage
Fiber:
+ Enormous bandwidth over long distances
– Installation can be more expensive/difficult
– Doesn’t work at sea or in remote areas
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Digital Modulation and
Multiplexing
Modulation schemes send bits as signals
Multiplexing schemes share a channel among
users.
• Baseband Transmission
• Passband Transmission
• Frequency Division Multiplexing
• Time Division Multiplexing
• Code Division Multiple Access
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Baseband
Transmission
Line codes send symbols that represent one or
more bits
• NRZ is the simplest, literal line code (+1V=“1”,
-1V=“0”)
• Other codes tradeoff bandwidth and signal
transitions
Strategies:
Manchester coding, mixes clock signal in every
symbol 4B/5B maps 4 data bits to 5 coded bits
with 1s and 0s:
Data Code Data Code Data Code Data Code
0000 11110 0100 01010 1000 10010 1100 11010
0001 01001 0101 01011 1001 10011 1101 11011
0010 10100 0110 01110 1010 10110 1110 11100
0011 10101 0111 01111 1011 10111 1111 11101
Amplitude shift
keying Frequency
shift keying
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Passband Transmission
(2)
Constellation diagrams are a shorthand to
capture the amplitude and phase modulations
of symbols:
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Frequency Division
Multiplexing
FDM (Frequency Division Multiplexing)
shares the channel by placing users on
different frequencies:
Overall FDM
channel
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Frequency Hopping Spread
Spectrum
• WiFi and Bluetooth change frequencies many
times/sec
• Called “frequency hopping”
• Invented by sex-goddess Hedy Lamarr
• She patented it, but Navy wasn’t interested
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Time Division Multiplexing
(TDM)
Time division multiplexing shares a channel
over time:
• Users take turns on a fixed schedule; this
is not packet switching or STDM
(Statistical TDM)
• Widely used in telephone / cellular
systems
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Code Division Multiple Access
(1)
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Public Switched Telephone
Network
• Structure of the telephone
system
• Politics of telephones
• Local loop: modems, ADSL, and
FttH
• Trunks and multiplexing
• Switching
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Structure of the Telephone
System (1)
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Structure of the Telephone
System (3)
Major Components
• Local loops analog twisted pairs to houses,
businesses).
• Trunks (digital fiber optic links between switching
offices).
• Switching offices (calls are moved from one
trunk to another)
• Core of phone system is optical & digital in
Europe, US
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Politics of
Telephones
There is a distinction for competition between
serving a local area (LECs) and connecting to a
local area (at a POP) to switch calls across areas
(IXCs)
• Customers of a LEC can dial via any IXC they
choose
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Physics of Cat 3
Wiring
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Local loop (1): Acoustic
Couplers
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Local loop (3): Digital Subscriber
Lines
DSL broadband sends data over the local loop to
the local office using frequencies that are not
used for POTS
• Telephone/
computers attach
to the same old
phone line
• Rates vary with line
– ADSL2 up to 24
Mbps
– VDSL2 to 100
Mbps
• OFDM used to 1.1
MHz CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Local loop (4): Fiber To The
Home
FttH broadband relies on deployment of
fiber optic cables to provide high data
rates customers
• One wavelength can be shared among
many houses
• Fiber is passive (no amplifiers, etc.)
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Pulse Code Modulation
(1)
Calls are carried digitally on PSTN trunks using
TDM
• A call is an 8-bit PCM sample each 125 µs (64
kbps)
• Traditional T1 carrier has 24 call channels
each 125 µs (1.544 Mbps)
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
SONET/SDH
(2)
SONET (Synchronous Optical NETwork) is the
worldwide standard for carrying digital signals on
optical trunks
• Keeps 125 µs frame; base frame is 810 bytes
(52Mbps)
• Payload “floats” within framing for flexibility
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
SONET/SDH
(3)
Hierarchy at 3:1 per level is used for higher
rates
• Each level also adds a small amount of
framing
• Rates from 52 Mbps (STS-1) to 40 Gbps (STS-
768)
SONET/SDH rate
hierarchy
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Wavelength Division
Multiplexing
WDM (Wavelength Division Multiplexing),
another name for FDM, is used to carry many
signals on one fiber:
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Circuit Switching/Packet
Switching (1)
Switch
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Generations of mobile telephone
systems
• 1G, analog voice
– AMPS (Advanced Mobile Phone System) is example,
deployed from 1980s. Modulation based on FM (as in
radio).
• 2G, analog voice and digital data
– GSM (Global System for Mobile communications) is
example, deployed from 1990s. Modulation based on
QPSK.
• 3G, digital voice and data
– UMTS (Universal Mobile Telecommunications System)
is example, deployed from 2000s. Modulation based
on CDMA
• LTE, digital data including voice
– LTE (Long Term Evolution) is example, deployed from
2010s. Modulation based on OFDM
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
2G GSM – Global System for
Mobile Communications
(1)
• Mobile is divided into handset and SIM
card (Subscriber Identity Module) with
credentials
• Mobiles tell their HLR (Home Location
Register) their current whereabouts for
incoming calls
• Cells keep track of visiting mobiles (in the
Visitor LR)
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
2G GSM – Global System for
Mobile Communications
Air interface(2)
is based on FDM channels of
200 KHz divided in an eight-slot TDM frame
every 4.615 ms
• Mobile is assigned up- and down-stream
slots to use
• Each slot is 148 bits long, gives rate of
27.4 kbps
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
2G GSM—The Global System for
Mobile Communications
(3)
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
3G UMTS – Universal Mobile
Telecommunications System (1)
Architecture is an evolution of GSM; terminology
differs Not compatible with 2G GSM
Intern
et
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
3G UMTS – Universal Mobile
Telecommunications System (2)
Air interface based on CDMA over 5 MHz
channels
• Rates over users <14.4 Mbps (HSPDA) per
5 MHz
• CDMA permits soft handoff (connected to
both cells)
Soft
hando
ff
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
4
G
• ITU defined spec in 2008, before the technology
existed
• ITU can’t enforce what carriers do or call their
services
• Pure IPv6 packet switching, no circuit switching
• No voice (except as VoIP)
• 1 Gbps for stationary user, 100 Mbps for moving
user
• Uses carrier aggregation (multiple bands
together)
• Uses OFDMA (Orthogonal Freq. Div. Mux Access)
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
OFDM
A
0 1 0 0 1 0 1 1 0 1 1 1 0 0 1 0 1 0 1
1
Channel 1 Channel 2 Channel 3 Channel 4
0 1 1 0
1 0 1 1
0 1 1 1
0 0 1 0
1 0 1 1
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Cable
Television
• Internet over
cable
• Spectrum
allocation
• Cable modems
• ADSL vs. cable
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Community Antenna
Television
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Internet over
Cable
Internet over cable reuses the cable television
plant
• Data is sent on the shared cable tree from the
head- end, not on a dedicated line per
subscriber (DSL)
ISP
(Interne
t)
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Internet over Telephone
System
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Cable
Modems
Cable modems at customer premises
implement the physical layer of the DOCSIS
standard
• QPSK/QAM is used in timeslots on
frequencies that are assigned for
upstream/downstream data
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
Comparison of Cable and
Telephone
Item Cable Telephone Internet
Internet
Type of wiring Shared Dedicated
Interference from Possible Impossible
neighbors
Wiring Coax CAT 3 twisted pair
Age of system Newer Very old
Max speed 400 Mbps 100 Mbps (copper)
Fiber possible? No Yes
Security Poor Good
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
En
d
Chapter
2
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011
CN5E by Tanenbaum & Wetherall, © Pearson Education-Prentice Hall and D. Wetherall, 2011