Detect loss of tunability - Diagnostic action to take if code generation reduces expression with tunable variables to numeric equivalent - MATLAB (original) (raw)

Main Content

Diagnostic action to take if code generation reduces expression with tunable variables to numeric equivalent

Model Configuration Pane: Diagnostics / Data Validity

Description

The Detect loss of tunability parameter specifies the diagnostic action to take when code generation reduces an expression with tunable variables to the numeric equivalent. This parameter applies only to:

When the Default parameter behavior (Simulink Coder) parameter is set to Tunable, this parameter does not apply to variables that have the Auto storage class.

The default diagnostic action depends on the type of the code generation target.

Settings

error | warning | none

error

The software issues an error and terminates simulation or code generation if code generation reduces an expression with tunable variables to the numeric equivalent.

This is the default setting for ERT targets.

warning

The software issues a warning if code generation reduces an expression with tunable variables to the numeric equivalent.

This is the default setting for GRT targets.

none

The software does not issue a diagnostic if code generation reduces an expression with tunable variables to the numeric equivalent.

Tips

If a tunable workspace variable is modified in mask initialization code or used in an arithmetic expression that includes unsupported operators or functions, the expression is reduced to the numeric equivalent and the variable values are no longer tunable.

Application Setting
Debugging No impact
Traceability No impact
Efficiency No impact
Safety precaution error

Programmatic Use

Parameter: ParameterTunabilityLossMsg
Type: string | character vector
Value: "none" | "warning" "error"
Default: "warning" for GRT targets | "error" for ERT targets

Version History

Introduced in R2007a