| Real-Time Workshop® Embedded Coder™ | ![]() |
Set event flags for multirate, multitasking operation before calling model_step for ERT-based Simulink model — not generated as of Version 5.1 (R2008a)
void model_SetEventsForThisBaseStep(boolean_T *eventFlags) void model_SetEventsForThisBaseStep(boolean_T *eventFlags, RT_MODEL_model *model_M)
Pointer to the model's event flags array.
Pointer to the real-time model object. The Real-Time Workshop Embedded Coder software generates this argument only if Generate reusable code is on.
Versions of the Real-Time Workshop Embedded Coder software prior to Version 5.1 (R2008a) generate the model_SetEventsForThisBaseStep function for multirate, multitasking models. The function maintains model event flags that determine which subrate tasks need to run on a given base rate time step. In a multirate, multitasking application, the program code must call model_SetEventsForThisBaseStep before calling the model_step function.
Note The macro MODEL_SETEVENTS, defined in the static ert_main.c module, provides a way to call model_SetEventsForThisBaseStep from a static main program. |
Note Real-Time Workshop Embedded Coder no longer generates the this function and you should avoid using it. The model event flags are now maintained by code in a model's generated example main program (ert_main.c). For more information, see Optimizing Task Scheduling for Multirate Multitasking Models on RTOS Targets. |
model_initialize, model_step, model_terminate
Model Entry Points in the Real-Time Workshop Embedded Coder documentation
![]() | model_initialize | model_step | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |