Author Blocks Using MATLAB
Use MATLAB® code within specialized APIs to author blocks
Author block algorithms using MATLAB code:
If your model does not require states or has discrete states retained for a single time step, use MATLAB Function block.
If your model has continuous states or discrete states with multirate input and output ports, use the Level 2 MATLAB S-Function. This workflow does not support bus input and output ports and might require manually creating a Target Language Compiler (TLC) for code generation.
If your model has discrete states and you want to generate code without a TLC file, use the MATLAB System block. This block allows you to effectively process large streaming data.
Categories
- Author Blocks Using MATLAB S-Functions
Create blocks whose properties and behaviors are defined by MATLAB S-functions
- Author Blocks Using MATLAB System Objects
Add System object™ algorithm that models dynamic systems to Simulink®
- Author Blocks Using MATLAB Functions
Add MATLAB algorithms to Simulink