main content

5g nr csi-凯发k8网页登录

this example shows the measurement procedure of csi-rsrp, csi-rssi, and csi-rsrq for the test environment, as described in ts 38.133 annex a.4.6.4.3, by using the channel state information reference signal from 5g toolbox™.

introduction

in nr 5g, the three types of csi-rs based reference signal measurements, as defined in ts 38.215 sections 5.1.2 and 5.1.4, includes:

  • csi-rsrp (csi reference signal received power): csi-rsrp is defined as the linear average over the power contributions of the resource elements of the antenna ports, which carry csi-rs configured for rsrp measurements. this measurement is performed across n number of resource blocks (measurement bandwidth). for this measurement, csi-rs transmitted on antenna port(s) 3000 or 3000 and 3001 is used.

  • csi-rssi (csi received signal strength indicator): csi-rssi is defined as the linear average of the total received power observed only in the ofdm symbols, in which csi-rs is present. this measurement is also performed across n number of resource blocks (measurement bandwidth). csi-rssi includes the power from sources, such as co-channel serving and non-serving cells, adjacent channel interference, and thermal noise. for this measurement, csi-rs transmitted on antenna port 3000 is used.

  • csi-rsrq (csi reference signal received quality): csi-rsrq is defined as, n*csi_rsrpcsi_rssi.

the purposes of these measurements include:

  • cell selection and reselection

  • mobility and handover management

  • beam management (beam adjustment and beam recovery)

this example configures only the csi-rs from the test environment.

initialize configuration objects

carrier configuration

create carrier configuration object occupying 10 mhz bandwidth with 15 khz subcarrier spacing as per configuration 1 in ts 38.133 table a.4.6.4.3.1-1.

carrier = nrcarrierconfig;
carrier.nslot = 1;
carrier.nsizegrid = 52;

csi-rs configuration

as per the test environment ts 38.133 table a.4.6.4.3.2-1, user equipment (ue) is configured with one csi-rs resource set (csi-rs 1.2 fdd), consisting of 2 csi-rs resources.

csirs = nrcsirsconfig;
% csi-rs resource             #0       #1
csirs.csirstype           = {'nzp',   'nzp'};
csirs.csirsperiod         = {[10 1],  [10 1]};
csirs.rownumber           = [1        1]; % single port (3000) csi-rs resources
csirs.density             = {'three', 'three'};
csirs.symbollocations     = {6,       10};
csirs.subcarrierlocations = {0,       0};
csirs.numrb               = [52,      52]; % measurement bandwidth in terms of number of resource blocks

generate csi-rs symbols and indices

generate csi-rs symbols and indices for the specified carrier and csi-rs configuration parameters with the output resource format as 'cell'. this output resource format provides a way to identify the outputs uniquely for each csi-rs resource in a resource set. you can also apply different power levels to each csi-rs resource.

ind = nrcsirsindices(carrier,csirs,'outputresourceformat','cell');
sym = nrcsirs(carrier,csirs,'outputresourceformat','cell');

signal and noise power setup

set up the signal and noise powers as described in ts 38.133 table a.4.6.4.3.2-2. as per note 2 in ts 38.133 table a.4.6.4.3.2-2, interference from other cells and noise from other sources is modeled as additive white gaussian noise (awgn) of appropriate power noc.

sinrdb0 = 0; % for csi-rs #0
sinrdb1 = 3; % for csi-rs #1
nocdbm = -94.65;
nocdb = nocdbm - 30;
noc = 10^(nocdb/10);

calculate the power scaling of csi-rs resources by using sinr values.

% power scaling of csi-rs resource #0
sinr0 = 10^(sinrdb0/10);     % linear es/noc
es0 = sinr0*noc;
% power scaling of csi-rs resource #1
sinr1 = 10^(sinrdb1/10);     % linear es/noc
es1 = sinr1*noc;

initialize the carrier resource grid and map csi-rs symbols to the grid

initialize the carrier resource grid for one slot.

ports = max(csirs.numcsirsports); % number of antenna ports
txgrid = nrresourcegrid(carrier,ports);

apply the power scaling values to the csi-rs resources and map them onto the grid.

txgrid(ind{1}) = sqrt(es0)*sym{1};
txgrid(ind{2}) = sqrt(es1)*sym{2};
% plot the carrier grid for two csi-rs resources
plotgrid(size(txgrid),ind)

figure contains an axes object. the axes object with title carrier grid containing csi-rs, xlabel ofdm symbols, ylabel subcarriers contains 3 objects of type image, line. these objects represent csi-rs resource #0, csi-rs resource #1.

perform ofdm modulation

perform ofdm modulation to generate the time-domain waveform.

[txwaveform,ofdminfo] = nrofdmmodulate(carrier,txgrid);

add awgn to the transmitted waveform and perform ofdm demodulation

consider the propagation condition as awgn, as specified in ts 38.133 table a.4.6.4.3.2-1.

% generate the noise
rng('default');  % set rng state for repeatability
n0 = sqrt(noc/(2*double(ofdminfo.nfft)));
noise = n0*complex(randn(size(txwaveform)),randn(size(txwaveform)));
% add awgn to the transmitted waveform
rxwaveform = txwaveform   noise;

perform ofdm demodulation on the received time-domain waveform to get the received resource element array.

rxgrid = nrofdmdemodulate(carrier,rxwaveform);

perform csi-rsrp, csi-rssi, and csi-rsrq measurements

finally, perform the csi-rsrp, csi-rssi, and csi-rsrq measurements on the csi-rs resources present in the received grid, by using the nrcsirsmeasurements function.

meas = nrcsirsmeasurements(carrier,csirs,rxgrid)
meas = struct with fields:
    rsrpperantenna: [-94.1599 -91.3258]
    rssiperantenna: [-65.6220 -64.9823]
    rsrqperantenna: [-11.3779 -9.1834]
% plot rsrpdbm, rssidbm and rsrqdb measurements for all csi-rs resources
plotcsirsmeasurements(meas)

figure contains an axes object. the axes object with title csi-rsrp measurements (in dbm), ylabel csi-rsrp in dbm contains 3 objects of type bar, text.

figure contains an axes object. the axes object with title csi-rssi measurements (in dbm), ylabel csi-rssi in dbm contains 3 objects of type bar, text.

figure contains an axes object. the axes object with title csi-rsrq measurements (in db), ylabel csi-rsrq in db contains 3 objects of type bar, text.

you can compare the measured csi-rsrp values of two csi-rs resources represented by the output field rsrpdbm to the standard specified values given in ts 38.133 table a.4.6.4.3.2-2.

local functions

function plotgrid(gridsize,csirsind)
%    plotgrid(gridsize,csirsind) plots the carrier grid of size gridsize
%    by populating the grid with csi-rs symbols of multiple resources
%    indicated by a cell array of csi-rs indices csirsind.
    figure()
    cmap = colormap(gcf);
    % considering the following values for two csi-rs resources and they need
    % to be updated based on the number of csi-rs resources
    names = {'csi-rs resource #0','csi-rs resource #1'};
    chpval = {20,2};
    chpscale = 0.25*length(cmap); % scaling factor
    tempgrid = zeros(gridsize);
    tempgrid(csirsind{1}) = chpval{1};
    tempgrid(csirsind{2}) = chpval{2};
    image(chpscale*tempgrid(:,:,1)); % multiplied with scaling factor for better visualization
    axis xy;
    clevels = chpscale*[chpval{:}];
    n = length(clevels);
    l = line(ones(n),ones(n),'linewidth',8); % generate lines
    % index the color map and associate the selected colors with the lines
    set(l,{'color'},mat2cell(cmap( min(1 clevels,length(cmap) ),:),ones(1,n),3)); % set the colors according to cmap
    % create legend
    legend(names{:});
    title('carrier grid containing csi-rs')
    xlabel('ofdm symbols');
    ylabel('subcarriers');
end
function plotcsirsmeasurements(meas)
%   plotcsirsmeasurements(meas) plots csi-rs based rsrp/rssi/rsrq measurements
    meas = structfun(@(s)max(s,[],1),meas,'uniformoutput',false);
    numres = numel(meas.rsrpperantenna);
    xticklabels = {};
    for idx = 1:numres
        xticklabels = [xticklabels {['csi-rs resource #' num2str(idx-1)]}]; %#ok
    end
    meastype = {'csi-rsrp','csi-rssi','csi-rsrq'};
    measval = {meas.rsrpperantenna, meas.rssiperantenna, meas.rsrqperantenna};
    measunits = {'dbm','dbm','db'};
    for measidx = 1:3
        figure()
        values = measval{measidx};
        baseval = 0;
        if ~any(values > 0)
            baseval = floor(min(values));
        end
        b = bar(values,'facecolor','#edb120','basevalue',baseval);
        xticklabels(xticklabels);
        xtips = b.xendpoints;
        ytips = b.yendpoints;
        for i = 1:numel(xtips)
            text(xtips(i), ytips(i), sprintf(['%0.2f ' measunits{measidx}],values(i)), ...
                'horizontalalignment', 'center', 'verticalalignment', 'top');
        end
        ylabel([meastype{measidx} ' in ' measunits{measidx}]);
        title([meastype{measidx} ' measurements (in ' measunits{measidx} ')'])
    end
end

references

[1] 3gpp ts 38.133. “nr; requirements for support of radio resource management.” 3rd generation partnership project; technical specification group radio access network.

[2] 3gpp ts 38.215. “nr; physical layer measurements.” 3rd generation partnership project; technical specification group radio access network.

see also

functions

  • |

objects

  • |

related topics

网站地图