HDL Applications for the MATLAB Function Block - MATLAB & Simulink (original) (raw)

Main Content

Structure of Generated HDL Code

The MATLAB Function block contains a MATLAB® function in a model. The inputs and outputs of the function are represented by the ports on the block, which allow you to interface your model to the function code. When you generate HDL code for a MATLAB Function block, HDL Coder™ generates two HDL files:

The structure of these code files is analogous to the structure of the model, in which a subsystem provides an interface between the root model and the function in the MATLAB Function block.

HDL Applications

The MATLAB Function block supports a subset of the MATLAB language that is well-suited to HDL implementation of various DSP and telecommunications algorithms, such as:

You can also use the MATLAB Function block in a wide variety of floating-point applications. Both single anddouble types are supported. To learn more, see HDL Optimizations Across MATLAB Function Block Boundary Using MATLAB Datapath Architecture.

See Also

Check for MATLAB Function block settings

Topics