MATLAB Function 模块基础
使用 MATLAB Function 模块在 Simulink 模型中实现 MATLAB 函数。
工具
MATLAB Function 模块编辑器 | Create, edit, and debug MATLAB code in MATLAB Function blocks |
模块
MATLAB Function | 在 Simulink 模型中包含 MATLAB 代码 |
对象
MATLABFunctionConfiguration | MATLAB Function block property configuration (自 R2019b 起) |
Stateflow.EMChart | Stateflow interface to MATLAB Function block |
模型设置
主题
- 用 MATLAB Function 模块在 Simulink 中实现 MATLAB 函数
使用 MATLAB Function 模块在 Simulink 模型中实现 MATLAB 代码。
- 为输出变量解析信号对象
在模型层次结构的各个层次上管理隐式信号解析。
- Code and Integration Limitations for MATLAB Function Blocks
Learn limitations of MATLAB Function blocks before use in your model.
- 使用 MATLAB Function 模块集成 C 代码
使用 MATLAB Function 模块调用外部 C 代码并控制枚举和总线类型定义。
- Overview of Integrating Python Code with Simulink
Integrate Python® code with Simulink Using MATLAB Function block or MATLAB System block.
- Configure MATLAB Function Blocks Programmatically
Set up a MATLAB Function block and inspect it with programmatic commands.
疑难解答
在仿真期间调试 MATLAB Function 模块代码。
Prevent Algebraic Loop Errors in MATLAB Function, Chart, and Truth Table Blocks
Adhere to restrictions for using MATLAB Function blocks, Chart, and Truth Table blocks in feedback loops.
Initialize Persistent Variables in MATLAB Functions
Specialized semantics impact the way that a function initializes persistent data.