Main Content

Terminate code

Include custom code in the generated model terminate function

Model Configuration Pane: Code Generation / Custom Code


Specify custom code to include in the generated model terminate function.


A terminate function is generated only if you select the Terminate function required check box.


'' (default) | string

Specify code to appear in the model's generated terminate function in the model.c or model.cpp file.

Recommended Settings

DebuggingNo impact
TraceabilityNo impact
EfficiencyNo impact
Safety precautionNo impact

Programmatic Use

Parameter: CustomTerminator
Type: character vector
Value: C code
Default: ''

Version History

Introduced before R2006a