HE/channelSounding.m

29 lines
1000 B
Mathematica
Raw Normal View History

2024-03-30 16:35:40 +08:00
function txNDP = channelSounding(cfg)
% NDP
guardInterval = 0.8;% Guard interval in Microseconds
cfgNDP = wlanHESUConfig('APEPLength',0,'GuardInterval',guardInterval); % No data in an NDP
cfgNDP.ChannelBandwidth = cfg.ChannelBandwidth;
cfgNDP.NumTransmitAntennas = cfg.numTx;
cfgNDP.NumSpaceTimeStreams = cfg.numTx;
txNDP = wlanWaveformGenerator([],cfgNDP);
% PN
soundingSeqMod_1 = zadoffChuSeq(29,255);
soundingSeqMod_2 = zadoffChuSeq(47,255);
% Concatenate multiple sequences to sound the channel periodically.
numSeq = 20; % Number of transmitted sequences in a WSS period
if cfg.numTx == 1
soundingSeqMod = [soundingSeqMod_1];
txSignal = repmat(soundingSeqMod,numSeq,1);
else
soundingSeqMod = [soundingSeqMod_1, soundingSeqMod_2];
txSignal = repmat(soundingSeqMod,numSeq,1);
end
% with 50 sample padding.
% txNDP = [txNDP; zeros(50,size(txNDP,2))];
txNDP = [txNDP; txSignal; zeros(50,size(txNDP,2))];
end