Starting And Stopping The Timer; Interval Timer Mode - Renesas RZ/A Series User Manual

Hide thumbs Also See for RZ/A Series:
Table of Contents

Advertisement

RZ/A1L Group, RZ/A1LU Group, RZ/A1LC Group
11.3.4

Starting and Stopping the Timer

The OS timer is started and stopped as follows.
Starting the timer
The timer is started in either of the following way:
• setting the OSTMnTS.OSTMnTSF bit to 1
Status bit OSTMnTE.OSTMnTE is set to 1.
The counter starts to count up or down in accord with the settings for operating mode.
Stopping the timer
Setting the OSTMnTT.OSTMnTT bit to 1 stops the timer.
This also clears the OSTMnTE.OSTMnTE status flag.
11.3.5

Interval Timer Mode

Select the interval timer mode when an OS timer is to be used as a reference timer for generating
interrupt requests at a fixed interval.
11.3.5.1
Basic Operation in Interval Timer Mode
In interval timer mode, the timer counts down from the value specified in the OSTMnCMP register. An
OSTMnTINT interrupt request is generated when the counter reaches 0000 0000
Select interval timer mode by setting OSTMnCTL.OSTMnMD1 = 0.
New values can be written to the OSTMnCMP register at any time. If it is rewritten during count
operation, the counter loads the new OSTMnCMP value when the next 0000 0000
Cycles of OSTMnTINT output
The cycle of OSTMnTINT output is as follows.
• OSTMnTINT generation cycle = counter-clock cycle × (OSTMnCMP + 1)
R01UH0437EJ0600 Rev.6.00
Jan 29, 2021
11. OS Timer
.
H
is reached.
H
11-9

Advertisement

Table of Contents
loading

This manual is also suitable for:

Rz/a1 seriesRz/a1lu seriesRz/a1lc series

Table of Contents