System-generated identifiers
Specify whether to use shorter names for the $N
token in
system-generated identifiers
Model Configuration Pane: Code Generation / Identifiers
Description
Specify whether the code generator uses shorter, more consistent names for the $N
token in system-generated identifiers.
Dependencies
This parameter:
Appears only for ERT-based targets.
Requires Embedded Coder® when generating code.
Settings
Shortened
(default) | Classic
Classic
Generate longer identifier names for the
$N
token. For example, for a model namedsym
, if:Global variables is
$N$R$M
, the block state identifier isDWork_sym
.Global types is
$R$N$M
, the block state type is a structure namedsym_D_Work
.
Shortened
Shorten identifier names for the
$N
token to allow more space for user names. This option provides a more predictable and consistent naming system that uses camel case, no underscores or plurals, and consistent abbreviations for both a type and a variable. For example, for a model namedsym
, if:Global variables is
$N$R$M
, the block state identifier isDW_sym
.Global types is
$R$N$M
, the block state type is a structure namedsym_DW
.
System-generated identifiers per model
Classic | Shortened | Data Representation | Description |
---|---|---|---|
BlockIO, B | B | Type, Global Variable | Block signals of the system |
ExternalInputs | ExtU | Type | Block input data for root system |
ExternalInputSizes | ExtUSize | Type | Size of block input data for the root system (used when inputs are variable dimensions) |
ExternalOutputs | ExtY | Type | Block output data for the root system |
ExternalOutputSizes | ExtYSize | Type | Size of block output data for the root system |
U | U | Global Variable | Input data |
USize | USize | Global Variable | Size of input data |
Y | Y | Global Variable | Output data |
YSize | YSize | Global Variable | Size of output data |
Parameters | P | Type, Global Variable | Parameters for the system |
ConstBlockIO | ConstB | Const Type, Global Variable | Block inputs and outputs that are constants |
| MachLocal | Const Type, Global Variable | Used by ERT S-function targets |
ConstParam, ConstP | ConstP | Const Type, Global Variable | Constant parameters in the system |
ConstParamWithInit, ConstWithInitP | ConstInitP | Const Type, Global Variable | Initialization data for constant parameters in the system |
D_Work , DWork | DW | Type, Global Variable | Block states in the system |
MassMatrixGlobal | MassMatrix | Type, Global Variable | Used for physical modeling blocks |
PrevZCSigStates, PrevZCSigState | PrevZCX | Type, Global Variable | Previous zero-crossing signal state |
ContinuousStates, X | X | Type, Global Variable | Continuous states |
StateDisabled, Xdis | XDis | Type, Global Variable | Status of an enabled subsystem |
StateDerivatives, Xdot | XDot | Type, Global Variable | Derivatives of continuous states at each time step |
ZCSignalValues, ZCSignalValue | ZCV | Type, Global Variable | Zero-crossing signals |
DefaultParameters | DefaultP | Global Variable | Default parameters in the system |
GlobalTID | GlobalTID | Global Variable | Used for sample time for states in referenced models |
InvariantSignals | Invariant | Global Variable | Invariant signals |
NSTAGES | NSTAGES | Global Variable | Solver macro |
Object | Obj | Global Variable | Used by ERT C++ code generation to refer to referenced model objects |
TimingBridge | TimingBrdg | Global Variable | Timing information stored in different data structures |
SharedDSM | SharedDSM | Type, Global Variable | Shared local data stores, which are Data Store Memory blocks with Share across model instances selected |
InstP | InstP | Type, Global Variable | Parameter arguments for the system |
System-generated identifier names per referenced model or reusable subsystem
Classic | Shortened | Data Representation | Description |
---|---|---|---|
rtB , B | B | Type, Global Variable | Block signals of the system |
rtC , C | ConstB | Type, Global Variable | Block inputs and outputs that are constants |
rtDW , DW | DW | Type, Global Variable | Block states in the system |
rtMdlrefDWork, MdlrefDWork | MdlRefDW | Type, Global Variable | Block states in referenced model |
rtP, P | P | Type, Global Variable | Parameters for the system |
rtRTM, RTM | RTM | Type, Global Variable | RT_Model structure |
rtX, X | X | Type, Global Variable | Continuous states in model reference |
rtXdis, Xdis | XDis | Type, Global Variable | Status of an enabled subsystem |
rtXdot, Xdot | XDot | Type, Global Variable | Derivatives of the S-function's continuous states at each time step |
rtZCE, ZCE | ZCE | Type, Global Variable | Zero-crossing enabled |
rtZCSV, ZCSV | ZCV | Type, Global Variable | Zero-crossing signal values |
rtSharedDSM, SharedDSM | SharedDSM | Type, Global Variable | Shared local data stores, which are Data Store Memory blocks with Share across model instances selected |
rtInstP, InstP | InstP | Type, Global Variable | Parameter arguments for the system |
Note
When you set the System-generated identifiers parameter to Shortened
, while generating an identifier for a global variable of a referenced model which is a run-time parameter, the code generator adds a prefix rtP_
to the variable name for the $N
token.
Recommended Settings
Application | Setting |
---|---|
Debugging | No impact |
Traceability | No impact |
Efficiency | No impact |
Safety precaution | No impact |
Programmatic Use
Parameter: InternalIdentifier |
Type: character vector |
Value: Classic | Shortened |
Default: Shortened |
Version History
Introduced in R2013a