Main Content

App Design

Control the behavior of MATLAB® apps created in App Designer

Use Stateflow® to create state machines that define the behavior of MATLAB apps. Stateflow charts can monitor your interactions with an app and enable or disable app widgets accordingly. For charts in Simulink® models, use the keyword this to establish a bidirectional connection between the app and the chart, as illustrated in Model a Power Window Controller. For standalone charts in MATLAB, use the app startup callback to create a chart object that can communicate with the app, as illustrated in Design Human-Machine Interface Logic by Using Stateflow Charts.

Stateflow Syntax

thisAccess chart data during simulation

Rubriques

Connect Apps to Charts in Simulink Models

Connect Apps to Standalone Charts in MATLAB