What is Sample Time and How Does it Work?
What is Sample Time?
The sample time determines how often a block updates and produces outputs during simulation.
How Does Sample Time Work for Renesas RA
For Renesas® RA Microcontrollers, you can configure the sample time for each block in your Simulink model. This allows you to implement both single-rate (all blocks run at the same interval) and multi-rate (blocks run at different intervals) designs.
Single-rate modeling: All blocks execute at the same, user-defined rate.
Multi-rate modeling: Different blocks can have different sample times, and the generated code automatically manages the scheduling.
The actual execution rates are determined by the sample times you specify in your model and are implemented using hardware timers on the microcontroller.
You can view and verify sample times in your Simulink model by enabling sample time colors or annotations.