Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

wlanVHTDataRecover

Recover VHT data

Syntax

recBits = wlanVHTDataRecover(rxSig,chEst,noiseVarEst,cfg)
recBits = wlanVHTDataRecover(rxSig,chEst,noiseVarEst,cfg,userNumber)
recBits = wlanVHTDataRecover(rxSig,chEst,noiseVarEst,cfg,userNumber,numSTS)
recBits = wlanVHTDataRecover(___,cfgRec)
[recBits,crcBits] = wlanVHTDataRecover(___)
[recBits,crcBits,eqSym] = wlanVHTDataRecover(___)
[recBits,crcBits,eqSym,cpe] = wlanVHTDataRecover(___)

Description

example

recBits = wlanVHTDataRecover(rxSig,chEst,noiseVarEst,cfg) returns the recovered payload bits from the VHT data field[1] for a single-user transmission. Inputs include the received VHT data field signal, the channel estimate, the noise variance estimate, and the format configuration object, cfg.

example

recBits = wlanVHTDataRecover(rxSig,chEst,noiseVarEst,cfg,userNumber) returns the recovered payload bits, in a multiuser transmission, for the user specified by userNumber.

recBits = wlanVHTDataRecover(rxSig,chEst,noiseVarEst,cfg,userNumber,numSTS) also specifies the number of space-time streams, numSTS, for a multiuser transmission.

example

recBits = wlanVHTDataRecover(___,cfgRec) returns the recovered bits using the algorithm parameters specified in cfgRec.

[recBits,crcBits] = wlanVHTDataRecover(___) also returns the VHT-SIG-B checksum bits, crcBits, using the arguments from the previous syntaxes.

[recBits,crcBits,eqSym] = wlanVHTDataRecover(___) also returns the equalized symbols, eqSym.

[recBits,crcBits,eqSym,cpe] = wlanVHTDataRecover(___) also returns the common phase error, cpe.

Examples

collapse all

Recover bits in the VHT-Data field using channel estimation on a VHT-LTF field over a 2 x 2 quasi-static fading channel.

Create a VHT configuration object with 160 MHz channel bandwidth and two transmission paths.

cbw = 'CBW160';
vht = wlanVHTConfig('ChannelBandwidth',cbw,'NumTransmitAntennas',2,'NumSpaceTimeStreams',2,'APEPLength',512);

Generate VHT-LTF and VHT-Data field signals.

txDataBits = randi([0 1],8*vht.PSDULength,1);
txVHTLTF  = wlanVHTLTF(vht);
txVHTData = wlanVHTData(txDataBits,vht);

Pass the transmitted waveform through a 2 x 2 quasi-static fading channel with AWGN.

snr = 10;
H = 1/sqrt(2)*complex(randn(2,2),randn(2,2));
rxVHTLTF  = awgn(txVHTLTF*H,snr);
rxVHTData = awgn(txVHTData*H,snr);

Calculate the received signal power and use it to estimate the noise variance.

powerDB = 10*log10(var(rxVHTData));
noiseVarEst = mean(10.^(0.1*(powerDB-snr)));

Perform channel estimation based on the VHT-LTF field.

demodVHTLTF = wlanVHTLTFDemodulate(rxVHTLTF,vht,1);
chanEst = wlanVHTLTFChannelEstimate(demodVHTLTF,vht);

Recover payload bits in the VHT-Data field and compare against the original payload bits.

rxDataBits = wlanVHTDataRecover(rxVHTData,chanEst,noiseVarEst,vht);
numErr = biterr(txDataBits,rxDataBits)
numErr =

     0

Recover a VHT-Data field signal through a SISO AWGN channel using ZF equalization.

Configure VHT format object, generate random payload bits, and generate the VHT-Data field.

cfgVHT = wlanVHTConfig('APEPLength',512);
txBits = randi([0 1], 8*cfgVHT.PSDULength,1);
txVHTData = wlanVHTData(txBits,cfgVHT);

Pass the transmitted VHT data through an AWGN channel.

awgnChan = comm.AWGNChannel('NoiseMethod','Variance','Variance',0.1);
rxVHTData = awgnChan(txVHTData);

Configure the recovery object and recover the payload bits using a perfect channel estimate of all ones. Compare the recovered bits against the transmitted bits.

cfgRec = wlanRecoveryConfig('EqualizationMethod','ZF');
recBits = wlanVHTDataRecover(rxVHTData,ones(242,1),0.1,cfgVHT,cfgRec);
numErrs = biterr(txBits,recBits)
numErrs =

     0

Recover VHT-Data field bits for a multiuser transmission using channel estimation on a VHT-LTF field over a quasi-static fading channel.

Create a VHT configuration object having a 160 MHz channel bandwidth, two users, and four transmit antennas. Assign one space-time stream to the first user and three space-time streams to the second user.

cbw = 'CBW160';
numSTS = [1 3];
vht = wlanVHTConfig('ChannelBandwidth',cbw,'NumUsers',2, ...
    'NumTransmitAntennas',4,'NumSpaceTimeStreams',numSTS);

Because there are two users, the PSDU length is a 1-by-2 row vector.

psduLen = vht.PSDULength
psduLen =

        1050        3156

Generate multiuser input data. This data must be in the form of a 1-by- N cell array, where N is the number of users.

txDataBits{1} = randi([0 1],8*vht.PSDULength(1),1);
txDataBits{2} = randi([0 1],8*vht.PSDULength(2),1);

Generate VHT-LTF and VHT-Data field signals.

txVHTLTF  = wlanVHTLTF(vht);
txVHTData = wlanVHTData(txDataBits,vht);

Pass the data field for the first user through a 4x1 channel because it consists of a single space-time stream. Pass the second user's data through a 4x3 channel because it consists of three space-time streams. Apply white Gaussian noise to each user signal.

snr = 15;
H1 = 1/sqrt(2)*complex(randn(4,1),randn(4,1));
H2 = 1/sqrt(2)*complex(randn(4,3),randn(4,3));

rxVHTData1 = awgn(txVHTData*H1,snr,'measured');
rxVHTData2 = awgn(txVHTData*H2,snr,'measured');

Repeat the process for the VHT-LTF fields.

rxVHTLTF1  = awgn(txVHTLTF*H1,snr,'measured');
rxVHTLTF2  = awgn(txVHTLTF*H2,snr,'measured');

Calculate the received signal power for both users and use it to estimate the noise variance.

powerDB1 = 10*log10(var(rxVHTData1));
noiseVarEst1 = mean(10.^(0.1*(powerDB1-snr)));

powerDB2 = 10*log10(var(rxVHTData2));
noiseVarEst2 = mean(10.^(0.1*(powerDB2-snr)));

Estimate the channel characteristics using the VHT-LTF fields.

demodVHTLTF1 = wlanVHTLTFDemodulate(rxVHTLTF1,cbw,numSTS);
chanEst1 = wlanVHTLTFChannelEstimate(demodVHTLTF1,cbw,numSTS);

demodVHTLTF2 = wlanVHTLTFDemodulate(rxVHTLTF2,cbw,numSTS);
chanEst2 = wlanVHTLTFChannelEstimate(demodVHTLTF2,cbw,numSTS);

Recover VHT-Data field bits for the first user and compare against the original payload bits.

rxDataBits1 = wlanVHTDataRecover(rxVHTData1,chanEst1,noiseVarEst1,vht,1);
[~,ber1] = biterr(txDataBits{1},rxDataBits1)
ber1 =

    0.4983

Determine the number of bit errors for the second user.

rxDataBits2 = wlanVHTDataRecover(rxVHTData2,chanEst2,noiseVarEst2,vht,2);
[~,ber2] = biterr(txDataBits{2},rxDataBits2)
ber2 =

    0.0972

The bit error rates are quite high because there is no precoding to mitigate the interference between streams. This is especially evident for the user 1 receiver because it receives energy from the three streams intended for user 2. The example is intended to show the workflow and proper syntaxes for the LTF demodulate, channel estimation, and data recovery functions.

Input Arguments

collapse all

Received VHT-Data field signal in the time domain, specified as an NS-by-NR matrix. NR is the number of receive antennas. NS must be greater than or equal to the number of time-domain samples in the VHT-Data field input.

Note

wlanVHTDataRecover processes one PPDU data field per entry. If NS is greater than the field length, extra samples at the end of rxSig are not processed. To process a concatenated stream of PPDU data fields, multiple calls to wlanVHTDataRecover are required. If rxSig is shorter than the length of the VHT-Data field, an error occurs.

Data Types: double
Complex Number Support: Yes

Channel estimation for data and pilot subcarriers, specified as a matrix or array of size NST-by-NSTS-by-NR. NST is the number of occupied subcarriers. NSTS is the number of space-time streams. For multiuser transmissions, NSTS is the total number of space-time streams for all users. NR is the number of receive antennas. NST and NSTS must match the cfg configuration object settings for channel bandwidth and number of space-time streams.

NST increases with channel bandwidth.

ChannelBandwidthNumber of Occupied Subcarriers (NST)Number of Data Subcarriers (NSD)Number of Pilot Subcarriers (NSP)
'CBW20'56524
'CBW40'1141086
'CBW80'2422348
'CBW160'48446816

Data Types: double
Complex Number Support: Yes

Noise variance estimate, specified as a nonnegative scalar.

Data Types: double

VHT PPDU configuration, specified as a wlanVHTConfig object. The wlanVHTDataRecover function uses the following wlanVHTConfig object properties:

Channel bandwidth, specified as 'CBW20', 'CBW40', 'CBW80', or 'CBW160'. If the transmission has multiple users, the same channel bandwidth is applied to all users. The default value of 'CBW80' sets the channel bandwidth to 80 MHz.

Data Types: char | string

Number of users, specified as 1, 2, 3, or 4. (NUsers)

Data Types: double

Number of space-time streams in the transmission, specified as a scalar or vector.

  • For a single user, the number of space-time streams is a scalar integer from 1 to 8.

  • For multiple users, the number of space-time streams is a 1-by-NUsers vector of integers from 1 to 4, where the vector length, NUsers, is an integer from 1 to 4.

Example: [1 3 2] is the number of space-time streams for each user.

Note

The sum of the space-time stream vector elements must not exceed eight.

Data Types: double

Enable space-time block coding (STBC) of the PPDU data field, specified as a logical. STBC transmits multiple copies of the data stream across assigned antennas.

  • When set to false, no STBC is applied to the data field, and the number of space-time streams is equal to the number of spatial streams.

  • When set to true, STBC is applied to the data field, and the number of space-time streams is double the number of spatial streams.

See IEEE® 802.11ac™-2013, Section 22.3.10.9.4 for further description.

Note

STBC is relevant for single-user transmissions only.

Data Types: logical

Cyclic prefix length for the data field within a packet, specified as 'Long' or 'Short'.

  • The long guard interval length is 800 ns.

  • The short guard interval length is 400 ns.

Data Types: char | string

Modulation and coding scheme used in transmitting the current packet, specified as a scalar or vector.

  • For a single user, the MCS value is a scalar integer from 0 to 9.

  • For multiple users, MCS is a 1-by-NUsers vector of integers or a scalar with values from 0 to 9, where the vector length, NUsers, is an integer from 1 to 4.

MCSModulationCoding Rate
0BPSK1/2
1QPSK1/2
2QPSK3/4
316QAM1/2
416QAM3/4
564QAM2/3
664QAM3/4
764QAM5/6
8256QAM3/4
9256QAM5/6

Data Types: double

Type of forward error correction coding for the data field, specified as 'BCC' (default) or 'LDPC'. 'BCC' indicates binary convolutional coding and 'LDPC' indicates low density parity check coding. Providing a character vector or a single cell character vector defines the channel coding type for a single user or all users in a multiuser transmission. By providing a cell array different channel coding types can be specified per user for a multiuser transmission.

Data Types: char | cell | string

Number of bytes in the A-MPDU pre-EOF padding, specified as a scalar integer or vector of integers.

  • For a single user, APEPLength is a scalar integer from 0 to 1,048,575.

  • For multi-user, APEPLength is a 1-by-NUsers vector of integers or a scalar with values from 0 to 1,048,575, where the vector length, NUsers, is an integer from 1 to 4.

  • APEPLength = 0 for a null data packet (NDP).

APEPLength is used internally to determine the number of OFDM symbols in the data field. For more information, see IEEE Std 802.11ac-2013, Table 22-1.

Data Types: double

Algorithm parameters containing properties used during data recovery, specified as a wlanRecoveryConfig object. The configurable properties include OFDM symbol sampling offset, equalization method, and the type of pilot phase tracking. If you do not specify a cfgRec object, the default object property values as described in wlanRecoveryConfig Properties are used in the data recovery.

Note

Use cfgRec.EqualizationMethod = 'ZF' when either of the following conditions are met:

  • cfg.NumSpaceTimeStreams=1

  • cfg.NumSpaceTimeStreams=2 and cfg.STBC=true

OFDM symbol sampling offset represented as a fraction of the cyclic prefix (CP) length, specified as a scalar value from 0 to 1. This value indicates the start location for OFDM demodulation, relative to the beginning of the cyclic prefix. OFDMSymbolOffset = 0 represents the start of the cyclic prefix and OFDMSymbolOffset = 1 represents the end of the cyclic prefix.

Data Types: double

Equalization method, specified as 'MMSE' or 'ZF'.

  • 'MMSE' indicates that the receiver uses a minimum mean square error equalizer.

  • 'ZF' indicates that the receiver uses a zero-forcing equalizer.

Example: 'ZF'

Data Types: char | string

Pilot phase tracking, specified as 'PreEQ' or 'None'.

  • 'PreEQ' — Enables pilot phase tracking, which is performed before any equalization operation.

  • 'None' — Pilot phase tracking does not occur.

Data Types: char | string

Maximum number of decoding iterations in LDPC, specified as a positive scalar integer. This parameter is applicable when channel coding is set to LDPC. For information on channel coding options, see wlanVHTConfig or wlanHTConfig for 802.11™ format of interest.

Data Types: double

Enable early termination of LDPC decoding, specified as a logical. This parameter is applicable when channel coding is set to LDPC.

  • When set to false, LDPC decoding completes the number of iterations specified by MaximumLDPCIterationCount, regardless of parity check status.

  • When set to true, LDPC decoding terminates when all parity-checks are satisfied.

For information on channel coding options, see wlanVHTConfig or wlanHTConfig for 802.11 format of interest.

Number of the user in a multiuser transmission, specified as an integer having a value from 1 to NUsers. NUsers is the total number of users.

Number of space-time streams in a multiuser transmission, specified as a vector. The number of space-time streams is a 1-by-NUsers vector of integers from 1 to 4, where NUsers is an integer from 1 to 4.

Example: [1 3 2] is the number of space-time streams for each user.

Note

The sum of the space-time stream vector elements must not exceed eight.

Data Types: double

Output Arguments

collapse all

Recovered payload bits in the VHT-Data field, returned as a column vector of length 8 × cfgVHT.PSDULength. See wlanVHTConfig Properties for PSDULength details. The output is for a single user as determined by userNumber.

Data Types: int8

Checksum bits for VHT-SIG-B field, returned as a binary column vector of length 8.

Data Types: int8

Equalized symbols, returned as an NSD-by-NSYM-by-NSS matrix or array. NSD is the number of data subcarriers. NSYM is the number of OFDM symbols in the VHT-Data field. NSS is the number of spatial streams assigned to the user. When STBC is false, NSS = NSTS. When STBC is true, NSS = NSTS/2.

Data Types: double
Complex Number Support: Yes

Common phase error in radians, returned as a column vector having length NSYM. NSYM is the number of OFDM symbols in the VHT data field.

Limitations

wlanVHTDataRecover processing limitations, restrictions, and recommendations:

  • If only VHT format PPDUs are processed, then isa(cfgVHT, 'wlanVHTConfig') must be true.

  • For single-user scenarios, cfgVHT.NumUsers must equal 1.

  • When STBC is enabled, the number of space-time streams must be even.

  • cfgRec.EqualizationMethod = 'ZF' is recommended when cfgVHT.STBC = true and cfgVHT.NumSpaceTimeStreams = 2

  • cfgRec.EqualizationMethod = 'ZF' is recommended when cfgVHT.NumSpaceTimeStreams = 1

More About

collapse all

VHT data field

The very high throughput data (VHT data) field is used to transmit one or more frames from the MAC layer. It follows the VHT-SIG-B field in the packet structure for the VHT format PPDUs.

The VHT data field is defined in IEEE Std 802.11ac-2013, Section 22.3.10. It is composed of four subfields.

  • Service field — Contains a seven-bit scrambler initialization state, one bit reserved for future considerations, and eight bits for the VHT-SIG-B CRC field.

  • PSDU — Variable-length field containing the PLCP service data unit. In 802.11, the PSDU can consist of an aggregate of several MAC service data units.

  • PHY Pad — Variable number of bits passed to the transmitter to create a complete OFDM symbol.

  • Tail — Bits used to terminate a convolutional code. Tail bits are not needed when LDPC is used.

References

[1] IEEE Std 802.11ac™-2013 IEEE Standard for Information technology — Telecommunications and information exchange between systems — Local and metropolitan area networks — Specific requirements — Part 11: Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specifications — Amendment 4: Enhancements for Very High Throughput for Operation in Bands below 6 GHz.

Extended Capabilities

Introduced in R2015b


[1] IEEE Std 802.11ac-2013 Adapted and reprinted with permission from IEEE. Copyright IEEE 2013. All rights reserved.

Was this topic helpful?