Contenido principal

Design Time-Based Simulink Model

Design models for algorithms that depend on time-based scheduling and for which you intend to generate code for an Infineon® AURIX™ microcontroller. These models use a periodic interrupt source such as a hardware timer for timing.

To create and configure a time-based Simulink model:

  1. Create a new blank model.

  2. Configure the model for Infineon AURIX hardware board.

    1. In the Simulink editor, press Ctrl+E or click Modeling > Model Settings to open the Configuration Parameters dialog box.

    2. Select the Hardware Implementation pane and set Hardware board to Infineon AURIX TC3x and the Processing Unit to TriCore0.

      Hardware Implementation pane configuration

    3. Select the Model Referencing pane and set Total number of instances allowed per top model to One.

      Model referencing configuration

  3. Save the model. For example, save as tc3x_ifx_tricore_0.slx.

  4. In the Simulink editor, add the blocks you need for your application. For example, consider these connections.

    TriCore 0 reference model

    For time-based scheduling, you must provide a sample time for the source blocks used in the application model. For example, consider these Pulse Generator block parameter settings.

    Sample time settings for the source block used in time-based model

    You can also group all the blocks into a subsystem and provide sample time for the subsystem. For more information, see Sample Time in Subsystems.

  5. To view and configure the peripheral blocks and their parameters, on the Simulink toolstrip, on the Hardware tab, click Hardware Mapping. For more information, see Map Tasks and Peripherals Using Hardware Mapping.

    Hardware Mapping

See Also

Blocks

Tools

Model Settings

Topics