cfgNonHT = wlanNonHTConfig; txWaveform = wlanWaveformGenerator([1;0;0;1],cfgNonHT,... 'WindowTransitionTime',0); len = 30000; n = rand(len,1)+rand(len,1)*1i; rxWaveform = [n;txWaveform]; % 0.001*rand(100,1) offset = 5; threshold = 1-10*eps; startOffset = wlanPacketDetect(rxWaveform,... cfgNonHT.ChannelBandwidth,offset,threshold) ; totalOffset = offset + startOffset