wlanDMGDataBitRecover

Recover data bits from DMG data field

Description

example

DataBits = wlanDMGDataBitRecover(rxDataSig,noiseVarEst,cfg) recovers the data bits given the data field from a DMG transmission (OFDM, single-carrier, or control PHY), the noise variance estimate, and the DMG configuration object.

example

DataBits = wlanDMGDataBitRecover(rxDataSig,noiseVarEst,csi,cfg) uses the channel state information specified in csi to enhance the demapping of OFDM subcarriers.

DataBits = wlanDMGDataBitRecover(___,Name,Value) specifies additional options in name-value pair arguments, using the inputs from preceding syntaxes. When a name-value pair is not specified, its default value is used.

Examples

collapse all

Recover data information bits from the DMG data field of single-carrier (SC) PHY.

Transmitter

Create the DMG configuration object with a modulation and coding scheme (MCS) for the SC PHY.

cfgDMG = wlanDMGConfig('MCS',10);

Create the input sequence of data bits, specifying it as a column vector with cfgDMG.PSDULength*8 elements. Generate the DMG transmission waveform.

txBits = randi([0 1],cfgDMG.PSDULength*8,1,'int8'); 
tx = wlanWaveformGenerator(txBits,cfgDMG);

AWGN Channel

Set an SNR of 10 dB, calculate the noise power (noise variance), and add AWGN to the transmission waveform by using the awgn function.

SNR = 10;
nVar = 10^(-SNR/10);
rx = awgn(tx,SNR);

Receiver

Extract the data field by using the wlanFieldIndices function to generate the PPDU field indices.

ind = wlanFieldIndices(cfgDMG);
rxData = rx(ind.DMGData(1):ind.DMGData(2));

Reshape the received data waveform into blocks. Set the data block size to 512 and the guard interval length to 64. Remove the last guard interval from the received data waveform. The resulting data waveform is a 512-by-Nblks matrix, where Nblks is the number of DMG data blocks.

blkSize = 512; 
Ngi = 64;
rxData = rxData(1:end-Ngi); 
rxData = reshape(rxData,blkSize,[]);

Remove the guard interval from each block. The resulting signal is a 448-by-Nblks matrix, as expected for a time-domain DMG data field signal for SC PHY.

rxSym = rxData(Ngi+1:end,:);
size(rxSym)
ans = 1×2

   448     9

Recover the PSDU from the DMG data field.

rxBits = wlanDMGDataBitRecover(rxSym,nVar,cfgDMG);

Compare it against the original information bits.

disp(isequal(txBits,rxBits));
   1

Recover data information bits of the DMG data field of the OFDM PHY.

Transmitter

Create the DMG configuration object with a modulation and coding scheme (MCS) for the OFDM PHY.

cfgDMG = wlanDMGConfig('MCS',14);

Create the input sequence of data bits, specifying it as a column vector with cfgDMG.PSDULength*8 elements. Generate the DMG transmission waveform.

txBits = randi([0 1],cfgDMG.PSDULength*8,1,'int8'); 
tx = wlanWaveformGenerator(txBits,cfgDMG);

Channel

Transmit the signal through a channel with no noise (zero noise variance).

rx = tx;
nVar = 0;

Receiver

Extract the data field, using the wlanFieldIndices function to generate the PPDU field indices.

ind = wlanFieldIndices(cfgDMG);
rxData = rx(ind.DMGData(1):ind.DMGData(2));

Set the FFT length to 512 and the cyclic prefix length to 128 for the OFDM demodulation.

Nfft = 512;
Ncp = 128;

Perform the OFDM demodulation. Reshape the received waveform to have the OFDM symbols per column and remove cyclic prefix. Then, scale the sequence by the active tone 352 and extract the frequency domain symbols.

ofdmSym = reshape(rxData,Nfft+Ncp,[]);
dftSym = ofdmSym(Ncp+1:end,:);      
dftSym = dftSym/(Nfft/sqrt(352));   
freqSym = fftshift(fft(dftSym,[],1),1);

Extract data-carrying subcarriers and discard the pilots. Set the highest subcarrier index to 177.

pilotSCIndex = [-150; -130; -110; -90; -70; -50; -30; -10; 10; 30; 50; 70; 90; 110; 130; 150];
noDataSCIndex = [pilotSCIndex; [-1; 0; 1]];
Nsr = 177; 
dataSCIndex = setdiff((-Nsr:Nsr).',sort(noDataSCIndex));
rxSym = freqSym(dataSCIndex+(Nfft/2+1),:);

Recover the PSDU from the DMG data field. Assume a CSI estimation of all ones.

csi = ones(length(dataSCIndex),1);
rxBits = wlanDMGDataBitRecover(rxSym,nVar,csi,cfgDMG);

Compare it against the original information bits.

disp(isequal(txBits,rxBits));
   1

Recover data information bits from the DMG data field of the control PHY.

Transmitter

Create the DMG configuration object with a modulation and coding scheme (MCS) for the control PHY.

cfgDMG = wlanDMGConfig('MCS',0);

Create the input sequence of data bits, specifying it as a column vector with cfgDMG.PSDULength*8 elements. Generate the DMG transmission waveform.

txBits = randi([0 1],cfgDMG.PSDULength*8,1,'int8'); 
tx = wlanWaveformGenerator(txBits,cfgDMG);

Channel

Transmit the signal through a channel with no noise (zero noise variance).

rx = tx;
nVar = 0;

Receiver

Extract the header and the data field by using the wlanFieldIndices function.

ind = wlanFieldIndices(cfgDMG);
rxSym = rx(ind.DMGHeader(1):ind.DMGData(2));

De-rotate the received signal by pi/2 and despread it with a spreading factor of 32. Use the wlanGolaySequence function to generate the Golay sequence.

rxSym = rxSym.*exp(-1i*pi/2*(0:size(rxSym,1)-1).');
SF = 32; 
Ga = wlanGolaySequence(SF);
rxSymDespread = (reshape(rxSym,SF,length(rxSym)/SF)'*Ga)/SF;

Recover the PSDU from the DMG data field.

rxBits = wlanDMGDataBitRecover(rxSymDespread,nVar,cfgDMG);

Compare it against the original information bits.

disp(isequal(txBits,rxBits));
   1

Input Arguments

collapse all

Received DMG data signal, specified as a real or complex matrix. The contents and size of rxDataSig depend on the physical layer (PHY):

  • Single-carrier PHY — rxDataSig is the time-domain DMG data field signal, specified as a 448-by-NBLKS matrix of real or complex values. The value 448 is the number of symbols in a DMG data symbol and NBLKS is the number of DMG data blocks.

  • OFDM PHY — rxDataSig is the demodulated DMG data field OFDM symbols, specified as a 336-by-NSYM matrix of real or complex values. The value 336 is the number of data subcarriers in the DMG data field and NSYM is the number of OFDM symbols.

  • Control PHY — rxDataSig is the time-domain signal containing the header and data fields, specified as an NB-by-1 column vector of real or complex values, where NB is the number of despread symbols.

Data Types: double
Complex Number Support: Yes

Noise variance estimate, specified as a nonnegative scalar.

Data Types: double

DMG PPDU configuration, specified as a wlanDMGConfig object.

Channel state information, specified as a 336-by-1 real column vector. The value 336 specifies the number of data subcarriers in the DMG data field. csi is required only for OFDM PHY.

Data Types: double

Name-Value Pair Arguments

Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside quotes. You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

Example: 'MaximumLDPCIterationCount','12','EarlyTermination','false' specifies a maximum of 12 decoding iterations for the LDPC and disables early termination of LDPC decoding so that it completes the 12 iterations.

Maximum number of decoding iterations in low-density parity check (LDPC), specified as a positive integer. This argument applies when channel coding is set to LDPC for the user of interest.

For information on channel coding options, see the 802.11™ format configuration object of interest.

Data Types: double

Enable early termination of LDPC decoding, specified as a logical value of 1 (true) or 0 (false). This property applies when channel coding is set to LDPC for the user of interest.

  • 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 the 802.11 format configuration object of interest.

Data Types: logical

Output Arguments

collapse all

Recovered information bits from the DMG data field, returned as a column vector of length 8 × cfgDMG.PSDULength. See wlanDMGConfig for PSDULength details.

Data Types: int8

More About

collapse all

DMG Data Field

The DMG format supports three physical layer (PHY) modulation schemes: control, single carrier, and OFDM. The data field is variable in length. It serves the same function for the three PHYs and carries the user data payload.

For SC PHY, each block in the data field is 512-symbols long and with a guard interval (GI) of 64 symbols with the Golay Sequence. For OFDM, each OFDM symbol in the data field are 640 samples long and with a cyclic prefix (CP) of 128 samples to prevent intersymbol interference.

IEEE 802.11ad™-2012 specifies the common aspects of the DMG PPDU packet structure in Section 21.3. The PHY modulation-specific aspects of the data field structure are specified in these sections:

  • The DMG control PHY packet structure is specified in Section 21.4.

  • The DMG OFDM PHY packet structure is specified in Section 21.5.

  • The DMG SC PHY packet structure is specified in Section 21.6.

References

[1] IEEE Std 802.11ad™-2012 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 3: Enhancements for Very High Throughput in the 60 GHz Band.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using MATLAB® Coder™.

Introduced in R2017b