Treat each discrete rate as a separate task
Option to enable multitasking execution
Model Configuration Pane: Solver
Specify whether the software executes blocks with periodic sample times individually or in groups.
To use this parameter, clear the Use local solver when referencing model parameter.
A model with multiple tasks cannot reference a multirate model that uses single tasking mode.
To enable this parameter, set the solver Type to
All blocks are processed through each stage of simulation together (for example, calculating output and updating discrete states). Use single-tasking execution if:
Your model contains one sample time.
Your model contains a continuous and a discrete sample time, and the fixed step size is equal to the discrete sample time.
Groups of blocks with the same execution priority are processed through each stage of simulation based on task priority. The multitasking mode helps to create valid models of real-world multitasking systems, where sections of your model represent independent tasks.
Use the Single task data transfer and Multitask data transfer parameters to control the diagnostic behavior for sample rate transitions between blocks that have different sample times.
The table summarizes recommended values for this parameter based on considerations related to code generation.
No impact for simulation or during development
Off for production code generation
|Type: string | character vector|
Introduced in R2016b
- Time-Based Scheduling (Simulink Coder)
- Model Execution and Rate Transitions (Simulink Coder)
- Handle Rate Transitions (Simulink Coder)
- Solver Pane