www.gusucode.com > wlan 源码程序 matlab案例代码 > wlan/RecoverVHTSIGAUsingZeroForcingEqualizerExample.m
%% Recover VHT-SIG-A Using Zero-Forcing Equalizer % Recover the VHT-SIG-A in an AWGN channel. Configure the VHT signal to % have a 160 MHz channel bandwidth, one space-time stream, and one receive % antenna. %% % Create a |wlanVHTConfig| object having a channel bandwidth of 160 MHz. % Using the object to create a VHT-SIG-A waveform. cfg = wlanVHTConfig('ChannelBandwidth','CBW160'); %% % Generate L-LTF and VHT-SIG-A field signals. txLLTF = wlanLLTF(cfg); [txSig,txBits] = wlanVHTSIGA(cfg); chanBW = cfg.ChannelBandwidth; noiseVar = 0.1; %% % Pass the transmitted VHT-SIG-A through an AWGN channel. awgnChan = comm.AWGNChannel('NoiseMethod','Variance','Variance',noiseVar); rxLLTF = awgnChan(txLLTF); rxSig = awgnChan(txSig); %% % Using |wlanRecoveryConfig|, set the equalization method to zero-forcing, % |'ZF'|. cfgRec = wlanRecoveryConfig('EqualizationMethod','ZF'); %% % Perform channel estimation based on the L-LTF. demodLLTF = wlanLLTFDemodulate(rxLLTF,chanBW,1); chanEst = wlanLLTFChannelEstimate(demodLLTF,chanBW); %% % Recover the VHT-SIG-A. Verify that there are no bit errors in the received % information. [rxBits,crcFail] = wlanVHTSIGARecover(rxSig,chanEst,noiseVar,'CBW160',cfgRec); crcFail %% % The CRC failure check returns a |0|, indicating the CRC passed. Comparing % the transmitted bits to the received bits reconfirms the reported CRC % result because the output matches the input. biterr(txBits,rxBits)