MATLAB Function 模块基础
将 MATLAB® 函数集成到 Simulink® 模型中
使用 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 |
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 代码并控制枚举和总线类型定义。
- 将 Python 代码与 Simulink 集成的概述
使用 MATLAB Function 模块或 MATLAB System 模块将 Python® 代码与 Simulink 集成。
- 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.
专门的语义会影响函数初始化持久数据的方式。