Main Content

Simulink.SFunctionBuilder.setBuildOptions

Set build options for S-Function Builder block

Since R2022a

    Description

    Simulink.SFunctionBuilder.setBuildOptions(blk,Name=Value) sets build options specified using one or more name-value arguments for the S-Function Builder block blk. For example, to include debugging information in the generated MEX file, specify CreateDebuggableMEX as true.

    To configure S-function settings such as access to the SimStruct, sample mode, and sample time, use the Simulink.SFunctionBuilder.setSettings function.

    To specify the language for the S-function, use the Simulink.SFunctionBuilder.setTargetLanguage function.

    Input Arguments

    collapse all

    S-Function Builder block, specified as a block handle or as a string or a character vector that defines the block path.

    Tips

    • To get the block handle for a block in your model, use the getSimulinkBlockHandle function.

    • To get the block handle for the most recently selected or added block, use the gcbh function.

    Name-Value Arguments

    Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

    Before R2021a, use commas to separate each name and value, and enclose Name in quotes.

    Example: CreateDebuggableMEX=true

    Option to log build steps, specified as logical 1 (true) or 0 (false).

    Example: ShowCompileSteps=true

    Data Types: logical

    Option to include debugging information in generated MEX file, specified as logical 1 (true) or 0 (false).

    Example: CreateDebuggableMEX=true

    Data Types: logical

    Option to generate TLC file, specified as logical 1 (true) or 0 (false).

    Example: GenerateWrapperTLC=false

    Data Types: logical

    Option to build S-function that supports model coverage, specified as logical 1 (true) or 0 (false).

    Example: EnableSupportForCoverage=true

    Data Types: logical

    Option to build S-function that supports Simulink Design Verifier, specified as logical 1 (true) or 0 (false).

    Example: EnableSupportForDesignVerifier=true

    Data Types: logical

    Version History

    Introduced in R2022a