Amplitude Modulation and Demodulation

advertisement
Chapter 8
ft
Amplitude Modulation and
Demodulation
ra
This chapter is dedicated to Amplitude Modulation (AM) and related aspects.
It is the easiest form of modulation to grasp.
8.1
Amplitude Modulation
AM results from the product of two signals: a carrier signal at frequency f Hz
and a modulating signal at frequency g Hz, with f much greater than g. The
following equation models AM
s(t) = [1 + sin(2πgt)] · sin(2πf t) Volts.
(8.1)
D
The term sin(2πgt) denotes the modulating signal. The term sin(2πf t) is an
abstraction of the carrier signal. The unit term represents a DC component
added to the modulating signal to prevent loss of information.
An example is shown in Figure 8.1. The top subplot shows a carrier at
frequency f = 12 Hz and a modulating signal at frequency g = 2 Hz. The
bottom subplot is the corresponding AM signal.
The bottom subplot also shows the envelope of the AM signal. The envelope
is obtained by joining together with a line either the peaks of the positive half
cycles or the troughs of the negative half cycles. The frequency of the signal
within the envelope corresponds to the frequency of the carrier. The frequency
of the envelope corresponds to the frequency of the modulating signal. The
plots have been generated by the following Octave code:
1
2
3
4
5
% Create an array of 1000 time instants, in steps of 0.001 s.
time=[0:999]*0.001;
% Create a carrier signal at frequency f
f=12; % Hz
carrier=sin(2*pi*f*time);
105
© 2015 Michel Barbeau
Software Defined Radio
Carrier and Modulating Signal (−−)
Amplitude (V)
2
1
0
ft
−1
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
0.9
1
AM Signal and Envelope (:)
1
0
ra
Amplitude (V)
2
−1
−2
0
0.1
0.2
0.3
0.4
0.5
0.6
Time (s)
0.7
0.8
Figure 8.1: Amplitude modulation.
6
7
8
9
D
10
% Create a modulating signal at frequency g
g=2; % Hz
modulation=1+sin(2*pi*g*time);
% Modulation depth
m=1; % 100% modulation
% Multiply the modulating signal by the carrier
signal=m*modulation.*carrier;
% Plot the carrier
subplot(2,1,1);
plot(time,carrier);
hold on;
% Plot the modulating signal
plot(time,modulation,'−.r');
% Annotations
title('Carrier and Modulating Signal (−−)');
ylabel('Amplitude (V)');
grid on;
% Plot the AM signal
subplot(2,1,2);
plot(time,signal);
hold on;
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
106CHAPTER 8. AMPLITUDE MODULATION AND DEMODULATION
© 2015 Michel Barbeau
Software Defined Radio
27
28
29
30
31
32
33
% Plot the envelope
plot(time,modulation,':b');
% Annotationse
title('AM Signal and Envelope (:)');
xlabel('Time (s)');
ylabel('Amplitude (V)');
grid on;
8.2
ft
The carrier signal at frequency f is generated at line 5. The modulating signal
at frequency g is produced at line 8. On line 10, the factor m is the modulation
depth. It represents a percentage of modulation. 100% modulation is done in
this example. The degree of variation of the envelope (minimum voltage versus
maximum voltage) is determined by the modulation depth. Line 12 implements
the Equation 8.1 of AM.
AM Using the I and Q Signals
ra
I, Q(−−) and Modulating Signal (−.)
Amplitude (V)
2
1
0
−1
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
0.9
1
I and Q (−−) AM Signals and Envelope (:)
1
0
D
Amplitude (V)
2
−1
−2
0
0.1
0.2
0.3
0.4
0.5
0.6
Time (s)
0.7
0.8
Figure 8.2: AM using the I and Q signals.
Figure 8.2 shows an example where an in-phase carrier and its quadrature
carrier are modulated in amplitude. The carrier frequency is 12 Hz and the
modulating signal frequency is 2 Hz. The plots have been generated by the
following Octave script:
CHAPTER 8. AMPLITUDE MODULATION AND DEMODULATION107
© 2015 Michel Barbeau
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
ra
23
% Create an array of 1000 time instants, in steps of 0.001 s.
time=[0:999]*0.001;
% Create a carrier signal at frequency f
f=12; % Hz
% Create an in−phase carrier
Icarrier=cos(2*pi*f*time);
% Create a quadrature carrier
Qcarrier = sin(2*pi*f*time);
% Create a modulating signal at frequency g
g=2; % Hz
modulation=1+sin(2*pi*g*time);
% Modulation depth
m=1; % 100% modulation
% Multiply the modulation by the carrier
Isignal=m*modulation.*Icarrier;
Qsignal=m*modulation.*Qcarrier;
% Plot the carriers and modulating signal
subplot(2,1,1);
plot(time,Icarrier);
hold on;
plot(time,Qcarrier,'−−k');
hold on;
plot(time,modulation,'−.r');
% Annotations
title('I, Q(−−) and Modulating Signal (−.)');
ylabel('Amplitude (V)');
grid on;
% Plot the AM signals
subplot(2,1,2);
plot(time,Isignal);
hold on;
plot(time,Qsignal,'−−k');
hold on;
% Plot the envelope
plot(time,modulation,':b');
% Annotations
title('I and Q (−−) AM Signals and Envelope (:)');
xlabel('Time (s)');
ylabel('Amplitude (V)');
grid on;
ft
1
Software Defined Radio
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
D
40
The in-phase and quadrature, both at frequency f , are constructed on lines 6
and 8. The modulating signal, of frequency g, is created on line 11. It is used
to modulate the amplitude of both the in-phase and quadrature on lines 15
and 16, in accordance to Equation 8.1. Note that both the in-phase AM signal
and quadrature AM signal share the same envelope. In other words, they carry
exactly the same information. On the air, it is only necessary to send one of
them. But inside a receiver, it is convenient to have both of them because
demodulation is a matter of simple calculation.
108CHAPTER 8. AMPLITUDE MODULATION AND DEMODULATION
© 2015 Michel Barbeau
Software Defined Radio
8.3
AM Demodulation
Given an in-phase AM signal I and quadrature Q, the modulating signal is
recovered by applying Pythagora’s theorem on the I and Q signals. The equation
for the demodulation of an amplitude-modulated signal is
p
I 2 + Q2 .
(8.2)
ft
Using the variables Isignal and Qsignal, the following Octave script impleAmplitude Demodulation
2
1.8
1.6
1.2
ra
Amplitude (V)
1.4
1
0.8
0.6
0.4
0.2
0
0
0.1
0.2
0.3
0.4
0.5
0.6
Time (s)
0.7
0.8
0.9
1
D
Figure 8.3: AM demodulation.
ments amplitude demodulation:
1
2
3
4
5
6
7
8
% Demodulation
demodulation = sqrt((Isignal).ˆ2 + (Qsignal).ˆ2);
% Plot the signal
plot(time,demodulation);
% Annotations
title('Amplitude Demodulation');
xlabel('Time (s)');
ylabel('Amplitude (V)');
Demodulation is implemented using the variables Isignal and Qsignal of the
previous Octave script. Equation 8.2 of AM demodulation is implemented on
line 2.
CHAPTER 8. AMPLITUDE MODULATION AND DEMODULATION109
© 2015 Michel Barbeau
8.4
Software Defined Radio
M-ary Quadrature Amplitude Modulation
Q
01
00
2
10
00
11
00
ft
00
00
00
01
01
01
-2
-1
1
10
01
11
01
1
2
01
11
-1
10
11
11
11
00
10
01
10
-2
10
10
11
10
ra
00
11
I
Figure 8.4: 16-QAM constellation.
D
M-ary Quadrature Amplitude Modulation (M-QAM) is used for data communications. An in-phase carrier and its quadrature are modulated in amplitude
to encode bits. There are M√different symbols. For each signal, i.e., the in-phase
An example, i.e., 16-QAM, is picand quadrature, there are M amplitudes.
√
tured in Figure 8.4. M is 16 and M is four. Each circle represents a symbol.
The horizontal axis corresponds to the amplitude of the in-phase carrier. The
vertical axis is the amplitude of the quadrature carrier. In this examples log2 M
bits can be represented per symbol, i.e., four bits. For example, when the symbol 1001 is sent, the amplitude of both the in-phase I and quadrature Q is one.
On the receiver side, when the amplitudes of the in-phase and quadrate signals
both fall within the range 0.5 to 1.5 Volts the corresponding decoded symbol is
1001.
To model the signal sent over the air, we just have to leverage Equation 3.1.
Let f be the frequency of the carrier, in Hertz. For a given symbol, let I and
110CHAPTER 8. AMPLITUDE MODULATION AND DEMODULATION
© 2015 Michel Barbeau
Software Defined Radio
Q be the corresponding required amplitudes of the in-phase and quadrature
signals, in Volts. For that symbol, the value of the modulated signal at time t
is
s(t) = I cos(2πf t) + Q sin(2πf t) Volts.
(8.3)
Demodulation of a QAM signal implies separating the in-phase and quadrature from the modulated signal. Let us see how the in-phase is recovered. Let
r(t) be a received QAM signal at frequency f Hertz. The received signal r(t) is
multiplied by a cosine signal at the same frequency
ft
r(t) · cos(2πf t).
Assuming that r(t) is equal to s(t), this product can be expanded as
[I cos(2πf t) + Q sin(2πf t)] · cos(2πf t).
which is equal to
[I cos(2πf t) · cos(2πf t)] + [Q sin(2πf t) · cos(2πf t)].
ra
Using the two trigonometric equivalences cos2 ω = (1+cos 2ω)/2 and sin ω cos ω =
(sin 2ω)/2, it can be rewritten as
I/2 · [1 + cos(4πf t)] + Q/2 · sin(4πf t).
which is equal to
I/2 + I/2 · cos(4πf t) + Q/2 · sin(4πf t).
A low pass filter is used to eliminate the second and fourth terms at frequency
2f Hertz. The first term is multiplied by two to yield the value I.
D
Exercise 8.1
Starting from a received QAM signal r(t), develop the equation that selects the
quadrature signal.
CHAPTER 8. AMPLITUDE MODULATION AND DEMODULATION111
Download