MIB and BCH Parsing Example in 5G user guide not working

1 回表示 (過去 30 日間)
Serwan
Serwan 2022 年 8 月 11 日
コメント済み: OscarVenegas Cooper 2023 年 10 月 11 日
Hello Everyone
I try the example of MIB and BCH Parsing which is in 5G user guide and in the mathwork website
% Parse the last 23 decoded BCH transport block bits into a MIB message.
% The BCH transport block 'trblk' is the RRC message BCCH-BCH-Message,
% consisting of a leading 0 bit and 23 bits corresponding to the MIB. The
% leading bit signals the message type transmitted (MIB or empty sequence).
mib = fromBits(MIB,trblk(2:end)); % Do not parse leading bit
% Create set of subcarrier spacings signaled by the 7th bit of the decoded
% MIB, the set is different for FR1 (L_max=4 or 8) and FR2 (L_max=64)
if (refBurst.L_max==64)
commonSCSs = [60 120];
else
commonSCSs = [15 30];
end
initialSystemInfo = struct();
initialSystemInfo.NFrame = mib.systemFrameNumber*2^4 + bit2int(sfn4lsb,4);
initialSystemInfo.SubcarrierSpacingCommon = commonSCSs(mib.subCarrierSpacingCommon + 1);
initialSystemInfo.k_SSB = k_SSB + mib.ssb_SubcarrierOffset;
initialSystemInfo.DMRSTypeAPosition = 2 + mib.dmrs_TypeA_Position;
initialSystemInfo.PDCCHConfigSIB1 = info(mib.pdcch_ConfigSIB1);
initialSystemInfo.CellBarred = mib.cellBarred;
initialSystemInfo.IntraFreqReselection = mib.intraFreqReselection;
% Display the MIB structure
disp(' BCH/MIB Content:')
disp(initialSystemInfo);
% Check if a CORESET for Type0-PDCCH common search space (CSS) is present,
% according to TS 38.213 Section 4.1
if ~isCORESET0Present(refBurst.BlockPattern,initialSystemInfo.k_SSB)
fprintf('CORESET 0 is not present (k_SSB > k_SSB_max).\n');
return
end
but it is not work, insteade I get the following error messege
Unrecognized function or variable 'MIB'.
what is the wrong with the code, and what can I do to overcome the error and get results
Thank you in advance
  1 件のコメント
OscarVenegas Cooper
OscarVenegas Cooper 2023 年 10 月 11 日
Hello,
I've got the same problem, I have been searching for several hours and have not found anything. The function fromBits does not even exist in the Matlab documentary.
By chance, did you find the fix? Could you share it?

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeSignal Generation, Manipulation, and Analysis についてさらに検索

タグ

製品


リリース

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by