Conceptos básicos de los bloques MATLAB Function
Utilice bloques MATLAB Function para implementar funciones de MATLAB en modelos de Simulink. Usando los bloques MATLAB Function se puede generar código C/C++ legible, eficiente y compacto para desplegarlo en aplicaciones de escritorio e integradas.
Herramientas
MATLAB Function Block Editor | Create, edit, and debug MATLAB code in MATLAB Function blocks |
Bloques
MATLAB Function | Include MATLAB code in models that generate embeddable C code |
Objetos
MATLABFunctionConfiguration | MATLAB Function block property configuration (desde R2019b) |
Stateflow.EMChart | Stateflow interface to MATLAB Function block |
Ajustes de modelos
Temas
- Implementar funciones de MATLAB en Simulink con bloques MATLAB Function
Utilice bloques MATLAB Function para implementar código escrito en MATLAB en modelos de Simulink.
- Resolve Signal Objects for Output Variables
Manage implicit signal resolution at various levels of the model hierarchy.
- Run Simulations and Generate Code with Masked Library Subsystems Containing MATLAB Function Blocks
Run simulations and generate code with models using custom MATLAB Function blocks in a library.
- Code and Integration Limitations for MATLAB Function Blocks
Learn limitations of MATLAB Function blocks before use in your model.
- Call MATLAB Function Files in MATLAB Function Blocks
Use MATLAB Function blocks to call and execute code written in MATLAB function files.
- Integrate C Code by Using the MATLAB Function Block
Use MATLAB Function blocks to call external C code and control enumeration and bus typedefs.
- Configure MATLAB Function Blocks Programmatically
Set up a MATLAB Function block and inspect it with programmatic commands.
Solución de problemas
Debug MATLAB Function block code during simulation.
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.