| Stateflow User's Guide | ![]() |
Monitoring Stateflow Test Points
A Stateflow test point is a signal that Stateflow guarantees to be observable, for example, by a Floating Scope block, during a simulation. Stateflow allows you to designate a data or a state in a Stateflow diagram as a test point. While all Stateflow states can be test points, only Stateflow data of local scope qualify. They can be scalar, one-dimensional, or two-dimensional in size, and of any data type except type ml. Like states, test point data must also be a descendant of a Stateflow chart.
You implicitly declare all Stateflow data of local scope and all states as test points if the Enable debugging/animation code option is selected for the Stateflow simulation target. If this option is not set, you can specify individual local data or states as test points by setting their TestPoint property in the Stateflow API or through the Model Explorer (see Setting Test Points for Stateflow States and Local Data with Model Explorer).
You can monitor individual Stateflow test points with a floating scope during model simulation. You can also log test point values into MATLAB workspace objects. Use the following topics to learn how to set test points and display the values of Stateflow test points while you are simulating a model.
| Watching Stateflow Data in MATLAB | Setting Test Points for Stateflow States and Local Data with Model Explorer | ![]() |
© 1994-2005 The MathWorks, Inc.