Chapter 6
An Overview of Transceiver
Systems
This chapter plays the role of an introductory chapter to the rest of this book. The
key idea here is to point out the problems that one may encounter when a pair of
transmitter and receiver are implemented and separated by a non-ideal (i.e., a real)
channel. Sample simulation programs that help us with demonstration of the impact
of a channel and implementation tolerances (e.g., a carrier offset between transmitter
and receiver) are developed. Various methods of combating the channel distortions
and implementation tolerances are the subject of the subsequent chapters. The
programs developed in this chapter will be extended and used extensively in the rest
of the book to demonstrate the performance of the developed methods.
6.1 Building Blocks
Figure 6.1 presents a block diagram of a complete transceiver (transmitter + chan-
nel + receiver) digital communication system. The information bits, b[n], are first
coded by adding redundant bits that protect (to a certain extent) the information
against possible errors due to channel noise/distortion. The coded bits are then
grouped and converted to (possibly complex) data symbols, s[n]. Next, the data
symbols are pulse-shaped, through transmit filter pT(t), and modulate a carrier to
generate an RF (radio frequency) signal for transmission through a passband chan-
nel. The channel may introduce some distortion to the signal and add some noise to
it. Interference from other users may also exist. These are usually over the bands
that are non-overlapping with the desired signal band and thus could be removed
through linear filtering. At the receiver, the signal picked up by the antenna first
passes through a low noise amplifier (LNA) and amplified to a level appropriate for
the rest of the circuit. The signal level at this stage is controlled by an automatic
gain control (AGC) mechanism. Next, the demodulator shifts the desired signal to
151
152 Quadrature Amplitude Modulated Transceiver Systems Chap. 6
the baseband. The receive/matched filter pR(t) (usually chosen to be matched to
pT(t)) removes any out-of-band signals, including the interference from other users
and channel noise. The matched filter output is then sampled and passed through
an equalizer to compensate for the distortion caused by the channel. The output
of the equalizer is input to a slicer/decoder that makes the final decision about the
transmitted bits, b[n].
Demodulator
coder
bit/
symbol
Modulator
⊕ ⊕
Carrier
recovery
transmit
filter, pT(t)
slicer/
decoder
interference form
other usersnoise
sampler
b[n]
bˆ[n]
Timing
recovery
filter, pR(t)
receive/matched
Equalizer
Channel, c(t)
LNA/
AGC
Figure 6.1: Block diagram of a digital communication system.
The transceiver system shown in Figure 6.1 follows the structure of older gen-
erations of modems. In a software defined radio, the received signal is sampled at
a point as close as possible to the antenna. If possible, the samples of the received
signal are taken right after the LNA/AGC and the control of the gain of LNA (i.e.,
the task of AGC) is done in the digital domain by processing the signal samples
and sending a feedback to the LNA. This operation of the receiver is discussed in
Chapter 7. If the carrier frequency is so high (say, many GHz) that it does not allow
direct sampling of the RF signal, a first level of down conversion to an intermediate
frequency (IF) is made before sampling. In any case, in a software defined radio,
processing begins with samples of a modulated version of the desired signal. Conver-
sion from this modulated band to baseband is done digitally. Many approaches are
possible. Among them, one very efficient method, that takes advantage of multirate
signal processing, is the receiver structure that was introduced in Section 5.8.3. Sim-
ilarly, one may choose the transmitter structure that was introduced in Section 5.8.2
Sec. 6.2 MATLAB Simulation of Digital Transmission Systems 153
for efficient implementation of the cascade of the transmit filter and the modulator
in Figure 6.1.
Clearly, the discussion in Section 5.8.3 was based on the ideal, thus, unrealistic
assumption that the carrier phase and frequency were known to the receiver. More-
over, the assumption was that the receiver had perfect knowledge of the symbol
timing phase. In practice, of course, these are unknown or, at the best, the receiver
is only aware of their nominal values. Thus, the receiver should obtain the estimates
of these unknowns and track them as they drift slowly. The subject of carrier recov-
ery (acquisition and tracking) is discussed in Chapter 9. Methods of timing recovery
are discussed in Chapter 10. Chapter 11 is devoted to the problem of distortion that
arises as a result of a non-ideal response of the channel (caused by, e.g., multipaths
in a radio link) and introduces the concept of channel equalization. Although we
give the theoretical bases for the developed methods, we also rely extensively on
simulations to drill in the ideas further.
6.2 MATLAB Simulation of Digital Transmission
Systems
Computer simulations play a major role in the study of engineering problems. In the
particular case of digital transmission systems, computer simulations greatly help in
gaining an in-depth understanding of the properties and behavior of signals at var-
ious stages of the system. Eye-patterns (introduced below), for instance, provide a
visualization tool that greatly helps an engineer in better understanding the impact
of various impairments in the the channel on the received signals and, as a result,
finding methods of combating such impairments. Moreover, the adaptive methods
proposed in the subsequent chapters are in general difficult to analyze. Even when
possible, the theoretical developments and analyses involve a number of approxi-
mations and/or assumptions. Computer simulations are, thus, found necessary to
confirm such theoretical results.
In the context of this text, most of the parts in a simulation program directly
translate to modules in a software defined radio. Thus, the simulation programs not
only enhances our understanding of software radio algorithms and techniques, but
also may be thought as a tool for development of software radio systems.
In the rest of this chapter, we first develop a simulation program for a baseband
PAM transceiver system. This provides us a simple platform for exploring the con-
cept of eye-pattern and examination of the channel distortion effect on the received
signal. Later, we generalize this program and develop it to a QAM transceiver
system. The impact of carrier phase and frequency offset on QAM signals is then
explored by introducing such effects in the developed program.
As we proceed with the presentation of MATLAB scripts (programs), we often
call functions that we have developed as integral parts of this text. These func-
154 Quadrature Amplitude Modulated Transceiver Systems Chap. 6
tions and also the presented MATLAB programs are available on an accompanying
CD. The reader is expected to refer to these functions and explore them wherever
necessary.
6.3 Baseband PAM transceiver
The MATLAB script ‘pamtxrx.m’, presented on the next page, simulates a baseband
PAM transceiver system. The code is self-explatory and consists of the following
parts:
Parameters: The system parameters are set in this part. The parameters are:
(i) the symbol period, ‘Tb’; (ii) the sampling period, ‘Ts’; (iii) the number
of samples per symbol period, ‘L’; (iv) the roll-off factor of the transmit and
receive filters (a square-root raised-cosine pulse), ‘alpha’; (v) the duration of
the transmit and receive filters in the units of Tb, ‘K’ (an even integer); (vi)
the standard deviation of the channel noise, ‘sigmav’; and (vii) the channel
impulse response, ‘c’.
Source: This is any piece of information (a text file, a sampled speech signal, a
coded image, ...) that is converted to sequence of bits. In the MATLAB script
‘pamtxrx.m’, this sequence is stored in a vector called ‘b’. Here, the source is a
random sequence of bits in non-return-to-zero (NRZ) format. That is, logical
zero is represented by −1 and logical one is represented by +1.
Coder: Coverts the information bits from source to symbols. In the MATLAB
script ‘pamtxrx.m’ these symbols are stored in a vector called ‘s’.
Transmit filter: This a square-root raised-cosine filter with roll-off factor α. Here,
α is set equal to 0.5. In the real world, the transmit signal is continuous-
time. Since in computer simulation, we can only have sampled signals, we
approximate continuous-time signals by a dense grid of samples. Here, we
have L = 100 samples per symbol period. The function ‘sr cos p’ generates
a square-root raised-cosine pulse, for the transmit filter, pT(t). The next line
in the code, expands the transmit symbols and lowpass filters the result by
passing it through pT(t).
Channel: This is characterized by an impulse response c(t) and an additive noise.
Here, we have chosen c(t) = δ(t) which in the discrete domain becomes c = 1.
If the channel is multipath, e.g., with the impulse response c(t) = a0δ(t −
t0) + a1δ(t − t1), it has the equivalent discrete domain c = [zeros(N0,1); a0;
zeros(N1,1); a1], where N0 and N1 are t0 and t1 in unit of Ts. The channel
noise is assumed to be gaussian with the standard deviation ‘sigmav’.
Sec. 6.3 MATLAB Simulation of Digital Transmission Systems 155
MATLAB Script pamtxrx.m: Baseband PAM Transceiver
%
% PARAMETERS
%
Tb=0.0001; L=100; Ts=Tb/L; alpha=0.5;
K=8; sigmav=0; c=1;
%
% SOURCE
%
b=sign(randn(1000,1));
%
% CODER
%
s=b; % 2-level PAM
% s=b(1:2:end)+2*b(2:2:end); % 4-level PAM
%
% TRANSMIT FILTERING / PULSE SHAPING
%
pT=sr cos p(K*L,L,alpha); % Transmit filter (square-raised cosine filter)
xT=conv(expander(s,L),pT); % Transmit signal
%
% CHANNEL
%
xR=conv(c,xT); % Transmit the signal through the channel
xR=xR+sigmav*randn(size(xR)); % Add noise
%
% RECEIVE FILTERING
%
pR=pT;
y=conv(x,pR);
%
% DISPLAY
% Here, the eye pattern of the received PAM signal is displayed.
%
y=reshape(y,2*L,length(y)/(2*L)); % Reshape the received signal
% vector to columns of duration 2Tb.
y=y(:,8:end-8); % Delete the transient parts.
t=[0:1/L:2-1/L]; % Time in unit of symbol period.
plot(t,y,’b’)
xlabel(’t/Tb’)
title(’PAM eye-pattern’)
156 Quadrature Amplitude Modulated Transceiver Systems Chap. 6
Receive filter: This is similar to and, thus, matched to the transmit filter pT(t),
viz., pR(t) = pT(t). Since these are squre-root raised-cosine filters, their cas-
cade is a raised-cosine and thus a Nyquist pulse shape.
Display: This part of the code is to display any signal (or the result) in the system
that we wish to see. Here, we have chosen to present the received signal, after
it has passed through the receive filter, pR(t). The presentation has a special
format which is called eye pattern and discussed below.
6.4 Eye Patterns in PAM Systems
The quality of the received signal in a digital PAM transmission system can be best
seen by overlapping and displaying multiple segments of the received signal over the
duration of a few symbol periods. The result is known as an eye pattern because of
its resemblance to the human eye. In the analog domain, eye patterns are obtained
by displaying the received signal on the vertical input of an oscilloscope while the
horizontal sweep rate is set at 1/(kTb), where Tb is the symbol period and k is an
integer.
In the MATLAB script ‘pamtxrx.m’, the eye patterns are generated by dividing
the received signal to segments of length kTb. We have set k = 2. This is done by
using the function ‘reshape’ of MATLAB. The segments of the received signal are
then put together in a plot. Figures 6.2 and 6.3 show the eye patterns for a 2-level
PAM signal and two choices of ‘sigmav’ equal to 0 and 0.1. From these, it is clear
that in the absence of channel noise (and channel distortion), if the received signal
(after matched filtering) is sampled at correct time, the estimates of the transmitted
symbols will be exact. The presence of channel noise, as is apparent in Figures 6.3,
reduces the accuracy of the estimates. Also, the accuracy of the estimates reduces
in presence of an error in the sampling time.
The effect of channel distortion can also be visualized in an eye pattern. For
instance, if we choose1 c = [1; zeros(80,1); 0.5; zeros(119,1)] (a channel with two
distinct paths spaced apart by 80Tb/100 = 0.8Tb) and set the channel noise equal
to zero (to only have the effect of the channel distortion), we obtain the eye pattern
shown in Figures 6.4. As seen, the introduced distortion significantly affects the eye
pattern. The reader can do further exploration by making changes in the MATLAB
script ‘pamtxrx.m’. In particular, it is instructive to repeat the experiments with the
4-level PAM symbols. The result of such an experiment when ‘c = 1’ and ‘sigmav
= 0.1’ is presented in Figures 6.5.
1The additional 119 zeros at the end of ‘c’ are to keep the length of ‘y’ a multiple of 2L. This
is required for proper operation of the ‘reshape’ function.
Sec. 6.5 MATLAB Simulation of Digital Transmission Systems 157
0 0.5 1 1.5 2
−1.5
−1
−0.5
0
0.5
1
1.5
t/Tb
Figure 6.2: Eye pattern of a 2-level PAM signal. σv = 0.
0 0.5 1 1.5 2
−2
−1.5
−1
−0.5
0
0.5
1
1.5
2
t/Tb
Figure 6.3: Eye pattern of a 2-level PAM signal. σv = 0.1.
158 Quadrature Amplitude Modulated Transceiver Systems Chap. 6
0 0.5 1 1.5 2
−2
−1.5
−1
−0.5
0
0.5
1
1.5
2
t/Tb
Figure 6.4: Eye pattern of a 2-level PAM signal. σv = 0.1. The channel is multipath
with 2 paths spaced at 0.8Tb and have magnitudes of 1 and 0.5.
0 0.5 1 1.5 2
−5
−4
−3
−2
−1
0
1
2
3
4
5
t/Tb
Figure 6.5: Eye pattern of a 4-level PAM signal. σv = 0.1, c(t) = δ(t).
Sec. 6.6 MATLAB Simulation of Digital Transmission Systems 159
6.5 QAM Transceiver
The MATLAB script ‘qamtxrx.m’, presented on the next page, is a modified version
of ‘pamtxrx.m’. The transmit symbols are complex-valued and modulate a carrier
with frequency ‘fc’. The receiver assumes a carrier frequency ‘fc + Dfc’. A carrier
phase offset ‘phic’ is also included. We also have followed the QAM formulation
based on complex signals discussed in Section 3.3.2.
6.6 Eye Patterns in QAM Systems
In the case of QAM transmission, the demodulated signal y(t) is complex-valued.
Although the real and imaginary parts of y(t) can be treated separately and ac-
cordingly a pair of eye patterns be presented, it is more common to sketch y(t) in a
complex plane. An example of such eye pattern is shown in Figure 6.6, for a 4-QAM
(QPSK) signal. Here, the channel is ideal (i.e., distortion free) and free of noise.
There is no explicit time axis in this eye pattern. However, the time goes along the
plot as it moves between the constellation points (here, the points ±1 +±j).
−1.5 −1 −0.5 0 0.5 1 1.5
−1.5
−1
−0.5
0
0.5
1
1.5
real part
im
ag
in
ar
y
pa
rt
Figure 6.6: Eye pattern of a 4-QAM signal. σv = 0, c(t) = δ(t).
To obtain an idea of the quality of the demodulated signal, we may concentrate
on the samples of the demodulated signal at symbol intervals. By changing the
‘plot(y)’ in the display part of the MATLAB script ‘qamtxrx.m’ to ‘plot(y(1:L:end),’.’)’
and ‘plot(y(15:L:end),’.’)’, we obtain the results shown in Figures 6.7(a) and (b), re-
spectively. The first case corresponds to the best (optimum) sampling time where
the sample points match the transmit symbols exactly. A few dots at the origin
160 Quadrature Amplitude Modulated Transceiver Systems Chap. 6
MATLAB Script qamtxrx.m: QAM Transceiver
%
% PARAMETERS
%
Tb=0.0001; L=100; Ts=Tb/L;
fc=100000; Dfc=0; phic=0;
alpha=0.5; K=8; sigmav=0; c=1;
%
% SOURCE
%
b=sign(randn(1000,1));
%
% CODER
%
s=b(1:2:end)+i*b(2:2:end); % Binary to 4-QAM (QPSK) conversion
%
% TRANSMIT FILTERING
%
pT=sr cos p(K*L,L,alpha); % Transmit filter (square-root raised-cosine)
xbbT=conv(expander(s,L),pT); % Transmit signal
%
% MODULATION
%
t=[0:length(xbbT)-1]’*Ts; % Set the time
xT=real(exp(i*2*pi*fc*t).*xbbT);
%
% CHANNEL
xR=conv(c,xT); % Transmit the signal through the channel
xR=xR+sigmav*randn(size(xR)) ; % Add noise
%
% DEMODULATION
%
t=[0:length(xbbT)-1]’*Ts; % Set the time
xbbR=real(exp(-i*(2*pi*(fc-Dfc)*t+phic).*xR);
%
% RECEIVE FILTERING
%
pR=pT;
y=conv(xbbR,pR);
%
% DISPLAY
% Here, the eye pattern of the received QAM signal is displayed.
%
plot(t,y,’b’)
xlabel(’real part’)
ylabel(’imaginary part’)
Sec. 6.7 MATLAB Simulation of Digital Transmission Systems 161
correspond to the transient parts of the signal at the beginning and end of trans-
mission. In the second case, samples are chosen at a timing phase which is 15% off
from the optimum sampling timing. Compare these with Figure 6.2 and imagine
the cases where the samples are taken at the optimum and a non-optimum timing
phase.
−2 −1 0 1 2
−1.5
−1
−0.5
0
0.5
1
1.5
real part
im
ag
in
ar
y
pa
rt
(a)
−2 −1 0 1 2
−1.5
−1
−0.5
0
0.5
1
1.5
real part
im
ag
in
ar
y
pa
rt
(b)
Figure 6.7: Eye pattern of a 4-QAM signal when samples of specific timing phases
are shown. (a) Optimum timing. (b) 15% timing phase error. σv = 0 and c(t) = δ(t).
Figures 6.8, 6.9 and 6.10 show more examples of the QAM eye patterns with some
channel noise, phase offset, and carrier offset, respectively. As one would expect,
noise makes the eye patterns more erratic. Specifically, one may find that near the
optimum timing phase the plots no longer pass through the constellation points
±1 ± j. A phase offset φ rotates the eye pattern by the same amount. A carrier
offset ∆fc results in an spinning of the eye pattern with the same frequency. All
these are relatively obvious facts that can be understood from the QAM formulation
based on complex signals discussed in Section 3.3.2.
Other studies that prove useful to a reader of this text, at this point, are to
examine the spectra of the various signals in both the MATLAB scripts ‘pamtxrx.m’
and ‘qamtxrx.m’. The function ‘spec analysis.m’ on the accompanying CD, is a
convenient tool for performing such explorations. A number of problems at the end
of this chapter have been designed to serve this purpose.
162 Quadrature Amplitude Modulated Transceiver Systems Chap. 6
−1.5 −1 −0.5 0 0.5 1 1.5
−1.5
−1
−0.5
0
0.5
1
1.5
real part
im
ag
in
ar
y
pa
rt
Figure 6.8: Eye pattern of a 4-QAM signal. σv = 0.1, c(t) = δ(t), ∆fc = 0.
−2 −1 0 1 2
−2
−1.5
−1
−0.5
0
0.5
1
1.5
2
real part
im
ag
in
ar
y
pa
rt
Figure 6.9: Eye pattern of a 4-QAM signal. σv = 0, c(t) = δ(t), ∆fc = 0.
Sec. 6.7 MATLAB Simulation of Digital Transmission Systems 163
−2 −1 0 1 2
−2
−1.5
−1
−0.5
0
0.5
1
1.5
2
real part
im
ag
in
ar
y
pa
rt
Figure 6.10: Eye pattern of a 4-QAM signal. σv = 0, c(t) = δ(t), ∆fc = 10.
6.7 The Impact of Frequency Offset on the Baseband
Equivalent of Passband Channels
We recall from Chapter 3, Section 3.6, that any passband channel has an equivalent
baseband that is characterized by a complex-valued impulse response. The question
that we wish to answer here is “how the impulse response of the baseband equivalent
of a passband channel is affected by a carrier offset ∆fc?”.
To answer this question, we consider the QAM communication system that is
presented in Figure 6.11. This is similar to Figure 3.19 with the difference that,
here, a frequency offset ∆fc is introduced at the receiver. Also, as in Figure 3.19,
to simplify the derivations, the channel noise is ignored. To study the baseband
equivalent channel of Figure 6.11, we take a different approach than the one used
in Section 3.6, where we took a frequency domain approach. Here, we take a time
domain approach. To develop an insight, we first study the time domain response
of the channel to the data symbol s[0], i.e., the data symbol that is transmitted at
the time instant t = 0. Once
本文档为【signal processing techniques for software radio-chp6】,请使用软件OFFICE或WPS软件打开。作品中的文字与图均可以修改和编辑,
图片更改请在作品中右键图片并更换,文字修改请直接点击文字进行修改,也可以新增和删除文档中的内容。
该文档来自用户分享,如有侵权行为请发邮件ishare@vip.sina.com联系网站客服,我们会及时删除。
[版权声明] 本站所有资料为用户分享产生,若发现您的权利被侵害,请联系客服邮件isharekefu@iask.cn,我们尽快处理。
本作品所展示的图片、画像、字体、音乐的版权可能需版权方额外授权,请谨慎使用。
网站提供的党政主题相关内容(国旗、国徽、党徽..)目的在于配合国家政策宣传,仅限个人学习分享使用,禁止用于任何广告和商用目的。