To model systems that switch between periodic or continuous time dynamics, use Simulink® based states. Simulink based states are supported only in Stateflow® charts in a Simulink model. For more information, see Simulink Subsystems as States.
Set and modify the properties of a Simulink based state in the Property Inspector or in a Simulink based state properties dialog box.
For a Simulink based state, you can set these properties.
|Simulink Based State Properties||Description|
|Create data for monitoring self activity||Creates a data output port on the Stateflow block for this self-activity of the state.|
|Log self activity||Logs the state self-activity. View the activity of the state in the Simulation Data Inspector.|
|Logging name||Specify the signal logging name. To create a signal logging name that
is different from the state name, choose
|Limit data points to last||Maximum number of data points to log. Default value is 5000, which means the chart logs the last 5000 data points generated by the simulation.|
|Decimation||Decimation interval limits the amount of data logged by skipping samples. Default value is 2, which means the chart logs every other sample.|
Sets the Simulink based state as a Stateflow test point. See Monitor Test Points in Stateflow Charts.
Specify the code format generated for a Simulink based state. You can set the format to one of these options:
See Function packaging (Simulink).