1.2 Medium Access Control: Modulation and Demodulation (Reminder)

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 25

1.

2 MAC

1. Introduction
1.2 Medium Access Control

Prof. JP Hubaux

Modulation and demodulation (reminder)

analog
baseband
digital
signal
data digital analog
101101001 modulation modulation radio transmitter

radio
carrier

analog
baseband
digital
signal
analog synchronization data
demodulation decision 101101001 radio receiver

radio
carrier

2
1.2 MAC

Motivation
Can we apply media access methods from fixed networks?

Example of CSMA/CD
‰ Carrier Sense Multiple Access with Collision Detection
‰ send as soon as the medium is free, listen into the medium if a
collision occurs (original method in IEEE 802.3)
Problems in wireless networks
‰ signal strength decreases proportional to the square of the distance
or even more
‰ the sender would apply CS and CD, but the collisions happen at the
receiver
‰ it might be the case that a sender cannot “hear” the collision, i.e.,
CD does not work
‰ furthermore, CS might not work if, e.g., a terminal is “hidden”

Hidden and exposed terminals


Hidden terminals
‰ A sends to B, C cannot receive A
‰ C wants to send to B, C senses a “free” medium (CS fails)
‰ collision at B, A cannot receive the collision (CD fails)
‰ A is “hidden” for C

A B C
Exposed terminals
‰ B sends to A, C wants to send to another terminal (not A or B)
‰ C has to wait, CS signals a medium in use
‰ but A is outside the radio range of C, therefore waiting is not
necessary
‰ C is “exposed” to B

4
1.2 MAC

Motivation - near and far terminals


Terminals A and B send, C receives
‰ signal strength decreases proportional to the square of the distance
‰ the signal of terminal B therefore drowns out A’s signal
‰ C cannot receive A

A B C

If C for example was an arbiter for sending rights, terminal B would


drown out terminal A already on the physical layer
Also severe problem for CDMA-networks - precise power control
needed!

Access methods SDMA/FDMA/TDMA/CDMA


SDMA (Space Division Multiple Access)
‰ segment space into sectors, use directed antennas
‰ cell structure
FDMA (Frequency Division Multiple Access)
‰ assign a certain frequency to a transmission channel between a
sender and a receiver
‰ permanent (e.g., radio broadcast), slow hopping (e.g., GSM), fast
hopping (FHSS, Frequency Hopping Spread Spectrum)
TDMA (Time Division Multiple Access)
‰ assign the fixed sending frequency to a transmission channel
between a sender and a receiver for a certain amount of time
CDMA (Code Division Multiple Access)
‰ assign an appropriate code to each transmission channel

6
1.2 MAC

Frequency multiplex
Separation of the whole spectrum into smaller frequency bands
A channel gets a certain band of the spectrum for the whole time
Advantages:
‰ no dynamic coordination
necessary k1 k2 k3 k4 k5 k6
‰ works also for analog signals
c
f
Disadvantages:
‰ waste of bandwidth
if the traffic is
distributed unevenly
‰ inflexible
‰ guard spaces
t

Time multiplex
A channel gets the whole spectrum for a certain amount of time

Advantages:
‰ only one carrier in the
medium at any time
‰ throughput high even k1 k2 k3 k4 k5 k6
for many users
c
Disadvantages: f
‰ precise
synchronization
necessary

8
1.2 MAC

Time and frequency multiplex


Combination of both methods
A channel gets a certain frequency band for a certain amount of
time
Example: GSM
Advantages:
‰ better protection against
tapping k1 k2 k3 k4 k5 k6
‰ protection against frequency
selective interference c

But: precise coordination f


required

Code multiplex
Each channel has a unique code
k1 k2 k3 k4 k5 k6

All channels use the same spectrum at


the same time c
Advantages:
‰ bandwidth efficient
‰ no coordination and synchronization
necessary
‰ good protection against interference f
and tapping
Disadvantages:
‰ lower user data rates
‰ more complex signal regeneration
Implemented using spread spectrum t
technology

10
1.2 MAC

Some medium access control mechanisms for wireless

SDMA FDMA TDMA CDMA

FDD

Fixed Aloha CSMA Reservations Multiple Polling


• Used in DAMA Access with
Collision • Used in 802.11
GSM Pure Slotted (optional)
Avoidance

• Copes with hidden


Non-persistent p-persistent CSMA/CA and exposed terminal
• RTS/CTS
• Used in 802.11 • Used in 802.11
(mandatory) (optional)

MACAW MACA-BI FAMA


CSMA:
CSMA:Carrier
CarrierSense
SenseMultiple
MultipleAccess
Access
CA:
CA:Collision
CollisionAvoidance
Avoidance
DAMA: CARMA
DAMA:Demand-Assigned
Demand-AssignedMultiple
MultipleAccess
Access
MACA-BI:
MACA-BI:MACAMACAby byinvitation
invitation
FAMA: Floor Acquisition Multiple Access
FAMA: Floor Acquisition Multiple Access
CARMA:
CARMA:Collision
CollisionAvoidance
AvoidanceandandResolution
ResolutionMultiple
MultipleAccess
Access 11
FDD:
FDD:Frequency
FrequencyDivision
DivisionDuplex
Duplex

FDMA/FDD – example: GSM

f downlink
960 MHz 124

935.2 MHz 1 200 kHz

20 MHz
915 MHz 124

1
890.2 MHz
t
uplink

12
1.2 MAC

TDMA/TDD – example: DECT

417 µs

1 2 3 11 12 1 2 3 11 12
t
downlink uplink

DECT:
DECT:Digital
DigitalEnhanced
EnhancedCordless
CordlessTelecommunications
Telecommunications
TDD: 13
TDD:Time
TimeDivision
DivisionDuplex
Duplex

Aloha/slotted aloha
Mechanism
‰ random, distributed (no central arbiter), time-multiplex
‰ Slotted Aloha additionally uses time-slots, sending must always
start at slot boundaries
Aloha collision

sender A
sender B
sender C
t
Slotted Aloha collision

sender A
sender B
sender C
t

14
1.2 MAC

Performance of Aloha (1/3)

Retransmission
First transmission
(if necessary)

t0-X t0 t0+X t0+X+2tprop t0+X+2tprop+B

Vulnerable period
Backoff period
Time-out

• tprop : maximum one-way propagation time betwwen 2 stations


• Information about the outcome of the transmission is obtained after the
reaction time 2 tprop
• B: backoff time

15

Performance of Aloha (2/3)


S: new packets S: throughput of the system

G {
G : total load
S : arrival rate of new packets
Assumption: Poisson distribution of the aggregate arrival process, with an
average number of arrivals of 2G arrivals/2X seconds
( 2G )
k

P [ k transmissions in 2 X seconds ] e −2G , k = 0,1, 2,...


=
k!
Throughput S: total arrival rate G times the prob. of a successful transmission:
S = GP [ no collision ] = GP [ 0 transmissions in 2 X seconds ]
( 2G )
0

=G e −2 G
0!
= Ge −2G
16
Peakvalue at G = 0.5 : S = 1 ≈ 0.184
2e
1.2 MAC

Performance of Aloha (3/3)


Computation of the average packet transmission time

Average number of transmission attempts/packet:


G = e 2G attempts per packet
S
Average number of unsuccessful attempts per packet:
ε = G S − 1 = e 2G − 1
The first transmission requires X + t prop seconds,
and each subsequent retransmission requires 2t prop + X + B
Thus the average packet transmission time is approx:
E [Taloha ] = X + t prop + (e 2G − 1)( X + 2t prop + B)
expressed relatively to X:
E [Taloha ] / X = 1 + a + (e 2G − 1)(1 + 2a + B )
X
t prop
where a = is the normalized one-way propagation delay
X 17

Performance of Slotted Aloha


Retransmission
First transmission
(if necessary)

t0=kX (k+1)X t0+X+2tprop t0+X+2tprop+B

Vulnerable
period Backoff period
Time-out

S = Ge-G
Peakvalue at G = 1 : S = 1 ≈ 0.368
e
Average packet delay:
E [Tslotaloha ] / X = 1 + a + (eG − 1)(1 + 2a + B )
X

18
1.2 MAC

Carrier Sense Multiple Access (CSMA)


‰ Goal: reduce the wastage of bandwidth due to packet collisions
‰ Principle: sensing the channel before transmitting (never
transmit when the channel is busy)
‰ Many variants:
‰ Collision detection (CSMA/CD) or collision avoidance(CSMA/CA)
‰ Persistency (in sensing and transmitting)

Station A begins
transmission
at t=0
A

Station A captures
the channel
at t=tprop
A 19

1-Persistent CSMA

‰ Stations having a packet to send sense the channel


continuously, waiting until the channel becomes idle.
‰ As soon as the channel is sensed idle, they transmit their
packet.
‰ If more than one station is waiting, a collision occurs.
‰ Stations involved in a collision perform a the backoff algorithm
to schedule a future time for resensing the channel
‰ Optional backoff algorithm may be used in addition for fairness

Consequence : The channel is highly used (greedy algorithm).

20
1.2 MAC

Non-Persistent CSMA

‰ Attempts to reduce the incidence of collisions


‰ Stations with a packet to transmit sense the channel
‰ If the channel is busy, the station immediately runs the back-off
algorithm and reschedules a future sensing time
‰ If the channel is idle, then the station transmits

Consequence : channel may be free even though some users have


packets to transmit.

21

p-Persistent CSMA

‰ Combines elements of the above two schemes


‰ Stations with a packet to transmit sense the channel
‰ If it is busy, they persist with sensing until the channel becomes
idle
‰ If it is idle:
z With probability p, the station transmits its packet
z With probability 1-p, the station waits for a random time and senses
again

22
1.2 MAC

Throughput expression

Protocol Throughput
Pure ALOHA S = Ge −2G
Slotted ALOHA S = Ge −G
Unslotted G[1 + G + aG (1 + G + aG / 2)]e −G (1+ 2 a )
S=
1-persistent CSMA
( )
G (1 + 2a ) − 1 − e − aG + (1 + aG )e −G (1+ a )
Slotted
S=
[ ]
G 1 + a − e − aG e −G (1+ a )
1-persistent CSMA (1 + a )(1 − e − aG
)+ ae −G (1+ a )

Unslotted Ge − aG
S=
nonpersistent CSMA G (1 + 2a ) + e − aG
Slotted aGe − aG
S=
nonpersistent CSMA 1 − e − aG + a
23

Throughput plot

Normalized propagation delay is a =0 .01


24
1.2 MAC

CSMA/CD (reminder)
Repeater Terminator

Station

CS: Carrier Sense (Is someone already talking ?)


MA: Multiple Access (I hear what you hear !)
CD: Collision Detection (We are both talking !!)
Three states for the channel : contention, transmission, idle

Operating principle
‰ Check whether the channel is idle before transmitting
‰ Listen while transmitting, stop transmission when collision
‰ If collision, one of the 3 schemes above (1-persistent, non-
persistent or p-persistent) 25

Why CSMA/CD is unfit for WLANs

‰ Collision Detection requires simultaneous


transmission and reception operations (which a radio
transceiver is usually unable to do) Î detecting a
collision is difficult
‰ Carrier Sensing may be suitable to reduce
interference at sender, but Collision Avoidance is
needed at receiver
‰ CSMA/CD does not address the hidden terminal
problem

26
1.2 MAC

CSMA/CA
Is described in the section devoted to IEEE 802-11

27

DAMA - Demand Assigned Multiple Access


Channel efficiency only 18% for Aloha, 36% for Slotted Aloha
Reservation can increase efficiency to 80%
‰ a sender reserves a future time-slot
‰ sending within this reserved time-slot is possible without collision
‰ reservation also causes higher delays
‰ typical scheme for satellite links
Examples for reservation algorithms:
‰ Explicit Reservation (Reservation-ALOHA)
‰ Implicit Reservation (PRMA)
‰ Reservation-TDMA

28
1.2 MAC

DAMA / Explicit Reservation

Explicit Reservation (Reservation Aloha):


‰ two modes:
z ALOHA mode for reservation:
competition for small reservation slots, collisions possible
z reserved mode for data transmission within successful reserved slots
(no collisions possible)
‰ it is important for all stations to keep the reservation list consistent at
any point in time and, therefore, all stations have to synchronize from
time to time

collision

t
Aloha reserved Aloha reserved Aloha reserved Aloha

29

DAMA / Packet reservation (PRMA)


Implicit reservation
‰ based on slotted Aloha
‰ a certain number of slots form a frame, frames are repeated
‰ stations compete for empty slots according to the slotted aloha
principle
‰ once a station reserves a slot successfully, this slot is automatically
assigned to this station in all following frames as long as the station
has data to send
‰ competition for a slot starts again as soon as the slot was empty in
the last frame

reservation
1 2 3 4 5 6 7 8 time-slot
ACDABA-F
frame1 A C D A B A F
ACDABA-F
frame2 A C A B A
AC-ABAF- collision at
frame3 A B A F
A---BAFD reservation
frame4 A B A F D attempts
ACEEBAFD
frame5 A C E E B A F D 30
t
1.2 MAC

DAMA / Reservation-TDMA

Reservation Time Division Multiple Access


‰ every frame consists of N mini-slots and x data-slots
‰ every station has its own mini-slot and can reserve up to k data-slots
using this mini-slot (i.e. x = N * k).
‰ other stations can send data in unused data-slots according to a
round-robin sending scheme (best-effort traffic)

e.g. N=6, k=2


N mini-slots N * k data-slots

reservations other stations can use free data-slots


for data-slots based on a round-robin scheme

31

MACA - collision avoidance


MACA (Multiple Access with Collision Avoidance) uses short
signaling packets for collision avoidance
‰ Designed especially for packet radio networks (Phil Karn, 1990)
‰ Principle:
z RTS (request to send): a sender request the right to send from a
receiver with a short RTS packet before it sends a data packet
z CTS (clear to send): the receiver grants the right to send as soon as it
is ready to receive
Signaling packets contain
‰ sender address
‰ receiver address
‰ packet size

Variants of this method can be found in IEEE802.11 as DFWMAC


(Distributed Foundation Wireless MAC)

32
1.2 MAC

MACA principle
MACA avoids the problem of hidden terminals
‰ A and C want to
send to B
‰ A sends RTS first RTS
‰ C waits after receiving
CTS from B CTS CTS
A B C

MACA avoids the problem of exposed terminals


‰ B wants to send to A,
C to another terminal
‰ now C does not have RTS RTS
to wait for it cannot
receive CTS from A CTS
A B C

33

MACA example

A B D A B D
RTS CTS

E E
C C
1 2

A B D
DATA

: blocked from Tx

E
C 34
3
1.2 MAC

MACA variant: application in IEEE802.11


sender receiver

idle idle
packet ready to send; RTS
data;
ACK
RxBusy time-out;
wait for the RTS RTS;
ACK right to send time-out ∨ CTS
time-out ∨ Data with errors;
NAK; NAK
RTS CTS; data
wait for
wait for ACK data

RTS; RxBusy

ACK: positive acknowledgement RxBusy: receiver busy


NAK: negative acknowledgement
35

Polling mechanisms
If one terminal can be heard by all others, this “central” terminal
(e.g., base station) can poll all other terminals according to a
certain scheme
‰ all schemes known from fixed networks can be used (typical
mainframe - terminal scenario)
Example: Randomly Addressed Polling
‰ base station signals readiness to all mobile terminals
‰ terminals ready to send can now transmit a random number without
collision with the help of CDMA or FDMA (the random number can
be seen as a dynamic address)
‰ the base station now chooses one address for polling from the list of
all random numbers (collision if two terminals choose the same
address)
‰ the base station acknowledges correct packets and continues polling
the next terminal
‰ this cycle starts again after polling all terminals of the list

36
1.2 MAC

ISMA (Inhibit Sense Multiple Access)


Current state of the medium is signaled via a “busy tone”
‰ the base station signals on the downlink (base station to terminals)
if the medium is free or not
‰ terminals must not send if the medium is busy
‰ terminals can access the medium as soon as the busy tone stops
‰ the base station signals collisions and successful transmissions via
the busy tone and acknowledgements, respectively (media access
is not coordinated within this approach)
‰ mechanism used, e.g., for CDPD (Cellular Digital Packet Data)
‰ Similar approach was proposed
for Packet Radio Networks
(Kleinrock + Tobagi, 1975)

37

CDMA (Code Division Multiple Access)


Principles
‰ all terminals send on the same frequency and can use the whole
bandwidth of the transmission channel
‰ each sender has a unique code
‰ The sender XORs the signal with this code
‰ the receiver can “tune” into this signal if it knows the code of the sender
‰ tuning is done via a correlation function
Disadvantages:
‰ higher complexity of the receiver (receiver cannot just listen into the
medium and start receiving if there is a signal)
‰ all signals should have approximately the same strength at the receiver
Advantages:
‰ all terminals can use the same frequency, no planning needed
‰ huge code space (e.g., 232) compared to frequency space
‰ interferences (e.g. white noise) is not coded
‰ more robust to eavesdropping and jamming (military applications…)
‰ forward error correction and encryption can be easily integrated

38
1.2 MAC

DSSS (Direct Sequence Spread Spectrum) (1/2)


XOR of the signal with pseudo-random number (chipping sequence)
‰ many chips per bit (e.g., 128) result in higher bandwidth of the signal
Advantages
‰ reduces frequency selective tb
fading
user data
‰ in cellular networks
0 1 XOR
z base stations can use the
same frequency range tc
z several base stations can chipping
detect and recover the signal sequence
01101010110101 =
z soft handover

Disadvantages resulting
signal
‰ precise power control necessary
01101011001010
‰ complexity of the receiver
tb: bit period
tc: chip period

39

DSSS (Direct Sequence Spread Spectrum) (2/2)

spread
spectrum transmit
user data signal signal
X modulator

chipping radio
sequence carrier

transmitter

correlator
lowpass sampled
received filtered products sums
signal signal data
demodulator X integrator decision

radio chipping
carrier sequence

receiver
40
1.2 MAC

CDMA: principle (very simplified)


Spreading Despreading

Ak
Ak

Ad X As X Ad
C+D

As + Bs
Bk Bk

Bd X Bs X Bd
C+D
41
C+D:
C+D:Correlation
Correlationand
andDecision
Decision

CDMA: example
Sender A
‰ sends Ad = 1, key Ak = 010011 (assign: „0“= -1, „1“= +1)
‰ sending signal As = Ad * Ak = (-1, +1, -1, -1, +1, +1)
Sender B
‰ sends Bd = 0, key Bk = 110101 (assign: „0“= -1, „1“= +1)
‰ sending signal Bs = Bd * Bk = (-1, -1, +1, -1, +1, -1)
Both signals superimpose in space
‰ interference neglected (noise etc.)
‰ As + Bs = (-2, 0, 0, -2, +2, 0)
Receiver wants to receive signal from sender A
‰ apply key Ak bitwise (inner product)
z Ae = (-2, 0, 0, -2, +2, 0) • Ak = 2 + 0 + 0 + 2 + 2 + 0 = 6
z result greater than 0, therefore, original bit was „1“
‰ receiving B
z Be = (-2, 0, 0, -2, +2, 0) • Bk = -2 + 0 + 0 - 2 - 2 + 0 = -6, i.e. „0“

42
1.2 MAC

Spreading of signal A

data Ad 1 0 1

key sequence Ak 0 1 0 1 0 0 1 0 0 0 1 0 1 1 0 0 1 1
Ad+Ak 1 0 1 0 1 1 1 0 0 0 1 0 0 0 1 1 0 0

signal As

Real systems use much longer keys resulting in a larger distance


between single code words in code space.

43

Spreading of signal B

signal As

data Bd
1 0 0

key sequence Bk 0 0 0 1 1 0 1 0 1 0 0 0 0 1 0 1 1 1
Bd+Bk 1 1 1 0 0 1 1 0 1 0 0 0 0 1 0 1 1 1

signal Bs

As + Bs

44
1.2 MAC

Despreading of signal A
data Ad 1 0 1

As + Bs

Ak

(As + Bs)
* Ak

correlator
output
decision
output 0 1 0

Note: 45
Note:the
thereceived
receivedsignal
signalisisinverted
inverted

Despreading of signal B
data Bd 1 0 0

As + Bs

Bk

(As + Bs)
* Bk

correlator
output
decision
output 0 1 1

Note: 46
Note:the
thereceived
receivedsignal
signalisisinverted
inverted
1.2 MAC

Despreading with a wrong key

As + Bs

wrong
key K

(As + Bs)
*K

correlator
output
decision
output (1) (1) ?

47

SAMA - Spread Aloha Multiple Access


Aloha has only a very low efficiency, CDMA needs complex
receivers to be able to receive different senders with individual
codes at the same time
Idea: use spread spectrum with only one single code (chipping
sequence) for spreading for all senders accessing according to
aloha collision

sender A 1 0 1 narrow
sender B 0 1 1 band
send for a
shorter period
with higher power
spread the signal e.g. using the chipping sequence 110101 („CDMA without CD“)

Problem: find a chipping sequence with good characteristics

48
1.2 MAC

Comparison SDMA/TDMA/FDMA/CDMA
Approach SDMA TDMA FDMA CDMA
Idea segment space into segment sending segment the spread the spectrum
cells/sectors time into disjoint frequency band into using orthogonal codes
time-slots, demand disjoint sub-bands
driven or fixed
patterns
Terminals only one terminal can all terminals are every terminal has its all terminals can be active
be active in one active for short own frequency, at the same place at the
cell/one sector periods of time on uninterrupted same moment,
the same frequency uninterrupted
Signal cell structure, directed synchronization in filtering in the code plus special
separation antennas the time domain frequency domain receivers

Advantages very simple, increases established, fully simple, established, flexible, less frequency
capacity per km² digital, flexible robust planning needed, soft
handover
Dis- inflexible, antennas guard space inflexible, complex receivers, needs
advantages typically fixed needed (multipath frequencies are a more complicated power
propagation), scarce resource control for senders
synchronization
difficult
Comment only in combination standard in fixed typically combined still faces some problems,
with TDMA, FDMA or networks, together with TDMA higher complexity,
CDMA useful with FDMA/SDMA (frequency hopping lowered expectations; will
used in many patterns) and SDMA be integrated with
mobile networks (frequency reuse) TDMA/FDMA

In practice, several access methods are used in combination 49


Example :SDMA/TDMA/FDMA for GSM and IS-54

References
J. Schiller: Mobile Communications, Addison-Wesley, 2000
Leon-Garcia & Widjaja: Communication Networks, McGrawHill,
2000

50

You might also like