Author Blocks Using MATLAB Functions
Add MATLAB® algorithms to Simulink®
Use the MATLAB Function block to add MATLAB functions to Simulink models. Use this block to create algorithms that are easier to write in the textual language of MATLAB than in the graphical language of Simulink. Using MATLAB Function blocks, you can generate readable, efficient, and compact C/C++ code for deployment to desktop and embedded applications.
Categories
- MATLAB Function Block Basics
Integrate MATLAB functions into Simulink models
- Arguments and Units in MATLAB Function Blocks
Specify argument types, sizes, and units for MATLAB Function blocks
- MATLAB Function Block Editor
Edit MATLAB Function block code, define variables, input triggers, and function-call outputs
- Programming for Code Generation
Supported MATLAB features and functions, data definition, differences between generated code and MATLAB
- Performance
Guidelines for improving generated code performance