主要内容

Simulate Propagation Channels

This example shows how to simulate propagation channels. It demonstrates how to generate cell-specific reference signals, map them onto a resource grid, perform OFDM modulation, and pass the result through a fading channel.

Specify the cell-wide settings as fields in the structureenb. Many of the functions used in this example require a subset of these fields.

enb.NDLRB = 9; enb.CyclicPrefix ='Normal';enb.phichduration ='Normal';enb.CFI = 3; enb.Ng ='第六';enb.CellRefP = 1; enb.NCellID = 10; enb.NSubframe = 0; enb.DuplexMode ='FDD';antennaPort = 0;

资源网格和传输波形

生成一个副帧资源网​​格。要创建资源网格,请致电ltedlresourcegridfunction. This function creates an empty resource grid for one subframe.

子帧= ltedlresourcegrid(enb);

Generate cell-specific reference symbols (CellRS) and map them onto the resource elements (REs) of a resource grid using linear indices.

cellRSsymbols = lteCellRS(enb,antennaPort); cellRSindices = lteCellRSIndices(enb,antennaPort,{'1based'}); subframe(cellRSindices) = cellRSsymbols;

执行子帧中复杂符号的OFDM调制,subframe, using cell-wide settings structureenb.

[txwaveform,info] = lteofdmmodulate(ENB,副帧);

The first output argument,txWaveform, contains the transmitted OFDM modulated symbols. The second output argument,info, is a structure that contains details about the modulation process. The fieldinfo.SamplingRateprovides the sampling rate, R s a m p l i n g , of the time domain waveform:

R s a m p l i n g = 3 0 . 7 2 M H z 2 0 4 8 × N F F T ,

where N F F T 是OFDM逆傅立叶变换(IFT)的大小。

Propagation Channel

构建LTE多径褪色通道。首先,通过创建结构,设置通道参数channel.

channel.Seed = 1; channel.NRxAnts = 1; channel.DelayProfile ='EVA';channel.dopplerfreq = 5;channel.mimocrolation ='Low';channel.samplingrate = info.samplingrate;channel.intimeime = 0;

The sampling rate in the channel model,channel.SamplingRate, must be set to theinfofield of theSamplingRatereturned by thelteOFDMModulatefunction.

Pass data through the LTE fading channel by calling thelteFadingChannelfunction. This function generates an LTE multipath fading channel, as specified in TS 36.101 (See reference [1]). The first input argument,txWaveform, is an array of LTE transmitted samples. Each row contains the waveform samples for each of the transmit antennas. These waveforms are filtered with the delay profiles as specified in the parameter structure,channel.

rxWaveform = lteFadingChannel(channel,txWaveform);

Received Waveform

The output argument,rxWaveform, is the channel output signal matrix. Each row corresponds to the waveform at each of the receive antennas. Since you have defined one receive antenna, the number of rows in therxWaveformmatrix is one.

size(rxWaveform)
ans =1×21920 1

Plot Signal Before and After Fading Channel

显示一个频谱分析仪更加积极re-channel and after-channel waveforms. Use SpectralAverages = 10 to reduce noise in the plotted signals

title ='Waveform Before and After Fading Channel';saScope = dsp.SpectrumAnalyzer('SampleRate',info.SamplingRate,'ShowLegend',true,...'SpectralAverages',10,'标题',title,“频道名称”,{'Before','After'}); saScope([txWaveform,rxWaveform]);

图光谱分析仪包含一个轴对象和类型UiflowContainer的其他对象,Uimenu,Uitoolbar。在褪色通道之前和之后具有标题波形的轴对象包含2个类型线的对象。这些对象在之前,之后表示。

参考

  1. 3GPP TS 36.101 "User Equipment (UE) radio transmission and reception".

See Also

||

Related Examples

More About