Specify custom data type names
Option to replace built-in data type names in generated code
Model Configuration Pane: Code Generation / Data Type Replacement
Description
The Specify custom data type names parameter determines whether to replace built-in data type names in the generated code with data type names that you specify. For example, when you want to generate code that adheres to application or site standards for data type naming.
This parameter enables you to specify replacements in the generated code for:
Built-in data type names through the Data type names table.
Boolean and data type limit identifiers through the Advanced parameters section.
Settings
off (default) | ononDisplay the Data type names table, which enables you to change the names of built-in data types used by the generated code.
You can specify new data type names for some or all of the Simulink® built-in data types listed in the table. Specify the replacement name as one of the following:
A
Simulink.AliasTypeobject.A
Simulink.NumericTypeobject.The Simulink Name built-in data type name.
If you use a
Simulink.AliasTypeorSimulink.NumericTypeobject and Data type replacement is set toUse C data types with fixed-width integers, theHeaderFileobject property must be set to the name of the header file that provides the type definition.An error occurs, if:
A replacement data type specification is not consistent with the Simulink Name data type.
The
Simulink.AliasTypeobject has the Data scope parameter set toExported.
offIn generated code, use Simulink Coder™ names for built-in Simulink data types.
Recommended Settings
| Application | Setting |
|---|---|
| Debugging | No impact |
| Traceability | On |
| Efficiency | No impact |
| Safety precaution | No impact |
Programmatic Use
Parameter: EnableUserReplacementTypes |
| Type: character vector |
Value: 'on' | 'off' |
Default: 'off' |
Version History
Introduced in R2007a