MATLAB-Funktionen
Binden Sie MATLAB®-Code in Ihre Stateflow®-Diagramme ein. Implementieren Sie Algorithmen, die sich mithilfe von MATLAB leichter ausdrücken lassen, wie z. B. Matrixberechnungen und Datenanalysen.
Themen
- Reuse MATLAB Code by Defining MATLAB Functions
Create and execute MATLAB functions in a Stateflow chart.
- Program a MATLAB Function in a Chart
Define the logical behavior of a MATLAB function.
- Zugriff auf Simulink-Bus-Signale in MATLAB-Funktionen
Dieses Beispiel zeigt, wie Sie in einer MATLAB®-Funktion mithilfe von MATLAB®- und Stateflow®-Strukturen von Simulink®-Bus-Signalen lesen und auf sie schreiben können.
- Export Stateflow Functions for Reuse
Extend the scope of your functions to other blocks in a Simulink® model.
- Reuse Functions by Using Atomic Boxes
Encapsulate reusable functions in a separate namespace.
Fehlersuche
Debug a MATLAB Function in a Chart
Use breakpoints to debug MATLAB functions.
Initialize Persistent Variables in MATLAB Functions
Specialized semantics impact the way that a function initializes persistent data.