Real-Time Windows Target |
 |
Entering Simulation Parameters for Simulink
The simulation parameters give information to Simulink for running a simulation.
After you create a Simulink model, you can enter the simulation parameters for Simulink. This procedure uses the Simulink model rtwin_model.mdl
as an example and assumes you have already loaded that model:
- In the Simulink window, and from the Simulation menu, click Parameters. In the Simulation Parameters dialog box, click the Solver tab.
The Solver page opens.
- In the Start time box, enter
0.0
. In the Stop time box, enter the amount of time you want your model to run. For example, enter 10.0
seconds.
- From the Type list, choose Fixed-step. Real-Time Workshop does not support variable step solvers.
- From the integration algorithm list, choose a solver. For example, choose the general purpose solver ode5 (Dormand-Prince).
- In the Fixed step size box, enter a sample time. For example, enter
0.001
second for a sample rate of 1000
samples/second.
- From the Mode list, choose SingleTasking. For models with blocks that have different sample times, choose MultiTasking.
Your Solver page will look similar to the figure shown below.

- Do one of the following:
- Click Apply to apply the changes to your model and leave the dialog box open.
- Click OK to apply the changes to your model and close the Simulation Parameters dialog box.
| Creating a Simulink Model | | Entering Scope Properties for Signal Tracing |  |