How to change nrDLCarrierConfig to FR2?

1 visualización (últimos 30 días)
Al
Al el 6 de Nov. de 2023
Respondida: Umeshraja el 4 de Oct. de 2024
Just trying to play around with the code here, I am trying to added in parameters to get FR2 instead of FR1 but it isnt working. I know I need to change SCS but I seem to be doing it wrong:
scs1 = nrSCSCarrierConfig;
scs2 = nrSCSCarrierConfig('SubcarrierSpacing',60,'NSizeGrid',275);
waveconfig = nrDLCarrierConfig('FrequencyRange','FR2','SCSCarriers', {scs1,scs2},'ChannelBandwidth',60);
%waveconfig.PDSCH{1}.PRBSet = 0:10;
%waveconfig.ChannelBandwidth = 60;
[waveform,waveformInfo] = nrWaveformGenerator(waveconfig);
% Plot spectrogram of waveform for first antenna port
samplerate = waveformInfo.ResourceGrids(1).Info.SampleRate;
nfft = waveformInfo.ResourceGrids(1).Info.Nfft;
figure;
spectrogram(waveform(:,1),ones(nfft,1),0,nfft,'centered',samplerate,'yaxis','MinThreshold',-130);
title('Spectrogram of 5G Downlink Baseband Waveform');
Is there somewhere with an example? Or can someone please help guide me?

Respuestas (1)

Umeshraja
Umeshraja el 4 de Oct. de 2024
Hi @Al,
To create an 'nrDLCarrierConfig' object for Frequency Range 'FR2', specific constraints apply to the configuration parameters. According to the MATLAB R2023b documentation, the channel bandwidth for 'FR2' must be one of the following: 50, 100, 200, 400, 800, 1600, or 2000 MHz.
Additionally, the maximum transmission bandwidth configuration (TS 38.104 Tables 5.3.2-2 and 5.3.2-3) for 'FR2' varies based on the UE channel bandwidth and subcarrier spacing, as shown in the table below:
Here is how you can generate an NR downlink carrier waveform in FR2:
% Downlink configuration
cfgDL = nrDLCarrierConfig('FrequencyRange', 'FR2', ...
'ChannelBandwidth', 50);
%% SCS specific carriers
% Carrier 1
scscarrier1 = nrSCSCarrierConfig('SubcarrierSpacing', 60, 'NSizeGrid', 66, 'NStartGrid', 3);
% Carrier 2
scscarrier2 = nrSCSCarrierConfig('SubcarrierSpacing', 120, 'NSizeGrid', 32, 'NStartGrid', 2);
cfgDL.SCSCarriers = {scscarrier1, scscarrier2};
%% Bandwidth Parts
bwp = nrWavegenBWPConfig;
bwp.SubcarrierSpacing = 60;
bwp.NSizeBWP = 66;
bwp.NStartBWP = 3;
cfgDL.BandwidthParts = {bwp};
%% Synchronization Signals Burst
ssburst = nrWavegenSSBurstConfig;
ssburst.BlockPattern = 'Case D';
%'Case D' — For FR2 and 120 kHz SCS.
%'Case E' — For FR2 and 240 kHz SCS.
%'Case F' — For FR2 and 480 kHz SCS.
%'Case G' — For FR2 and 960 kHz SCS.
ssburst.TransmittedBlocks = ones([1 64]); % 4/8-bit binary vector for FR1 and 64-bit binary vector for FR2
ssburst.SubcarrierSpacingCommon = 60; % 15/30 for FR1 and 60/120 for FR2
cfgDL.SSBurst = ssburst;
%% Generation
[waveform,info] = nrWaveformGenerator(cfgDL);
Fs = info.ResourceGrids(1).Info.SampleRate; % Specify the sample rate of the waveform in Hz
%% Visualize
% Spectrum Analyzer
spectrum = spectrumAnalyzer('SampleRate', Fs);
spectrum(waveform);
release(spectrum);
Alternatively, you can use the 5G Waveform Generator App of MATLAB’s 5G Toolbox to easily generate standard-compliant NR uplink and downlink carrier waveforms. Please refer to the following documentation to get started
For more information, please refer to the MATLAB R2023b documentation

Categorías

Más información sobre 5G Toolbox en Help Center y File Exchange.

Productos


Versión

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by