WARP Project Forums - Wireless Open-Access Research Platform

You are not logged in.

#1 2013-Feb-26 05:44:10

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

implement algorithms in WARPLab

Hi, Patrick

I want to implement our algorithms in the OFDM model. I am wondering whether the following approach is doable.
We want to do some modification before the QAM. At first I want to implement our algorithm in the  WARPLab. I mean I modulate the data in the Matlab (in the OFDM way) and then download the data to the Transmitter I/Q buffer.

Is it doable? I assume the Matlab programming is easier than the System Generator modification. So i wan to verify the idea first in the WARPLab.

Thx.

Offline

 

#2 2013-Feb-26 10:27:43

chunter
Administrator
From: Mango Communications
Registered: 2006-Aug-24
Posts: 1212

Re: implement algorithms in WARPLab

Yes, that is precisely why we built WARPLab. It's a way for you to prototype your algorithm with offline processing in Matlab, which is an easier environment to try things in than System Generator or other HDL. Then, you can start to "harden" pieces of your design into the WARPLab core itself if it makes sense to do so.

A useful starting point for your work might be Robin Klose's work with Technische Universität Darmstadt in MIMO OFDM for WARPLab.

Offline

 

#3 2013-Feb-26 10:53:47

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Thank you so much, chris.
And the example is really helpful.

Offline

 

#4 2013-Mar-06 05:18:28

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Hi,

I have read the OFDM model proposed by Technische Universität Darmstadt. But their model is not based on 802.11a. Do you know any 802.11a OFDM example implemented in WARPLab?

Thanks a lot.

Offline

 

#5 2013-Mar-06 08:53:12

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

I'm not aware of anyone who has implemented an 802.11 PHY in WARPLab.

Offline

 

#6 2013-Mar-07 10:10:47

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Hi, murphpo, I find a Matlab simulation code for ieee 802.11a online. I want to use it to generate the ofdm signal. I have a question about the input data to warplab.
I first use the Matlab simulation model to generate a data sequence(modulation->add pilot->ifft->add cp->add preamble). Should there be any other processing to the generated data before I use it as the input data in warplab, like in the

Code:

Node1_Radio2_TxData = exp(t*j*2*pi*1e6);

from warplab_siso_example_TxRx.m

Thanks.

Last edited by Junqing Zhang (2013-Mar-07 10:11:30)

Offline

 

#7 2013-Mar-07 11:16:37

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

One issue will be the sample rate. The WARPLab ref design drives/captures samples at 40MHz, but 802.11a operates with 20MHz bandwidth. You'll need to implement the interpolation/decimation between the 802.11 waveform (probably assumes 20MHz sampling) and 40MHz. You can do this in MATLAB pretty easily with its interp/decimate routines.

Offline

 

#8 2013-Mar-07 11:28:51

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

OK. Thanks. I will try it.

Offline

 

#9 2013-Mar-08 06:14:31

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Hi, murphpo, sorry to bother you again. I am not good at communication theory, so I am still not quite sure about why we need interpolation/decimation here. Could you kindly help me to explain in detail? Thanks.
By the way, when you say we need interpolation/decimation here, say the data after the process(modulation->add pilot->ifft->add cp->add preamble) is y, at the transmitter side, for example,

Code:

x=1:1:length(y);
xi=1:0.5:length(y);
yi=interp1(x,y,xi,'linear');

then I use yi as the data input to the warplab.
and at the receiver side, after the data processed by the warplab,

Code:

yii=decimate(yi,2);

Right?

Last edited by Junqing Zhang (2013-Mar-08 06:15:03)

Offline

 

#10 2013-Mar-09 09:32:18

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Hi, murphpo,

I read the warplab_siso_example_Comm, in line 131, you process the data by a raised cosine filter before downloading to the warp node.
Is this operation the same purpose as the interpolation you mentioned before?

Thanks.

Offline

 

#11 2013-Mar-09 13:11:34

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

The rate change method depends a lot on the waveform and your bandwidth requirements. In general MATLAB's interp() and decimate() are good places to start. upfirdn is another useful function, especially for non-integer rate changes. I would suggest using interp(x,2) and decimate(x,2) as a starting point and see how it works.

Offline

 

#12 2013-Mar-09 15:21:31

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Thanks for your reply, murphpo.
So the interpolation/decimation and raised cosine filter have different functions here. Interpolation/decimation is to balance the bandwidth of wifi and the drive/sample rate. And raised cosine filter is for pulse shaping. right?

As to my requirement, I need interpolation/decimation and raised cosine filter here, right?

And you suggest using interp(x,2) and decimate(x,2) as a starting point, is it because the sampling rate(40MHz) is double of the wifi bandwidth(20MHz)?

Thanks for your help.

Offline

 

#13 2013-Mar-10 22:45:09

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

As to my requirement, I need interpolation/decimation and raised cosine filter here, right?

And you suggest using interp(x,2) and decimate(x,2) as a starting point, is it because the sampling rate(40MHz) is double of the wifi bandwidth(20MHz)?

My suggestion of interpolation/decimation by 2 is based on 802.11a using 20MHz bandwidth and WARPLab operating with 40MHz bandwidth (complex baseband sampled at 40Msps). But I have no idea what the reference code you're using assumes for sampling rates and bandwidths.

Offline

 

#14 2013-Mar-11 16:53:38

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Hi, murphpo. Sorry to bother you again.
The source code i found is based on IEEE 802.11a. As IEEE 802.11a is operating on 5GHz, could you tell me how to set the warplab to let it work in 5GHz?
I notice in the examples, the Channel is all set to 2.4GHz.

Code:

CarrierChannel = 12; % Channel in the 2.4 GHz band. In [1:14]

Besides, are there any other special modifications that should be made to the warplab code due to the frequency change?

Offline

 

#15 2013-Mar-11 19:55:53

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

The source code i found is based on IEEE 802.11a. As IEEE 802.11a is operating on 5GHz, could you tell me how to set the warplab to let it work in 5GHz?

Use the normal WARPLab call (warplab_setRadioParameter(udp_node1,CARRIER_CHANNEL,chan);) with chan values > 14. Channel values 15-38 translate to 5GHz channels 1-23 (see this table for the resulting center frequencies).

It's worth noting that the 802.11a waveform will work fine at 2.4GHz (the OFDM-only mode of 802.11g is the same waveform at 2.4GHz).

Offline

 

#16 2013-Mar-12 05:10:09

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Thanks murphpo.

Offline

 

#17 2013-Mar-25 18:27:54

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Hi, murphpo, sorry to bother you the interpolation/decimation question again.

I have understood why are the interpolation/decimation needed here. Say the sequence I want to transmit is [a1,a2,a3,...]. As the bandwidth of the sequence is 20MHz but the DA clock is 40MHz, interpolation is needed here. Say after interpolation, the sequence is [a1,b1,a2,b2,a3,b3,...]. This sequence is converted by the 40MHz clock and it can be regarded as the original sequence [a1, a2, a3,...] converted by a 20MHz clock. Is my above analysis right?

In the warplab_siso_example_Comm, you used a raised cosine filter. As far as I know, this filter could eliminate the ISI. And in your code, the upsample rate is set as 8.

If my analysis above about the interpolation is right, it is not possible to implement the pulse shaping in my model, right? As after upsample, it doesn't satisfy the requirement between bandwidth(20MHz) and DA clock(40MHz).

Or, can I set the upsample rate as 2, and discard interpolation. Is it doable?

Thanks.

Last edited by Junqing Zhang (2013-Mar-25 18:28:46)

Offline

 

#18 2013-Mar-26 10:45:05

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

The raised cosine filter is useful in limiting ISI in a single carrier waveform, as in the WARPLab comm example. For simple interpolation/decimation by 2x, a simple low pass filter is sufficient (something like a halfband filter is good for implementation; the filters built into MATLAB's interp/decimate functions are also good options).

Offline

 

#19 2013-Apr-05 16:28:52

Junqing Zhang
Member
Registered: 2012-Nov-28
Posts: 121

Re: implement algorithms in WARPLab

Hi, murphpo,
I integrated my Matlab model and warplab code together. But the performance is not very good. When I use 16QAM, the BER is really high. I guess maybe it is because synchronization and channel estimation algorithms used in the code is not robust enough.

Could you kindly tell me the synchronization and channel estimation algorithms used in the WARP reference design(I mean, the System Generation model)? If you could give me some papers you refer to, that would be brilliant.

Thanks for your help.

Offline

 

#20 2013-Apr-08 09:17:36

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

The Schmidl Cox paper on synchronization for OFDM is a good starting point.

Offline

 

#21 2018-Apr-30 08:49:53

alice_warp
Member
From: Italy
Registered: 2015-Sep-08
Posts: 53

Re: implement algorithms in WARPLab

murphpo wrote:

The raised cosine filter is useful in limiting ISI in a single carrier waveform, as in the WARPLab comm example. For simple interpolation/decimation by 2x, a simple low pass filter is sufficient (something like a halfband filter is good for implementation; the filters built into MATLAB's interp/decimate functions are also good options).

Hi murphpo,
in WARPLab 7, in the code wl_example_siso_ofdm_txrx.m...raised cosine filter is not implemented for ISI, right? Is the interpolation/decimation by 2x filter (used in the code) enough for this purpose?

Thank you in advance.

Alice

Offline

 

#22 2018-Apr-30 09:27:26

murphpo
Administrator
From: Mango Communications
Registered: 2006-Jul-03
Posts: 5159

Re: implement algorithms in WARPLab

The interpolation/decimation filter is a halfband filter, an efficient filter for 2x sample rate changes. The WARPLab OFDM examples do not implement raised cosine pulse shaping filters (not strictly necessary with OFDM where subcarriers are inherently orthogonal if the Rx PHY achieves sufficient synchronization).

Offline

 

Board footer