Outline

18-452/18-750 • Goals and structure of the course Networks and Applications • Administrative stuff Lecture 2: Wireless Challenges • A bit of history • Wireless technologies • Building a network Peter Steenkiste » Designing a BIG system Carnegie Mellon University » The OSI model » Packet-based communication » Challenges in Wireless Networking Spring Semester 2020 http://www.cs.cmu.edu/~prs/wirelessS20/

Peter A. Steenkiste, CMU 1 Peter A. Steenkiste, CMU 2

Why Use Wireless? What is Hard about Wireless?

There are no wires! There are no wires!

Has several significant advantages: • In wired networks links are constant, reliable and • Supports mobile users physically isolated » Move around office, campus, city, … - users get hooked » A 1 Gps always has the same properties » Remote control devices (TV, garage door, ..) » Not true for “54 Mbs” 802.11a and definitely not for “6 Gbs” 802.11ac » Cordless phones, cell phones, .. » WiFi, GPRS, Bluetooth, … • In wireless networks links are variable, error- prone and share the ether with each other and • No need to install and maintain wires other external, uncontrolled sources » Reduces cost – important in offices, hotels, … » Link properties can be extremely dynamic » Simplifies deployment – important in homes, hotspots, … » For mobile devices they also differ across locations

Peter A. Steenkiste, CMU 3 Peter A. Steenkiste, CMU 4

Page 1 Wireless is a shared medium Attenuation and Errors

Bob Mary • In wired communication, Bob Mary signals are contained in a conductor • In wired networks error rate 10-10 or less » Copper or fiber » Wireless networks are far from that target » Guides energy to destination » Protects signal from external • Signal attenuates with distance and is signals affected by noise and competing signals • Wireless communication • Obstacles further attenuate the signal uses broadcasting over • Probability of a successful reception depends the shared ether on the “signal to interference and noise ratio” » Energy is distributed in space - the SINR » Signal must compete with many other signals in same frequency band • More details later in the course

Peter A. Steenkiste, CMU 5 Peter A. Steenkiste, CMU 6

How Do We Increase Mobility Affects the Network Capacity? Link Throughput

Bob Bob Mary  Quality of the  Easy to do in wired networks: simply add wires transmission depends » Fiber is especially attractive on distance and obstacles blocking the  Adding wireless “links” “line of sight” (LOS) increases interference. » “Slow fading” – the signal strength changes slowly » Frequency reuse can help … subject to spatial limitations  Reflections off » Or use different frequencies … subject to frequency limitations obstacles combined with mobility can cause  The capacity of the wireless “fast fading” Mary network is fundamentally » Very rapid changes in the signal limited. » More on this later  Hard to predict signal!

Peter A. Steenkiste, CMU 7 Peter A. Steenkiste, CMU 8

Page 2 Implications of Variability How is Wireless Different? in Wireless PHY Layer

Wired Wireless • Wireless datalink protocols must optimize • Physical link properties • Physical link properties throughput across an unknown and dynamic are fixed and specified in can change rapidly in transmission medium standards unpredictable ways » Important to understand what causes the changes • Designed for low error • Error rates vary a lot • Wireless “links” as observed by layers 3-7 rates and throughput is and throughput is very will be unavoidably different from wired links fixed and known dynamic » Variable and latency • Datalink layer is simple • How do you design an » Intermittent connectivity and optimized for the efficient datalink » Must adapt to changes in connectivity and bandwidth physical layer protocol? • Understanding the physical layer is the key to • was designed • How well will higher making wireless work well assuming low error rates layer protocols work? » High level intuition is sufficient

Peter A. Steenkiste, CMU 9 Peter A. Steenkiste, CMU 10

Outline From Signals to Packets

Packet • RF introduction Transmission Sender Receiver » A cartoon view

» Communication 0100010101011100101010101011101110000001111010101110101010101101011010111001 » Time versus frequency view Packets Header/Body Header/Body Header/Body • Modulation and • Channel capacity Bit Stream 0 0 1 0 1 1 1 0 0 0 1 • Antennas and signal propagation • Modulation “Digital” Signal • Diversity and coding • OFDM Analog Signal

Peter A. Steenkiste, CMU 11 Peter A. Steenkiste, CMU 12

Page 3 RF Introduction Wireless Spectrum in the US

• RF = Radio Frequency » Electromagnetic signal that propagates through “ether” » Ranges 3 KHz .. 300 GHz » Or 100 km .. 0.1 cm (wavelength)

• Travels at the speed of light • Can take both a time and a frequency view

Peter A. Steenkiste, CMU 13 Peter A. Steenkiste, CMU 14

Cartoon View 1 – Cartoon View 2 – A Wave of Energy Rays of Energy

• Think of it as energy that radiates from an • Can also view it as a “ray” that propagates antenna and is picked up by another antenna. between two points • Helps explain properties such as attenuation » Rays can be reflected etc. » Density of the energy reduces over time, distance » A channel can include multiple “rays” that take different paths – “multi-path” effect » Signal strength is reduced, error rates go up • Implications for wireless networks • Relevance to networking? » We can have provide connectivity without line of sight! » Error rates of “wireless” depend on distance » Receiver can receive multiple copies of the signal, which – Also depends on many properties leads to signal distortion » Notion spatial reuse of frequencies » Combined with mobility, it also leads to fast fading – Basis of cellular and WiFi infrastructures

Peter A. Steenkiste, CMU 15 Peter A. Steenkiste, CMU 16

Page 4 (Not so) Cartoon View 3 – Time and Point View of Signal Electro-magnetic Signal

• Signal that propagates and changes over • Can look at a point in space: signal will change time with a certain frequency and has an in time according to a sine function amplitude and phase » But transmitter can change phase, amplitude, frequency • Can take a snapshot in time: signal will “look” » Think: sine wave like a sine function in space • Relevance to networking? » Signal at different points are (rough) copies of each other » The sender can change the properties of the EM signal • Receiver can observe transmitter’s changes over time to convey information » Receivers can observe these changes and extract the Relevance to information Received Networking? Signal Time (point in space)

Transmitter Peter A. Steenkiste, CMU 17 Peter A. Steenkiste, CMU Space (snapshot in time) 18

Communication Sine Wave Parameters

Remember: Received • General sine wave Cartoon view Signal Time (point in space) » s(t ) = A sin(2ft + ) • Example on next slide shows the effect of varying each of the three parameters Transmitter Space (snapshot in time) a) A = 1, f = 1 Hz,  = 0; thus T = 1s b) Reduced peak amplitude; A=0.5 • Sender changes signal in agree upon way and c) Increased frequency; f = 2, thus T = ½ receiver interprets the changes d) Phase shift;  = /4 radians (45 degrees) » “Modulation” and “demodulation” • note: 2 radians = 360° = 1 period • Problem: the signal gets distorted on “channel” » Makes it harder for receiver to interpret changes

Peter A. Steenkiste, CMU 19 Peter A. Steenkiste, CMU 20

Page 5 Key Idea of Wireless Space and Time View Revisited Communication

• The sender sends an EM signal and changes its properties over time » Changes reflect a digital signal, e.g., binary or multi-valued signal » Can change amplitude, phase, frequency, or a combination • Receiver learns the digital signal by observing how the received signal changes » Note that signal is no longer a simple sine wave or even a periodic signal “The wireless telegraph is not difficult to understand. The ordinary telegraph is like a very long cat. You pull the tail in New York, and it meows in Los Angeles. The wireless is exactly the same, only without the cat.”

Peter A. Steenkiste, CMU 21 Peter A. Steenkiste, CMU 22

Outline Challenge

• RF introduction • Cats, really? This is very informal! » A cartoon view » Sender “changes signal” and receiver “observes changes” » Communication • designers need more precise » Time versus frequency view information about the performance of wireless • Modulation and multiplexing “links” • Channel capacity » Can the receiver always decode the signal? » How many Kbit, Mbit, Gbit per second? • Antennas and signal propagation » Does the physical environment, distance, mobility, weather, • Modulation season, the color of my shirt, etc. matter? • Diversity and coding • We need a more formal way of reasoning about wireless communication: • OFDM Represent the signal in the frequency domain!

Peter A. Steenkiste, CMU 23 Peter A. Steenkiste, CMU 24

Page 6 Time Domain View: Key Parameters of Periodic versus Aperiodic Signals (Periodic) Signal

• Periodic signal - analog or digital signal • Peak amplitude (A) - maximum value or strength of pattern that repeats over time the signal over time; typically measured in volts » s(t +T ) = s(t ) • Frequency (f ) – where T is the period of the signal » Rate, in cycles per second, or Hertz (Hz) at which the signal repeats » Allows us to take a frequency view – important to understand wireless challenges and solutions • Period (T ) - amount of time it takes for one repetition of the signal • Aperiodic signal - analog or digital signal » T = 1/f pattern that doesn't repeat over time • Phase () - measure of the relative position in time » Hard to analyze within a single period of a signal • Wavelength () - distance occupied by a single • Can “make” an aperiodic signal periodic cycle of the signal by taking a time slice T and repeating it » Or, the distance between two points of corresponding phase of two consecutive cycles » Often what we do implicitly

Peter A. Steenkiste, CMU 25 Peter A. Steenkiste, CMU 26

Key Property of Signal = Sum of Sine Waves Periodic EM Signals

• Any electromagnetic signal can be shown to consist of a collection of periodic analog signals (sine waves) at different amplitudes, frequencies, and phases = • The period of the total signal is equal to the period of the fundamental frequency » All other frequencies are an integer multiple of the + 1.3 X fundamental frequency • There is a strong relationship between the “shape” of the signal in the time and frequency + 0.56 X domain » Discussed in more detail later + 1.15 X

Peter A. Steenkiste, CMU 27 Peter A. Steenkiste, CMU 28

Page 7 Outline The Frequency Domain

• A (periodic) signal can be viewed as a sum of sine waves of different strengths. • RF introduction • Corresponds to energy at a certain frequency • Modulation and multiplexing - review • Every signal has an equivalent representation in the » Analog versus digital signals frequency domain. • What frequencies are present and what is their strength (energy) » Forms of modulation » Baseband versus carrier modulation • We can translate between the two formats using a fourier transform » Multiplexing • Channel capacity Bandwidth • Antennas and signal propagation • Modulation

Amplitude • Diversity and coding Time • OFDM Frequency

Peter A. Steenkiste, CMU 29 Peter A. Steenkiste, CMU 30

Amplitude and Frequency Signal Modulation Modulation

• Sender sends a “carrier” signal and changes it in a way that the receiver can recognize • The carrier is sine wave with fixed amplitude and frequency • Amplitude modulation (AM): change the strength 0 0 1 1 0 0 1 1 0 0 0 1 1 1 0 0 0 1 1 0 0 0 1 1 1 0 of the carrier based on information • High values -> stronger signal • Frequency (FM) and phase modulation (PM): change the frequency or phase of the signal • Frequency or Phase shift keying • Digital versions are also called “shift keying” 0 1 1 0 1 1 0 0 0 1 • Amplitude (ASK), Frequency (FSK), Phase (PSK) Shift Keying • Discussed in more detail in a later the course

Peter A. Steenkiste, CMU 31 Peter A. Steenkiste, CMU 32

Page 8 Analog and Digital Signal Amplitude Carrier Modulation Modulation

• The signal that is used to modulate the carrier can be analog or digital » Analog: broadcast radio (AM/FM) » Digital: WiFi, LTE • Analog: a continuously varying signal » Cannot recover from distortions, noise » Can amplify the signal but also amplifies the noise • Digital: discreet changes in the signal that correspond to a digital signal » Can recover from noise and distortion: » Regenerate signal along the path: demodulate + remodulate Signal Carrier Modulated Frequency Carrier

Peter A. Steenkiste, CMU 33 Peter A. Steenkiste, CMU 34

Multiplexing Multiplexing Techniques

• Capacity of the transmission medium usually • Frequency-division multiplexing (FDM) exceeds the capacity required for a single signal » divide the capacity in the frequency domain • Multiplexing - carrying multiple signals on a • Time-division multiplexing (TDM) single medium » Divide the capacity in the time domain » Fixed or variable length time slices » More efficient use of transmission medium • A must for wireless – spectrum is huge! » Signals must differ in frequency (spectrum), time, or space

Peter A. Steenkiste, CMU 35 Peter A. Steenkiste, CMU 36

Page 9 Multiple Users Can Frequency versus Share the Ether Time-division Multiplexing

 With frequency-division multiplexing different users use different parts of the frequency spectrum. Frequency » I.e. each user can send all the time at reduced rate Frequency Bands » Example: roommates » Hardware is slightly more expensive Frequency and is less efficient use of spectrum  With time-division multiplexing different users send at different times. » I.e. each user can sent at full speed Slot some of the time Frame » Example: a time-share condo » Drawback is that there is some transition time between slots; Different users use becomes more of an issue with Different carrier frequencies longer propagation times  The two solutions can be Time combined.

Peter A. Steenkiste, CMU 37 Peter A. Steenkiste, CMU 38

Frequency Reuse in Space

• Frequencies can be reused in space » Distance must be large enough » Example: radio stations • Basis for “cellular” network architecture • Set of “base stations” connected to the wired network support set of nearby clients » Star topology in each circle » Cell phones, 802.11, …

Peter A. Steenkiste, CMU 39

Page 10