tx_gen_preamble.m

来自「此代码是LDPC码进行BP算法的重要参考代码」· M 代码 · 共 26 行

M
26
字号
function preamble = tx_gen_preamble(sim_options);

global sim_consts;

%Generate first ten short training symbols
short_tr = sim_consts.ShortTrainingSymbols;

% generate four short training symbols
short_tr_symbols = tx_freqd_to_timed(short_tr);

% Pick one short training symbol
Strs = short_tr_symbols(1:16);

% extend to ten short training symbols
short_trs=[Strs Strs Strs Strs Strs Strs Strs Strs Strs Strs];

% next generate the two long training symbols
long_tr = sim_consts.LongTrainingSymbols;
long_tr_symbols = tx_freqd_to_timed(long_tr);

% extend with the 2*guard interval in front and then two long training symbols
long_trs_signal = [long_tr_symbols(64-2*16+1:64) long_tr_symbols long_tr_symbols];

% concatenate first short training symbols and long training symbols
preamble = [short_trs long_trs_signal];

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?