ssSetOperatingPointVisibility
Specify whether to make the S-function simulation operating point visible in model simulation operating point
Since R2019a
Syntax
void ssSetOperatingPointVisibility(S, visibility)
Arguments
S
SimStruct that represents an S-function block.
visibility
Option to specify the visibility of the S-function simulation state. The default is
false
; the operating point of the s-function is hidden. Specified as true or false.
Description
This function allows you to specify whether or not the simulation state of the
S-function is accessible from the simulation snapshot of the model. When this option
is set to true
, you can access the operating point of this block
via the get
method of ModelOperatingPoint
class and you can restore any modified values via the set
of the
ModelOperatingPoint
class.
Languages
C, C++
Examples
Use the ssSetOperatingPointVisibility
function to specify
whether the simulation state of an S-function should be visible in the simulation
state of the model. The specification is based upon the second (Boolean) parameter
value.
static void mdlInitializeSizes(SimStruct* S)mdl { ssSetNumSFcnParams(S, 2); /* two parameters */ if (ssGetNumSFcnParams(S) != ssGetSFcnParamsCount(S)) return; ssSetSFcnParamTunable(S, 0, false); ssSetSFcnParamTunable(S, 1, false); { boolean_T visibility = 0U; ssSimStateCompliance setting = GetSimSnapParameterSetting(S, &visibility); if (ssGetErrorStatus(S)) return; ssSetOperatingPointCompliance(S, setting); ssSetOperatingPointVisibility(S, true); }
Version History
Introduced in R2019a