Contenuto principale

Include headers

Interface header code

Model Configuration Pane: Simulation Target

Description

The Include headers parameter specifies header code containing types and function declarations to import into Simulink®.

Settings

none (default) | ...

Tips

  • Write valid C/C++ code. When you include a custom header file, use the #include directive. You can also include extern declarations of variables or functions.

    Include header configuration parameter.

  • Additionally, for versions R2024a or later, you can include a custom header file without the #include directive. However, mixed declarations in a single configuration parameter set are not supported. For this parameter, mixed declarations occur when any one of the following conditions is met.

    • Declaring header files with and without the #include directive.

    • Include valid C/C++ code and declare header files without the #include directive.

    (since R2024a)

    Include header files without #include directive.

Recommended Settings

ApplicationSetting
Debugging

No recommendation

Traceability

No recommendation

Efficiency

No recommendation

Safety precaution

No recommendation

Programmatic Use

Parameter: SimCustomHeaderCode
Type: character vector or string scalar
Value: any C code
Default: none

Version History

Introduced in R2020b