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.

wlanDMGDataBitRecover

Recover data bits from DMG data field

Syntax

DataBits = wlanDMGDataBitRecover(rxDataSig,noiseVarEst,cfg)
DataBits = wlanDMGDataBitRecover(rxDataSig,noiseVarEst,csi,cfg)
DataBits = wlanDMGDataBitRecover(___,Name,Value)

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 = 

   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. The wlanDMGDataBitRecover function uses the following object properties:

Modulation and coding scheme index, specified as an integer from 0 to 24. The MCS index indicates the modulation and coding scheme used in transmitting the current packet.

  • Modulation and coding scheme for control PHY

    MCS IndexModulationCoding RateComment

    0

    DBPSK

    1/2

    Code rate and data rate might be lower due to codeword shortening.

  • Modulation and coding schemes for single-carrier modulation

    MCS IndexModulationCoding RateNCBPSRepetition

    1

    π/2 BPSK

    1/2

    1

    2

    2

    1/2

    1

    3

    5/8

    4

    3/4

    5

    13/16

    6

    π/2 QPSK

    1/2

    2

    7

    5/8

    8

    3/4

    9

    13/16

    10

    π/2 16QAM

    1/2

    4

    11

    5/8

    12

    3/4

    NCBPS is the number of coded bits per symbol.

  • Modulation and coding schemes for OFDM modulation

MCS IndexModulationCoding RateNBPSCNCBPSNDBPS

13

SQPSK

1/2

1

336

168

14

5/8

210

15

QPSK

1/2

2

672

336

16

5/8

420

17

3/4

504

18

16QAM

1/2

4

1344

672

19

5/8

840

20

3/4

1008

21

13/16

1092

22

64QAM

5/8

6

2016

1260

23

3/4

1512

24

13/16

1638

NBPSC is the number of coded bits per single carrier.

NCBPS is the number of coded bits per symbol.

NDBPS is the number of data bits per symbol.

Data Types: double

Number of training fields, specified as an integer from 0 to 64. TrainingLength must be a multiple of four.

Data Types: double

Packet training field type, specified as 'TRN-R' or 'TRN-T'. This property applies when TrainingLength > 0.

'TRN-R' indicates that the packet includes or requests receive-training subfields and 'TRN-T' indicates that the packet includes transmit-training subfields.

Data Types: char | string

Request beam tracking, specified as a logical. Setting BeamTrackingRequest to true indicates that beam tracking is requested. This property applies when TrainingLength > 0.

Data Types: logical

Tone pairing type, specified as 'Static' or 'Dynamic'. This property applies when MCS is from 13 to 17. Specifically, TonePairingType applies when using OFDM and either SQPSK or QPSK modulation.

Data Types: char | string

DTP group pair index, specified as a 42-by-1 integer vector for each pair. Element values must be from 0 to 41, with no duplicates. This property applies when MCS is from 13 to 17 and when TonePairingType is 'Dynamic'.

Data Types: double

DTP update indicator, specified as a logical. Toggle DTPIndicator between packets to indicate that the dynamic tone pair mapping has been updated. This property applies when MCS is from 13 to 17 and when TonePairingType is 'Dynamic'.

Data Types: logical

Number of bytes carried in the user payload, specified as an integer from 1 to 262,143.

Data Types: double

Initial scrambler state of the data scrambler for each packet generated, specified as an integer from 1 to 127. When MCS is 0, the initial scrambler state is limited to values from 1 to 15. The default value of 2 is the example state given in IEEE Std 802.11™-2012, Amendment 3, Section L.5.2.

Data Types: double | int8

MPDU aggregation indicator, specified as a logical. Setting AggregatedMPDU to true indicates that the current packet uses A-MPDU aggregation.

Data Types: logical

Received power level of the last packet, specified as an integer from 0 to 15.

When transmitting a response frame immediately following a short interframe space (SIFS) period, a DMG STA sets the LastRSSI as specified in IEEE® 802.11ad™-2012, Section 9.3.2.3.3, to map to the TXVECTOR parameter LAST_RSSI of the response frame to the power that was measured on the received packet, as reported in the RCPI field of the frame that elicited the response frame. The encoding of the value for TXVECTOR is as follows:

  • Power values equal to or above –42 dBm are represented as the value 15.

  • Power values between –68 dBm and –42 dBm are represented as round((power – (–71 dBm))/2).

  • Power values less than or equal to –68 dBm are represented as the value of 1.

  • For all other cases, the DMG STA shall set the TXVECTOR parameter LAST_RSSI of the transmitted frame to 0.

The LAST_RSSI parameter in RXVECTOR maps to LastRSSI and indicates the value of the LAST_RSSI field from the PCLP header of the received packet. The encoding of the value for RXVECTOR is as follows:

  • A value of 15 represents power greater than or equal to –42 dBm.

  • Values from 2 to 14 represent power levels (–71+value×2) dBm.

  • A value of 1 represents power less than or equal to –68 dBm.

  • A value of 0 indicates that the previous packet was not received during the SIFS period before the current transmission.

For more information, see IEEE 802.11ad-2012, Section 21.2.

Data Types: double

Turnaround indication, specified as a logical. Setting Turnaround to true indicates that the STA is required to listen for an incoming PPDU immediately following the transmission of the PPDU. For more information, see IEEE 802.11ad-2012, Section 9.3.2.3.3.

Data Types: logical

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 single 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.

collapse all

Maximum number of LDPC decoding iterations, specified as the comma-separated pair consisting of 'MaximumLDPCIterationCount' and a positive integer.

Data Types: double

Enable early termination of LDPC decoding, specified as the comma-separated pair consisting of 'EarlyTermination' and a logical.

  • 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.

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

Introduced in R2017b

Was this topic helpful?