Main Content

EMX array types identifier format

Description

Customize generated identifiers for emxArray (embeddable mxArray) types. The code generator produces emxArray types for variable-size arrays that use dynamically allocated memory. This parameter applies to MATLAB® code in a MATLAB Function block, a Stateflow® chart, or a System object™ associated with a MATLAB System block. This parameter does not apply to:

  • Input or output signals

  • Parameters

  • Global variables

  • Discrete state properties of System objects associated with a MATLAB System block

Category: Code Generation > Identifiers

Settings

Default: emxArray_$M$N

Enter a macro that specifies whether, and in what order, certain text is to be included in the generated identifier. The macro can include a combination of the following format tokens.

TokenDescription
$M

Insert name-mangling text if required to avoid naming collisions.

Required.

$N

Insert type name. For example, real_T

$R

Insert root model name into identifier, replacing unsupported characters with the underscore (_) character.

Required for model referencing.

Tips

  • The code generator applies the identifier format specified by this parameter before it applies the formats specified by other identifier format control parameters.

  • Where possible, increase the Maximum identifier length to accommodate the length of the identifiers you expect to generate. Reserve at least three characters for name-mangling text.

  • If you specify $R, the value you specify for Maximum identifier length must be large enough to accommodate full expansions of the $R and $M tokens.

Dependencies

This parameter:

  • Appears only for ERT-based targets.

  • Requires an Embedded Coder® when generating code.

Command-Line Information

Parameter: CustomSymbolStrEmxType
Type: character vector
Value: valid combination of tokens
Default: emxArray_$M$N

Recommended Settings

ApplicationSetting
DebuggingNo impact
TraceabilityNo impact
EfficiencyNo impact
Safety precautionNo recommendation

Related Topics