Main Content

NR Symbol Demodulator

Demodulate complex NR data symbols to data bits or LLR values

Since R2019b

  • NR Symbol Demodulator block

Libraries:
Wireless HDL Toolbox / Modulation

Description

The NR Symbol Demodulator block demodulates complex data symbols to data bits or log likelihood ratios (LLR) values based on the modulation types supported by 5G New Radio (NR) standard TS 38.211 [1]. The block provides an architecture suitable for HDL code generation and hardware deployment. You can use this block in the development of an NR receiver.

The block accepts data symbols, along with a valid signal, and outputs demodulated bits or LLR values with valid and ready signals. The number of demodulated bits or LLR values for a given symbol depends on the modulation type, as shown in this table.

Modulation TypeNumber of Bits per Symbol (NBPS)
BPSK1
QPSK2
16-QAM4
64-QAM6
256-QAM8
pi/2-BPSK1

The ready output port indicates when the block can accept an input data sample. You can use ready output port to control the upstream data coming to the block.

Ports

Input

expand all

Input data symbols, specified as a complex scalar. The block performs demodulation assuming the input constellation power normalization is in accordance with NR standard TS 38.211, Section 5.1 [1]. The normalization values are based on the modulation type.

  • 1/√2 for BPSK, QPSK, and pi/2-BPSK

  • 1/√10 for 16-QAM

  • 1/√42 for 64-QAM

  • 1/√170 for 256-QAM

Example: For BPSK modulation, the input values can be [0.707 +0.707i; -0.707 -0.707i]

The software supports double and single data types for simulation, but not for HDL code generation.

For HDL code generation, the input data type must be signed fixed point and the maximum input word length the block supports is 32 bits.

Data Types: single | double | signed fixed point
Complex Number Support: Yes

Control signal that indicates if the input data is valid. When this value is 1 (true), the block accepts the values on the data input port. When this value is 0 (false), the block ignores the values on the data input port.

Data Types: Boolean

Select the modulation type by specifying its corresponding value shown in this table. Valid modSel values are from 0 to 5. Each value represents a specific modulation type, as shown in this table.

ValueModulation Type
0 BPSK
1QPSK
216-QAM
364-QAM
4 256-QAM
5pi/2-BPSK

If you specify a value other than one listed in this table, the block displays a warning message and applies QPSK modulation.

The software supports double and single data types for simulation, but not for HDL code generation.

For HDL code generation, specify this value in fixdt(0,3,0) format.

Dependencies

To enable this port, set the Modulation source parameter to Input port.

Data Types: single | double | signed fixed point

Output

expand all

Output demodulated data bits or LLR values, returned as a scalar.

  • When you set the Decision type parameter to Soft, the block outputs demodulated LLR values. A positive LLR output value is considered as 0 and a negative LLR output value is considered as 1. The magnitude of the output gives a piecewise linear approximation to the LLR of the demodulated bits. The algorithm used for the LLR approximation is described in [1]. The block scales the returned LLRs with a respective scaling factor based on the modulation type as shown in this table.

    Modulation TypeScaling Factor
    BPSK4/√2
    QPSK4/√2
    16-QAM[4 8]/√10
    64-QAM[4 8 12 16]/√42
    256-QAM[4 8 12 16 20 24 28 32]/√170
    pi/2-BPSK4/√2

    The output word length increases by 3 bits for inputs with data type signed fixed point. For input with data types double or single, the output data type is the same as the input data type.

  • When you set the Decision type parameter to Hard, the block results in the output containing the bit sequences corresponding to the closest constellation points to the input. The data type of this output is Boolean.

Data Types: single | double | signed fixed point | Boolean

Control signal that indicates if data from the data output port is valid. When this value is 1 (true), the block returns valid data on the data output port. When this value is 0 (false), the values on the data output port are not valid.

Data Types: Boolean

Control signal that indicates when the block is ready to accept new input data. When this value is 1 (true), the block accepts input data in the next time step. When this value is 0 (false), the block ignores the input data in the next time step.

The ready signal remains 0 (false) until the block outputs data of the corresponding input data symbol. The number of clock cycles the ready signal remains 0 (false) depends on the selected modulation type. If the selected modulation type is 16-QAM, the ready signal remains 0 (false) for 3 clock cycles, calculated as NBPS – 1 and then it changes to 1 (true) indicating that the block is ready to accept data in the next time step.

Data Types: Boolean

Parameters

expand all

To specify the modulation type by using the Modulation parameter, select Property. To specify the modulation type from the modSel port during run time, select Input port.

Select the modulation type.

Dependencies

To enable this parameter, set the Modulation source parameter to Property.

Select the demapping type.

  • Soft — Demap data symbols to LLR values. This LLR value for each bit indicates how likely the bit is 1 or 0.

  • Hard — Demap data symbols to bits 1 or 0.

This parameter specifies the type of rounding mode for internal fixed-point calculations. For more information about rounding modes, see Rounding Modes. This parameter does not apply when the input is of data type double or single.

Algorithms

expand all

The block outputs data in the form of bits or LLR values based on the demapping type you specify for the Decision type parameter: Hard or Soft respectively. For this demapping, the block implements simplified approximate LLR algorithm [2].

References

[1] 3GPP TS 38.211. "NR; Physical channels and modulation." 3rd Generation Partnership Project; Technical Specification Group Radio Access Network. URL: https://www.3gpp.org.

[2] F. Tosato and P. Bisaglia. "Simplified soft-output de-mapper for binary interleaved coded OFDM with application to HIPERLAN/2." ICC 2002, Vol. 2, pp. 664–668.

Extended Capabilities

Version History

Introduced in R2019b