Connecting Source and Sink Blocks - Connecting Source and Sink Blocks - 2026.1 English - UG1483

Vitis Model Composer User Guide (UG1483)

Document ID
UG1483
Release Date
2026-06-23
Version
2026.1 English

The AI Engine library is compatible with the standard Simulink block library. You can use blocks from each library together to create models that can be simulated in Simulink. However, during code generation, Model Composer only permits blocks which are designed for probing at different points in the design and debugging inside a subsystem. Namely, Scope, Display, To Workspace blocks, and so on. Additionally, the AI Engine library provides sink blocks for connection to the variable-size signal output from the AIE Kernel or AIE Graph blocks.

Table 1. Sink Blocks
Block Description
To Fixed Size Converts variable-size output to fixed size.
Variable Size Signal to Workspace Logs the variable signal to workspace.

To Fixed Size

The output ports of the AIE Kernel and AIE Graph blocks are variable-sized (vector) signals. There is a possibility that the kernel does not produce a fixed number of output samples in each simulation step. Many Simulink blocks do not accept variable-size signals as inputs. This this limits leveraging Simulink blocks in designs that use the AIE kernel and AIE Graph blocks.

Model Composer provides the To Fixed Size block which takes a variable-sized vector input and produces a fixed sized vector output.

Figure 1. To Fixed Size

The 'To Fixed Size' block takes a variable-size input signal and produces a fixed-size output signal. There are two available modes for this block:

Stop simulation when input variable-size signal is not full
In this mode, the block stops the simulation and errors out if the input variable-size signal is not full. The output signal is set to the same size as the input signal.
Produce a valid output signal
In this mode, the input buffers until the number of samples reaches the Output Size. The buffered samples are then transferred to the output, and the valid port is set to true. If there are not enough samples buffered, the output is a vector of zeros, and the tool sets the valid port to false.

Variable Size Signal to Workspace

The output ports of AIE Kernel and AIE Graph blocks are variable-sized signals. Model Composer provides a Variable Size Signal to Workspace block in the AI Engine library to easily save the output into a workspace variable in MATLAB. The block saves only the valid samples of the input variable size signal, making analysis of the signal easier.

Figure 2. Variable Size Signal to Workspace

Within the block parameters, the default name for the Variable name is simout.

The Variable Size Signal to Workspace block uses the Simulink To Workspace block under the mask. Therefore, settings that change the behavior of the To Workspace block also impact the Variable Size Signal to Workspace block. You can access block settings from Model Settings (Ctrl-E).

Figure 3. Configuration Parameters

You can set the name of the output (default is out) from the settings window. You can also control whether the To Workspace block outputs the results in a structure called out. Regardless of the checkbox selection or chosen name, this block behaves similarly to the To Workspace block.

If you toggle the Single simulation output check box from Model Settings, press Ctrl-D to refresh the text on the Variable Size Signal to Workspace block.

Important: If a simulation error occurs and you did not select Single simulation output in Model Settings, the block creates an empty variable. This behavior is consistent with the To Workspace block.

Connecting the AI Engine block to source blocks that generate or import signal data (Constant, Signal to Workspace block, and so on) is supported.