Physical Layer – How bits are sent

Download Report

Transcript Physical Layer – How bits are sent

Physical Layer (2)
Goal
• Physical layer design goal: send out bits as fast
as possible with acceptable low error ratio
• Goal of this lecture
– Review some of the important concepts
– Modulation, demodulation, maximum likelihood
detection
– Introduction to wireless communications, CDMA,
OFDM, MIMO
Review
• What is bandwidth (how it is defined)? What
it means to have high(low) bandwidth?
• What is noise?
• Shannon’s theorem?
– If a link has a bandwidth of 4KHz and the signal to
noise power ratio is 15, what is the capacity of the
channel?
• Why we have limited bandwidth?
Modulation
• Even in the simplest 10Mbs Ethernet case, the
signals you send out is different from the 0-1
waveform.
• Modulation is to convert the 0-1 waveform to the
actual signal to be sent out.
• In most cases the signals are derived from sine
waves.
– Given the 0-1 waveform, you do some tricks to the
sine wave at some frequency f, and send it out
– This sine wave is called the carrier
Different modulation techniques
•
•
•
•
Amplitude modulation
Frequency modulation
Phase modulation
In digital communications, phase modulation is
used
– Simplest case – BPSK
– Given a 0-1 stream, regard it as a -1 and 1 stream and
multiply it with the sine wave. The -1 and 1 stream is
called the baseband signal (no exactly, but for our
purpose it is)
Demodulation
• The problem is, given a (0,180) phase
modulated signal on frequency f, how to
determine whether the bit is 0 or 1?
• This is demodulation.
• Assume that you know the beginning of a
binary symbol.
Demodulation
• Three steps:
– You multiply the received signal with a sine wave
on f, and pass it to a low-pass filter only allowing
signals with frequency less than f to pass
– Do an integral to the output of the filter from 0 to
T where T is the symbol time.
– If the result is positive, it was 1 and if it was
negative, it was 0.
• If no noise, things are simple!
Demodulation
• With noise, it’s all about guessing, because you
don’t know what the noise is when this symbol is
sent as noise is random.
• You may know some statistics of the noise, based
on which you make your best guess.
• For example, let’s say -1 is -2.5 volts 1 is 2.5 volts.
Suppose you know that very rarely the noise
exceeds 2.5 volts. If you received a 0.3 volts, you
would guess it to be -1 or 1? What is the chance
that you got it right/wrong?
Maximum Likelihood Detection
• Detection – given a received signal, determine
which of the possible original signals was sent.
There are finite number of possible original
signals (2 for the binary case – -1 or 1)
• Compute a likelihood value for every possible
input, choose the one with largest likelihood –
maximum likelihood detection
Maximum Likelihood Detection
• There are two inputs, x1 and x2. Noise is n.
What you receive is y.
• If I sent x1, you receive y=x1 + n. If I sent x2,
you receive y=x2+n. You don’t know what I
sent and how large n is.
• You compute the likelihood of receiving y if I
sent xi, Li (i=1,2). If L1 > L2, you say I sent x1.
Else you say I sent x2.
• How to compute L1 and L2?
Maximum Likelihood Detection
• If n=0 always, y=x1 if I sent x1 and y=x2 if I sent x2. Of course x1 !=
x2. Will you make mistake in this case? What is the likelihood of
y=x2 if I sent x1?
• If n is not always zero, we assume n follows some probability
distribution. If it is Gaussian, the channel is called AWGN.
• Given y, the likelihood of x1 being sent is the likelihood that n=y-x1.
Similarly, the likelihood of x2 being sent is the likelihood that n=yx2. (likelihood is derived from probability, but likelihood could be
taking some values that probability cannot take depending on how
you define likelihood)
• So what you are doing is to compare the likelihood of n=y-x1 and
n=y-x2. So the detection rule is if p(n=y-x1)/p(n=y-x2) > 1, output
x1, else output x2.
• That’s all!
• Wait, what if you know that x1 is more likely to be sent than x2?
Question left in last lecture
• How do you demodulate 10Mbps Ethernet
signal?
I,Q channels
• In modern communications, you have two carriers on the
same frequency but their phases differ by 90 degrees. So
one is sine and the other is cosine. You can apply two
symbol streams (the baseband signals) to them separately,
and add the two together and send out.
• The receiver won’t be confused because what he does is to
multiply the received signal with two locally generated sine
waves on the same frequency as the sender side, one sine
and one cosine. Then he passes each of the two multiplied
signals to a device that only allows signals on frequency no
higher than B to pass (assuming the highest frequency of
your signal is B). Why?
QAM
• With two carriers, you have two dimensions.
So the signal will appear on a plane. 16-QAM,
64-QAM, 256-QAM
Cellular Phone Networks
• User – base station – Telephone network
• FDMA – Frequency division multiplexing
– How to make sure that you are using this band,
not that band?
• TDMA – Time division multiplexing
• CDMA – Code division multiplexing
GSM – Global System for Mobile
Communications
• Second generation cell phone system (digital, first
generation analog).
• GSM-900 and GSM-1800 are most widely used
– GSM-900 uses 890 - 915 MHz to send information from the
Mobile Station to the Base Transceiver Station (uplink) and 935 960 MHz for the other direction (downlink).
• FDMA + TDMA
• Each user transmitting on a frequency and receiving on
another frequency.
• 124 pairs of 200 KHz channels. Each channel divided into
time slots for 8 users.
• Each user is has a chance to transmit every 4.615 ms. Each
time he can send 114 data bits – 24.7kbps.
CDMA
• Described in IS-95.
• A good analogy in the book – You have a
group of people in a room. TDMA means they
talk in turn. FDMA means that those who
wants to talk sit in different corners and can’t
hear other pair. CDMA means each pair talks
in a different language and other people’s
voice is noise to them.
CDMA
• The whole bandwidth is used by every user.
Meaning that they can send out symbols really
fast.
• The trick is to make what A sent appear as 0 to B.
– Because we have a fast symbol rate, for each data bit,
we send out, say, 8 bits, call the “small bits” chips.
– Given a bit, if 1, send out, say, -1,-1,-1,1,1,-1,1,1, and if
0, 1,1,1,-1,-1,1,-1,-1
– This is called the chip sequence.
– The key is that each station has a unique chip
sequence (language), and different languages are
orthogonal.
Wireless LAN Physical Layer
• 802.11b,g in the 2.4G band and 802.11a in the 5G band.
People now consider 802.11 as the notion of MAC layer
protocol, while a, b, g, or n, are about physical layer.
• 802.11b. 1, 2, 5.5, 11Mbps.
– 1Mbps: BPSK modulation. 1 bit into 11 chips with Barker
sequence +1 +1 +1 −1 −1 −1 +1 −1 −1 +1 −1. Why spread
spectrum? Required by FCC but was later removed
– 2Mbps: QPSK.
– 5.5M and 11M: use some bits to select chip sequence and use
two bits for QPSK
• 802.11a. Up to 54Mbps. OFDM.
• 802.11g. Up to 54Mbps. OFDM.
OFDM (Orthogonal Frequency Division
Multiplexing)
• In wireless communications, in addition to the
bandwidth limit and additive noise, you also have
multipath fading!
• The faster your symbol rate is, the more badly you will
be affected by multipath fading.
• In effect, OFDM is like DSL: given a wideband channel,
divide it into many sub channels. Each sub-channel can
be modulated/demodulated independently. Because
each sub-channel is of a much smaller bandwidth,
multipath fading is much less severe.
• In implementation, use IFFT and FFT.
MIMO
• Used in 802.11n.
• t transmit antennas and r receive antennas.
With the knowledge of channel matrix, by preprocessing the data, equivalent to min{t,r}
channels.
Wired communication – Optical
Backbone
• SONET – Synchronous Optical Network
– OC-1: 51.84Mbps
– OC-3: 3*51.84Mbps
– OC-9: 9*51.84Mbps
–…
• Used for backbone switching