lteSCI
Sidelink control information format structure and bit payload
Syntax
Description
[
returns a sidelink control
information (SCI) message structure, sciout
,bitsout
]
= lteSCI(ue
)sciout
,
and the SCI message bit vector, bitsout
, for
the settings specified in the user equipment structure.
This function creates and manipulates SCI format 0 messages,
defined in TS 36.212 [1], Section
5.4.3. You can use lteSCI
to create a default
SCI message, to blindly decode SCI format types, and to determine
the sizes of the bit fields.
By default, all returned fields are set to zero.
[
returns
the SCI structure fields and bit vector using settings specified in
SCI input structure sciout
,bitsout
]
= lteSCI(ue
,sciin
)sciin
. Fields not defined
in sciin
are set to defaults specified by ue
.
You can use this syntax to initialize SCI field values, in particular
the frequency hopping bit, which affects the fields that the format
uses.
Examples
Create SCI Message
Create a format 0 SCI message structure.
Create a UE settings structure.
ue = struct('NSLRB','15MHz');
Generate an SCI message and view the returned SCI message structure contents.
[sci0,bits] = lteSCI(ue); sci0
sci0 = struct with fields:
SCIFormat: 'Format0'
FreqHopping: 0
Allocation: [1x1 struct]
TimeResourcePattern: 0
ModCoding: 0
TimeAdvance: 0
NSAID: 0
allocfields = sci0.Allocation
allocfields = struct with fields:
RIV: 0
Create SCI Message with Distributed VRB Allocation Type
Create a format 0 SCI message structure with the distributed VRB allocation type. The allocation message fields are contained in the Allocation
substructure. To create the appropriate set of fields at the output, the FreqHopping
field is initialized at the input to the function.
Create a UE settings structure and define FreqHopping
using an input SCI message structure.
ue = struct('NSLRB',50); sciin = struct('FreqHopping',1);
Generate an SCI message and view the returned SCI message structure contents.
[sci0,bits] = lteSCI(ue,sciin); sci0
sci0 = struct with fields:
SCIFormat: 'Format0'
FreqHopping: 1
Allocation: [1x1 struct]
TimeResourcePattern: 0
ModCoding: 0
TimeAdvance: 0
NSAID: 0
allocfields = sci0.Allocation
allocfields = struct with fields:
HoppingBits: 0
RIV: 0
Recover SCI Message from Bit Vector
Recover the contents of a format 0 SCI message bit vector.
Create a UE settings structure.
ue = struct('NSLRB',50);
Generate an SCI message structure.
[sci0,bits] = lteSCI(ue); sci0
sci0 = struct with fields:
SCIFormat: 'Format0'
FreqHopping: 0
Allocation: [1x1 struct]
TimeResourcePattern: 0
ModCoding: 0
TimeAdvance: 0
NSAID: 0
Change the ModCoding
setting to 22 and generate an SCI bits vector.
sci0.ModCoding = 22; [~,bits_new] = lteSCI(ue,sci0);
Use the new bits to recover the new SCI message. View the new SCI message structure and confirm that the ModCoding
setting is now 22.
[sci0_new,~] = lteSCI(ue,bits_new)
sci0_new = struct with fields:
SCIFormat: 'Format0'
FreqHopping: 0
Allocation: [1x1 struct]
TimeResourcePattern: 0
ModCoding: 22
TimeAdvance: 0
NSAID: 0
View SCI Message Field Sizes
Create a format 0 SCI message structure. Use the opts
input to view the message field sizes and to exclude fields with zero length.
Create a UE settings structure.
ue = struct('NSLRB','5MHz'); opts = {'fieldsizes','excludeunusedfields'}
opts = 1x2 cell
{'fieldsizes'} {'excludeunusedfields'}
Generate an SCI message and view the field sizes of the returned SCI message structure contents.
[sci0,bits] = lteSCI(ue,opts); sci0
sci0 = struct with fields:
SCIFormat: 'Format0'
FreqHopping: 1
Allocation: [1x1 struct]
TimeResourcePattern: 7
ModCoding: 5
TimeAdvance: 11
NSAID: 8
allocfields = sci0.Allocation
allocfields = struct with fields:
RIV: 9
Inspect the returned structure to see the bit length of each field in the SCI message.
fieldsLength = sci0.FreqHopping + sci0.Allocation.RIV + ... sci0.TimeResourcePattern + sci0.ModCoding + sci0.TimeAdvance + ... sci0.NSAID
fieldsLength = uint64
41
bitsLength = size(bits,1)
bitsLength = 41
isequal(fieldsLength,bitsLength)
ans = logical
1
The sum of the field sizes matches the length of the returned bits
output.
Input Arguments
ue
— User equipment settings
structure
User equipment settings, specified as a structure containing these parameter fields:
PSSCHNSubchannels
— Number of sub-channels in the V2X PSSCH resource pool
1
(default) | integer scalar from 1 to 110 | optional
Number of sub-channels in the V2X PSSCH resource pool,
specified as an integer scalar from 1 to 110. You must specify
this input when you set the sciin
to
'Format1'
.
Data Types: double
NSLRB
— Number of sidelink resource blocks
integer scalar from 6 to 110
Number of sidelink resource blocks, specified as an integer scalar from 6 to 110.
Example: 6
, which corresponds to a channel
bandwidth of 1.4 MHz.
Data Types: double
opts
— Formatting options for output SCI structure
character vector | cell array of character vectors | string array
Formatting options for output SCI structure, specified as a character
vector, cell array of character vectors, or a string array. You can specify
a format for the Field content and Fields to
include. For convenience, you can specify several options as
a single character vector or string scalar by a space-separated list of
values placed inside the quotes. Values for opts
when
specified as a character vector include (use double quotes for
string):
Category | Options | Description |
---|---|---|
Field content |
| Set the fields to zero or to their input values. |
| Sets the field values to their bit sizes and adds
the | |
Fields to include |
|
|
|
|
Example: 'fieldsizes excludeunusedfields'
,
"fieldsizes excludeunusedfields"
,
{'fieldsizes','excludeunusedfields'}
, or
["fieldsizes","excludeunusedfields"]
specify the same
formatting options.
Data Types: char
| string
| cell
sciin
— SCI message settings
structure
SCI message settings, specified as a structure containing any fields
returned in sciout
. See sciout
for
the specific fields output for each SCIFormat
. SCI format
0 message is defined in TS 36.212 [1], Section 5.4.3.1. It can contain the following
field:
SCIFormat
— SCI format type
'Format0'
(default) | 'Format1'
SCI format type, specified as 'Format0'
or
'Format1'
.
Data Types: char
| string
Data Types: struct
bitsin
— Input bits
column vector
Input bits, specified as a column vector. bitsin
is
treated as the SCI message bit payload, that is,
bitsout
== bitsin
.
The length of bitsin
must align with the number of
resource blocks, ue
.NSLRB
. Use
lteSCIInfo
to determine SCI
message length for the specified ue
settings.
Data Types: double
Output Arguments
sciout
— SCI message structure
structure
SCI message structure, returned as a structure whose fields match the associated SCI format contents.
The field names associated with sciout
depend on the
SCI format field in sciin
. By default, all values are
set to zero. However, if any of the SCI fields are already present in the
input sciin
, their values are carried forward into
sciout
. The input field values appear in the
associated bit positions in bitsout
. Carrying the
values forward allows for easy initialization of SCI field values.
sciout
also carries forward the
NSLRB
field specified in
sciin
.
This table presents the fields associated with each SCI format, as defined in TS 36.212 [1], Section 5.4.3.1.
SCI Formats | sciout Fields | Size | Description |
---|---|---|---|
'Format0'
| SCIFormat | - | 'Format0' |
FreqHopping | 1 bit | PSSCH frequency hopping flag | |
Allocation | from 5 to 13 bits, | Resource block assignment and hopping resource allocation substructure, type 0 or type 1 allocation | |
TimeResourcePattern | 7 bits | Time resource pattern (ITRP) | |
ModCoding | 5 bits | Modulation and coding scheme (IMCS) | |
TimeAdvance | 11 bits | Timing advance indication | |
NSAID | 8 bits | Group destination ID, as defined by higher layers | |
Padding | 0 bits | Always zero for SCI Format 0 | |
'Format1'
| SCIFormat | - | 'Format1' |
Priority | 3 bits | Per packet priority | |
ResourceReservation | 4 bits | Resource reservation | |
RIV | from 0 to 13 bits, | Resource indication value | |
TimeGap | 4 bits |
Time gap between initial transmission and retransmission | |
ModCoding | 5 bits | Modulation and coding scheme | |
RetransmissionIdx | 1 bit | Retransmission index |
bitsout
— SCI message in bit payload form
column vector of binary values
SCI message in bit payload form, returned as a column vector. bitsout
represents
the set of message fields mapped to the information bit payload (including
any zero-padding).
References
[1] 3GPP TS 36.212. “Evolved Universal Terrestrial Radio Access (E-UTRA); Multiplexing and channel coding.” 3rd Generation Partnership Project; Technical Specification Group Radio Access Network. URL: https://www.3gpp.org.
Version History
Introduced in R2016b
See Also
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)