Main Content

C Code Generation

Generate C and C++ code from MATLAB® and Simulink®

Generate C and C++ code from signal processing algorithms in DSP System Toolbox™ using the MATLAB Coder™ and Simulink Coder products. You can integrate the generated code into your projects as source code, static libraries, dynamic libraries, or even standalone executables. For more information, see Understanding C Code Generation in DSP System Toolbox. For a list of functions and blocks which support C/C++ code generation, see Functions and System Objects in DSP System Toolbox that Support C Code Generation and Simulink Blocks in DSP System Toolbox that Support C Code Generation, respectively.

In addition, you can also generate code optimized for ARM® Cortex® -M and ARM Cortex-A processors using the Embedded Coder® product. For more information, see Code Generation for ARM Cortex-M and ARM Cortex-A Processors. Once you generate code, you can relocate the code to another development environment that does not have MATLAB and Simulink products installed. For examples, see Relocate Code Generated from MATLAB Code to Another Development Environment and Relocate Code Generated from a Simulink Model to Another Development Environment.

Functions

codegenGenerate C/C++ code from MATLAB code

Topics

Featured Examples