Skip to Main Content Skip to Search
Product Documentation

How Stateflow Software Works with Simulink Software

Stateflow charts run as blocks in a Simulink model. The Stateflow block interfaces with other blocks in the model using input and output signals. Through these connections, Stateflow and Simulink software share data and respond to events that broadcast between model and chart. For example, the Stateflow shift_logic block is integrated with the Simulink sf_car model as shown.

You can develop your Stateflow chart before or after the Simulink model in which it will run. Stateflow software comes with its own editor and debugger, which helps you simulate and test the chart logic before you integrate it with a Simulink model. You can test a Stateflow chart independently of its parent model by attaching a Source block as an input and a Sink block as an output (see Sources and Sinks in the online Simulink Reference documentation). During simulation, you can animate the chart to get visual feedback about its run-time behavior.

  


Free Stateflow Interactive Kit

Learn how engineers use Stateflow to model state machines in their Simulink models.


Get free kit

Trials Available

Try the latest version of Stateflow.


Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS