Documentation

ltePBCHPRBS

PBCH pseudorandom scrambling sequence

Syntax

  • seq = ltePBCHPRBS(enb,n)
    example
  • seq = ltePBCHPRBS(enb,n,mapping)

Description

example

seq = ltePBCHPRBS(enb,n) returns a vector with the first n outputs of the Physical Broadcast Channel (PBCH) scrambling sequence when initialized with the structure enb.

seq = ltePBCHPRBS(enb,n,mapping) allows control over the format of the returned sequence, seq, through the string mapping. Valid formats are 'binary', the default, and 'signed'. The 'binary' format maps true to 1 and false to 0. The 'signed' format maps true to –1 and false to 1.

Examples

collapse all

Scramble Broadcast Channel MIB Message

Scramble the MasterInformationBlock broadcast channel (BCCH) message.

Create a cell-wide configuration structure initialzed to RMC R.0. Generate the MIB and coded BCH.

enb = lteRMCDL('R.0');
mib = lteMIB(enb);
bchCoded = lteBCH(enb,mib);

Generate the required length of the PBCH scrambling sequence. Scramble the coded BCH.

pbchPrbsSeq = ltePBCHPRBS(enb,length(bchCoded));
scrambled = xor(pbchPrbsSeq, bchCoded);

Compare Pseudorandom Scrambling Sequences

Compare the PBCH scrambling sequence generated using both generic and PBCH-specific pseudorandom binary sequence generators.

Create a cell-wide configuration structure initialzed to RMC R.0. Generate the first 25 bits of the pseudorandom binary sequence for physical layer cell identity, NCellID using ltePRBS and ltePBCHPRBS.

enb = lteRMCDL('R.0');
prbsSeq = ltePRBS(enb.NCellID, 25);
pbchPrbsSeq = ltePBCHPRBS(enb,25);
isequal(prbsSeq,pbchPrbsSeq)
ans =

     1

The generic pseudorandom binary scrambling sequence equals the PBCH-specific pseudorandom binary scrambling sequence.

Input Arguments

collapse all

enb — Cell-wide settingsstructure

Cell-wide settings, specified as a structure. enb must contain the following field.

NCellID — Physical layer cell identityscalar integer

Physical layer cell identity, specified as a scalar integer.

Data Types: double

Data Types: struct

n — Number of outputsnumeric scalar

Number of outputs, specified as a numeric scalar.

Data Types: double

mapping — Output sequence formatting'binary' (default) | 'signed'

Output sequence formatting, specified as a string. Valid formats are 'binary' and 'signed'. 'binary' maps true to 1 and false to 0. 'signed' maps true to –1 and false to 1.

Data Types: char

Output Arguments

collapse all

seq — PBCH pseudorandom scrambling sequencelogical column vector | numeric column vector

PBCH pseudorandom scrambling sequence, specified as a logical column vector or a numeric column vector. seq contains the first n outputs of the physical broadcast channel (PBCH) scrambling sequence. If n is set to 'signed', seq is a vector of data type double. Otherwise, it is a vector of data type logical.

Data Types: logical | double

Introduced in R2014a

Was this topic helpful?