Main Content

Generate Component and Test Bench

  1. If you have not yet done so, finish selecting the TLM generation options and click OK to save your changes and exit the TLM Generation options panes.

  2. Generate code. Select one of the following ways:

    • Press Ctrl-B (full model).

    • Right-click the subsystem and select C/C++ Code > Build This Subsystem.

    • In the Simulink® toolstrip, select the C Code tab, and click Generate Code (this option builds the full model).


    Generate the component and test bench on the architecture you plan to use for running the SystemC simulation.

  3. Go to Run TLM Component Test Bench (optional).

For more about using the generated TLM component, see Export TLM Component.