You are on page 1of 6

Design and Implementation of A Real-Time

ERP-OFDM SDR Receiver on the USRP2 Platform


Kerem Kucuk
Department of Computer Engineering
Kocaeli University
Kocaeli, Turkey
Email: kkucuk@kocaeli.edu.tr

Abstract-In this paper, the real time ERP-OFDM wireless lo­ In the literature, there are some SDR based receiver designs
cal area network (WLAN) receiver prototype and its performance to measure speciic characteristics in the desired network.
analysis based on IEEE 802.11g physical layer requirements
Digital beacon receiver presented in [4] uses USRP to measure
are presented. We design and implement a sotware deined
radio (SDR) receiver for all ERP-OFDM WLAN functionalities.
high frequency beacon measurement. In [5], test method is ap­
The receiver prototype setup based on the universal sotware plied to receiver and transceiver I1Q imbalance measurements
radio peripheral 2 called USRP2 with National Instruments on the USRP equipped with FLEXRF1800 and XCVR2450
(NI) LabVIEW sotware. It consists of a dipole antenna, the daughter boards. Chen et al. [6] examined two hardware
USRP2, and a computer setup USRP2 driver. In this prototype
platforms USRP2 and small-form-factor development platform
implementation, we deal with signal synchronization, phase
estimation, channel estimation, and demodulation over the real
to quantify minimum response delay. Shah et al. [7] studied
wireless channel conditions. To validate the real-time prototype positioning algorithm using RF signals. To demonstrate the
receiver, the spectrum of 2.4 MHz band is measured by IEEE ability of their technique, GNU radio and its hardware com­
802.11g supported Wi-Fi card. Moreover, the prototype receiver panion, USRP are used. The SDR IEEE 802.11 b receiver in
and Wi-Fi card performances are in very closed agreement with a
[8] enables practical channel impulse response estimation. The
frame error rate of 1 %. Hence, this prototype has been designed
successfully to implement all PHY functions of ERP-OFDM.
receiver is built on GNU radio and USRP hardware.
Keywords-IEEE 802.11g, OFDM, SDR, USRP2, LabVIEW,
Real-Time, Receiver. In this paper, we have focused on the real-time imple­
mentation of ERP-OFDM WLAN protocol baseband receiver
I. INTRODUCTION prototype and validation of it with uncontrolled wireless
Wireless local area networks (WLAN) have been used with trafic. This baseband prototype has been developed to be a
the increasing capacity and wide range applications [1] in valuable research and education tool in ERP-OFDM channel
the last decade. Rapid prototyping and veriication of the measurements. The implementation is built upon National
WLAN receiver are important to determine the WLAN system Instruments's (NI) LabVIEW software tool [9] and Ettus
performance. To adapt and to meet requirements of these Research's universal software radio peripheral 2 (USRP2) [10]
systems, software deined radio (SDR) implementations is equipped with XCVR2450 daughter board. At the receiver,
relied. Prototyping WLAN receivers on SDR platform that is the USRP2 motherboard is placed between the RF ront-end
universal software radio peripheral 2 (USRP2) is becoming a and the host computer. In general, conventional methods for
common technology for research to education [2]. receiver design are prototyping on the board or programming
The one of the most popular PRY in IEEE standards is an ield programmable gate array (FPGA) chip. These methods
ERP-OFDM [3]. The OFDM technique achieves the robust­ may take a longer time than to design the SDR. This prototype
ness against narow-band interference. To use the overlapping design is practical to be used complete WLAN receiver.
multi-carrier technique, however it requires reducing crosstalk Additionally, the baseband receiver prototype measurements
among sub-carriers, which means that orthogonality between are compared to the produced Wi-Fi card measurements in
the dilerent modulated carriers is provided. In the IEEE terms of frame error rate.
802.11g standard, the OFDM based transmission technique
provides a WLAN with data payload communication capabil­ The paper is organized as follows. Section II revIsits
ities of 6-54 Mbitls. The IEEE 802.11g [3] uses mainly OFDM transmit modulation of ERP-OFDM. Section III explains the
technique but can promote spread spectrum modulation if any theoretical background the ERP-OFDM receiver design. The
one component of the system has older equipment. implementation of the ERP-OFDM receiver on LabVIEW
with USRP2 platform is discussed in Section IV. Section
This study has been supported by the Scientiic and Technological Research V describes the evaluation of the prototype receiver and
Council of Turkey (TUBITAK) under project grant I059BI91000372 and
Scientiic Research Project Units of Kocaeli University under project grant performance comparison, and inally the conclusion of the
2013/13. paper is presented in Section VI.

ISBN: 978-1-4673-9609-7 ©2016 IEEE 24


II. TR ANSMIT MODULATIONS FOR ERP-OFDM SIGNAL pilot sub-carier, and M(k) expresses the mapping sub-carrier
In the ERP-OFDM transmitter, the transmitted OFDM number into requency olset index. The OFDM transmitter
frame is consists of several OFDM symbols. The frame con­ output can be written as;
tains a physical layer convergence protocols (PLCP) OFDM NsyM-1
preamble, signal ield and data portion. The OFDM preamble SDATA(t) =
L SDATA,n(t - nTsyM), (2)
has 12 symbols used to synchronize the receiver. The signal n=O
ield express the parameters of the following data packet of where NSYM is the number of transmitted OFDM symbols
the physical layer service data unit (PSDU) payload. Data part and TsyM is the symbol interval.
contains a dilerent number of symbols.
The OFDM training structure has short training (ST) sym­ III. ERP-OFDM RECEIVER DESIGN

bols and long training (LT) symbols 10 times and 2 times In the OFDM based systems such as IEEE 802.11 g, the
respectively. While the ST symbols are used for detection of discrete time OFDM signal with N sub-carriers is expressed
signal, gain control and estimation of coarse requency, the LT as [11] [12];
N-1
symbols are used for frequency and channel estimation stages.
After the IFFT and multiplied by the window function, short
x(n) =
L X(k)ej2ryn, (3)
k=O
preamble signal is obtained. Two periods of the LT symbols
are transmitted for ine requency and the channel estimation. where X(k) is the vector of complex modulation. The received
After the IFFT, adding guard interval (GI) and multiplied by data is retrieved by FFT on the received signal as;
1 k
X(k) ;::0 x(n)ej2rN k E [0,N -
the window function, time domain long preamble signal is =
1]. (4)
constituted.
The OFDM preamble is followed by the signal ield PRY If additive white Gaussian noise (AWGN) is considered, the
of PLCP section. It consists of the rate and length of the received OFDM signal is expressed by
y(n) x(n) @ h(n) + w(n),
transmitted data. The signal ield encoding is performed with =
(5)
the BPSK modulation and convolutional encoding (CE) at
R =
1/2. The signal ield encoding procedure includes CE, where hen) is the channel impulse response (CIR). The mul­
interleaving, modulation mapping, pilot insertion, and OFDM tipath CIR is described;
technique. The OFDM signal ield is followed by the data L-1
ield. Data ield contains two octets zero for service ield that h(n) =
L hzej2rin,TN 6, - TZ ), (6)
initializes data scrambler, variable length of data octets from z=o
medium access control (MAC) layer, encoder is reset by 6 tail where h(Z) is the CIR of Zth path, L is the number of the total
bits and required pad bits. The data ield encoding procedure propagation paths,fD, is the Doppler requency of the lth path,
includes scrambling, CE, puncturing, interleaving, modulation A is the index of the delay spread and TZ is the delay of the Zth
mapping process, pilot insertion, and OFDM modulation. The path. After discarding GI from yen), FFT processing is done
data ield is scrambled by the frame synchronous scrambler. on the received signals. Then the time domain received signals
The convolutional encode of the transmitter of the ERP-OFDM are transformed to the frequency domain signals.
uses the standard generator polynomials. The higher data rates
1 - n
are achieved by using other rates and puncturing patterns. Y(k) =
r ;::0 y(n)e j2ry k E [0,N - 1]. (7)
The data interleaving of ERP-OFDM is deined by two step
Assume that the GI is longer than the length of CIR, that
permutation. While the irst step provides coded bits with non­
is, there is no lSI between OFDM symbols, the transformed
adjacent sub-carriers, the second step provides coded bits with
signals Y(k) can be expressed by:
the less and more signiicant bits of the constellation.
The output of the modulation mapping process is translated Y ( k) =
X(k)H(k) + W(k)k =
... , N
0,1, - 1, (8)
time domain by 64-point IFFT. The transmitter output for one
where W(k) is AWGN Fourier transform, the discrete re­
OFDM symbol can be expressed as;

(�
quency impulse response of multi-path channel H(k) is written
N l M(k).dt-TGT) as;
sin(nln T)
SDATA,n(t) WTS(t) + dk,nej2r
in T nIn � -J' 2nT, k
H(k) hZej2r ,. ., e
=

k=O N (9)
=

NST/2
Pkej2rk.F(t-TGJ) , (1)
)
The transmitted signals X(k) can be estimated;
+Pn+1 + L
( k)
k=-NsT/2 X(k) � , (10)
H(k)
=

where, WTS is the windowing function of duration time, To!


is the GI duration, NSD and NST are the number of data and where X(k) is the estimation of CIR. The basic OFDM re­
total sub-carriers, dk,n is the complex number coresponding ceiver used in this project is shown in Fig. 1. After the received
to the kth sub-carrier of the nth OFDM symbol, the frequency signal down converted to the baseband, the receiver performs
spacing is ..F, Pn is the scrambling sequence, Pk is the the preamble correlation. It is the irst data processing block of

ISBN: 978-1-4673-9609-7 ©2016 IEEE 25


the ERP-OFDM baseband receiver. Then the receiver estimates be corrected with the coarse frequency estimation. The coarse
frequency ofset and symbol timing with the ERP-OFDM correction is given by;
preamble. After erasing the guard interval, the signal is applied
(16)
to FFT to demodulate the sub-carriers. The preamble and pilots
are used to correct for the channel. Demodulated sub-carriers Then, the corrected long preamble samples are used for ine
can be applied to de-interleaver. Finally, a Viterbi decoder and requency estimation as follows;
de-scrambler decode the information bits.
In the OFDM receiver, synchronization must be performed
before it can be demodulate the sub-carriers. The synchro­
al t =
1
64
L (�Lt(k)*Lt(k ) + 64) . (17)

nization process consists of at least two synchronization Finally, the total phase estimation (asT + aLT) is used for
tasks which are timing and frequency ofset estimations. The carrier requency correction for the remaining part of the rame
preamble based synchronization technique is used. The IEEE after the long preamble. The GI part of the OFDM symbol
802.11 g preamble contains the two repeated sample sequences. is removed rom the frequency and timing ofset corrected
In fact, the synchronization algorithms are essentially based samples. Then the signal is sent to the FFT processing block.
on determining the highest correlation between two repeated The channel is assumed static over a whole frame so
sample sequences. Therefore, the packet detection and the that once the channel is estimated; it's response is used to
timing ofset is expressed as; compensate the signal for the whole frame. In the literature,
IP(d)j2 there are lots of kind channel estimation techniques [13]. The
M(d) =
(11) most common idea is the least square (LS) solution which is
R(d)2 '
block-type. The idea of the LS is to minimize of the parameter

;r*(d k)r ( k
where
N/2 (Y - XH)H (Y - XH). LS channel estimate is expressed by
P(d) =
+ d+ + �), (12) (18)

R(d) L Ir(d
=
2
1
N-l
+ k)j2, (13)
k
The four pilot sub-carriers that are inserted into an OFDM
symbol at sub-carrier index E [-21, -7, + 7, + 21] can be used
to estimate remaining linear phase. After FFT processing and
k=O channel compensation of the received signal, the received pilot
where N is length of the preamble, k = 0,... , N-l. The symbol sub-carriers are related to the know pilot sub-carriers P n,k. The
timing estimation can be expressed from, remaining phase estimate ¢ n can be computed as;

t =
argmax(M(d)). (14)
d (19)
At the receiver, the received OFDM frame is illustrated in
Fig. 2. This frame is approximately starting in 5Ls with ten where, k is subcarrier index. Thus the compensated signal can
times ST signal and two times LT. The packet is set to start be expressed as;
at 0 and delay of correlation 16 samples. When the packet
Yn, k =
Yn, ke(-jP,). (20)
start is received, the cross-correlation of the ST symbols cause
M( n ) to move to the highest value. The frame is observed if After these processing steps, the sub-cariers of the received
the metric is higher than a threshold at determined sequential OFDM symbols are demodulated into binary representation,
samples. The frame synchronization is accomplished using the then these bit stream are deinterleaved, depunctured, decoded
second corelation decision statistic. The move of M( n ) at the using Viterbi algorithm and descrambled [14].
400-th sample gives an estimation of the preamble.
Using (14), the accurate preamble point of symbol
can be estimated. Then, the short preamble can be used for
Copt IV. RE AL-TIME IMPLEMENTATION OF
RECEIVER
T HE ERP-OFDM

St(k),
frequency ofset estimation. It's last 3 parts are assumed as Real-time ERP-OFDM receiver's GUI is built in LabVIEW
where k=O,I,. . . , 47. The coarse frequency estimation as shown in Fig. 3. The Receiver Parameters In and RX
is given by; Parameters Out ields in the main.vi of ERP-OFDM GUI dis­
play the preamble detection, PSDU information and received
signal, received signal data rate, time synchronization diagram,
(IS) signal constellation, signal ield demodulation and service
ield & PSDU demodulation ields. They show the speciic
The coarse frequency estimation value is stored to be used information depends on captured signal. ERP-OFDM program
in the ine frequency estimation. The long preamble can be blocks implemented in LabVIEW are illustrated in FigA.
used for ine frequency estimation. The long preamble has the These blocks provide basic OFDM receiver requirements. A

Lt(k),
two identical parts. They have totally 128 samples denoted as
where k=O,I, . . . ,127. The long preamble samples must
brief summary of each blocks task in ERP-OFDM receiver are
explained as follow.

ISBN: 978-1-4673-9609-7 ©2016 IEEE 26


Frequency
Demodulator
Estimation

Binary
Timing
output Descrabler Deinterleaver
Estimation
data

Fig. I. Typical block diagram of the OFOM receiver.

O Received OFDM frame


s O --

-


� -10


.� -20 .."'1.1"'1,''
!
0
J
� -30
E
o o 5 10 15 20 25 30 35
z
Time (�s)

Fig. 2. Captured OFDM frame in dB scale

Fig. 3. ERP-OFDM receiver GUI screen.

1) Carrier Detection Block: implements averaging low pass 3) Frame Detection Block: detects ERP-OFDM rame
ilter on a series of digital samples from captured data. based on the timing metric in 80 consecutive samples. Here,
2) RX Filter Block: accepts the low pass ilter output as the threshold is chosen 0.8.
input and decides signal detection when the threshold value is 4) Time Synchonization Block: provides timing synchro­
between the two consecutive input signal. Both RX Filter and nization on the received OFDM frame, locates the irst sample
Carrier Detection blocks constitute carrier sense mechanism. of the frame, and implements frame synchronization.

ISBN: 978-1-4673-9609-7 ©2016 IEEE 27


Fig. 4. ERP-OFDM receiver program blocks in LabVIEW.

5) CFO Estimation Block: computes and corrects of the 15) Data Demodulation Block: provides each subcarier
CFO on the received signal. with the binary representation depends on its modulation
6) Channel Estimation Block: can compute the channel's schemes determined by Signal Field Determination Block.
coeficients. 16) De-scambler Block: de-scrambles the output of the
7) Phase ffset Block: computes the phase and corrects the BPSK Demodulation Block using the standard generator poly­
remaining phase olset. nomial.
8) BPSK Demodulation Block: maps each sub-carrier back 17) CRC-32 Block: computes CRC-32. In the ERP-OFDM
into the 0 and l. signal, service and data is protected with CRC-32 by the
9) De-Interleaver Block: is used as a de-interleaver. It polynomial as in the standard.
performs two inverse step of an interleaver. This block uses PSDU Determination Block extracts octets from the bit se­
rate dependent parameters to de-interleave the bit sequence quence and determines frame control ield which says protocol
from [3]. version, frame type, sub-type, and some information about
the frame. After determining the type and sub-type of frame,
10) Viterbi Decoder Block: decodes bit stream using
this block extract all information based on the frame. Data
Viterbi algorithm with forward error corection. The trace back
Display Block shows and saves the information determined
depth is usually used 8 and 10 times constraint length for 2/3
for each ERP-OFDM signal until stop button is used. Lastly,
and 3/4 rate puncturing codes. In our design, trace back length
if a problem causes in the program, Eror Out ield lists the
is used 10 times constraint length.
error information with the LabVIEW code.
11) Signal Field Determination Block: provides data rate
parameters, number of octet and symbol in the OFDM frame. V. SDR RECEIVER EXPERIMENTAL RESULTS
This block also implements irst bit level correction using In order to evaluate the performance of the implemented
parity check bit over the irst 18 bits of the signal ield. If this ERP-OFDM, IEEE 802.11 signals captured in Wireless Infor­
correction is failed, then the demodulation process is inished. mation System Laboratory (WISLAB) are taken into consider­
If the correction is passed, then the demodulation process is ation. There is no any our control on the captured signal, so we
continued through CFO Correction Block. This information is could achieved the exact real-time performance of designed
shown in ERP-OFDM GUI's Signal Field Demodulation area. receiver in the real environment. The measurement setup of
12) CFO Correction Block: corrects the remaining received the LabVIEW ERP-OFDM is composed of a USRP2 board
signal samples. The length of corection is determined previ­ plugged to a notebook and connected to an extenal antenna.
ous block. LabVIEW NI USRP2 driver collects the data rom antenna,
13) Channel Correction Block: implements channel equal­ the program block in LabVIEW demodulates the received
ization over the input signal using the coeficients from Chan­ data packet, and puts in the LabVIEW GUI. The RF front­
nel Estimation Block. end is a RFX2400 daughter-board with the dipole antenna.
14) Phase Correction Block: corrects phase olset over the The input data can be changed by each number of samples
input signal. block of LabVIEW during the program is in progress. The

ISBN: 978-1-4673-9609-7 ©2016 IEEE 28


TABLE I prototype ensures the real time data samples reception. The
LAB VIEW RECEIVER PARAMETERS.
lexibility of the NI LabVIEW software agree to user easily
Parameter ERP-OFDM
matching the receiver to provide a real-time throughput of
Device Names 192.168.10.3 different data rate while operating at 2.4 GHz. This receiver
Active Antenna RX2 models is tested on the actual wireless environment and oper­
Rx Sampling Rate 20M
ates accurately shown with the frame error rate results. Clearly,
Rx Gain 40dB
Number of samples 400000 the designed receiver has the potential to implement other
802.11 Channel 12 signal processing techniques to improve receiver performance
CS Threshold 5e-5 that requires less frame error rate. The main advantage of this
receiver is that constructed using LabVIEW program blocks
o dB attenuation instead of other receiver test-beds that are normally dedicated
systems and when the user wants to see performance any other
algorithms, this prototype receiver can be easily updated.
ACKNOWLEDGMENT

The authors would like to thank the Dr. Murat Torlak for
his many valuable comments and suggestions to improve the
2_72%
quality of the paper.
RE FERENCES

[I] A. Molisch, Wireless Communications. Wiley-IEEE Press, 2005.


[2] M. EI-Hajjar, Q. A. Nguyen, R. G. Maunder, and S. X. Ng, "Demon­
strating the practical challenges of wireless communications using usrp,"
1271 0071 1252 120E 0678 1270 1078 1250 DC5D othr lEEE Comm. Mag., vol. 52, no. 5, pp. 194-201, May 2014.
MAC address [3] ISO/IEC Standard /or In/ormation Technology- Telecommunications and
Jnnation Exchange Between Systems- Local and Metopolitan Area
Networks- Specic Requirements- Part II: Wireless LAN Medium Access
Fig. 5. ERP-OFDM receiver frame error rates for the laboratory experiment.
Contol (MAC) and Physical Layer (PHY) Specications Amendment 4:
Further Higher Data Rate Extension in the 2.4 GHz Band, Std., 2006.
[4] M. Chetfena and L. Braten, "Low-cost digital beacon receiver based
captured data are processed to LabVIEW block to get real-time on software-deined radio;' Antennas and Popagation Magazine. IEEE,
vol. 53, no. 1, pp. 50 -55, feb. 2011.
results. In this case, the experimental results can be shown on
[5] c. Rojas, P. Zetterberg, and . Handel, "Transceiver inphase/quadrature
LabVIEW GUI screen window in real time. The spectrum of imbalance, ellipse itting, and the universal software radio peripheral,"
WLAN is measured and saved both the prototype receiver and Instrumentation and Measurement, IEEE Tansactions on, vol. 60,
no. ll, pp. 3629 -3639, nov. 2011.
PC which has a Wi-Fi card at the same time. The main GUI
[6] Z. Chen, N. Guo, Z. Hu, and R. Qiu, "Experimental validation of
parameters of the design SDR receiver are shown in Table I. channel state prediction considering delays in practical cognitive radio,"
In Fig. 5, the frame error rate and channel estimation with Vehicular Technology, IEEE Tansactions on, vol. 60, no. 4, pp. 1314
-1325, may 2011.
one LT at channel 1 in 2.4 GHz are reported for the determined
[7] S. Shah, S. Srirangarajan, and A. Tewik, "Implementation of a direc­
most packet generated nine wireless devices. We record 10000 tional beacon-based position location algorithm in a signal processing
captured rames. Fig. 5(a) shows number of IEEE 802.11 framework," Wireless Communications, IEEE Tansactions on, vol. 9,
no. 3, pp. 1044 -1053, march 2010.
frame type with frame error rate for each wireless devices.
[8] D. Maas, M. Firooz, J. Zhang, N. Patwari, and S. Kasera, "Channel
Even if the irst MAC address has the most number of frames sounding for the masses: Low complexity gnu 802.11 b channel impulse
which is almost 2500 and almost 110 data rames, it's frame response estimation," Wireless Communications, IEEE Tansactions on,
vol. ll, no. 1, pp. 1 -8, january 2012.
error rate is only 2.72%. The second MAC address has the
[9] Labview system design software. [Online]. Available:
most frame error rate which rames are data rames. The other http://www.ni. com/labview/
bar represents the remaining MAC address determined by the [10] Ettus research llc. [Online]. Available: http://www.ettus.com/
[II] F. Wu and M. A. Abu-Rgheff, "Time and frequency synchronization
receiver. The receiver has captured frames rom 115 diferent
techniques for ofdm systems operating in gaussian and fading channels:
wireless devices for this case. All of this MAC addresses have A tutorial," in T he 8th Annual Postgraduate Sym. on T he Convergence
also corrected by software wireless snifer. When the frame of Telecom., Net. and Boadcasting (PGNET), June 2007.
[12] S. Qin, P. Liu, X. Zhang, L. Zheng, and D. Wang, "Channel estimation
error rates are compared between the prototype receiver and
with timing offset based on psd & Is estimation for wireless ofdm
Wi-Fi card, Wi-Fi card provides better frame error rate within systems," in Intelligent Signal P ocessing and Communication Systems,
1% for all captured rames. This error behavior is expected 2007. ISPACS 2007. Int. Sym. on, Dec. 2007, pp. 248-251.
[13] M. Ozdemir and H. Arslan, "Channel estimation for wireless ofdm
because the receiver prototype is determine the carrier with
systems," Communications Surveys Tutorials, IEEE, vol. 9, no. 2, pp.
the IQ signals in the baseband stage. 18 -48, 2007.
[14] A. Tran, D. Truong, and B. Baas, "A complete real-time 802.lla base­
VI. CONCLUSION band receiver implemented on an array of programmable processors;' in
Signals, Systems and Computers, 2008 42nd Asilomar Conference on,
In this paper, the design of real-time SDR receiver com­ oct. 2008, pp. 165 -170.
patible with the ERP-OFDM and its blocks on the LabVIEW
software with the USRP2 driver are presented. The receiver

ISBN: 978-1-4673-9609-7 ©2016 IEEE 29

You might also like