CHAPTER 6 16-BIT TIMER/EVENT COUNTER
143
User’s Manual U11302EJ4V0UM
6.6 16-Bit Timer/Event Counter Operating Precautions
(1) Timer start errors
An error of up to one clock may occur in the time required for a match signal to be generated after timer start.
This is because the 16-bit timer register (TM0) is started asynchronously to the count pulse.
Figure 6-20. 16-Bit Timer Register Start Timing
(2) 16-bit compare register setting
Set the 16-bit compare register (CR00) to a value other than 0000H.
Thus, when using the 16-bit compare register as an event counter, a one-pulse count operation cannot be
carried out.
(3) Operation after compare register change during timer count operation
If the value after the 16-bit compare register (CR00) is changed is smaller than that of the 16-bit timer register
(TM0), TM0 continues counting, overflows and then restarts counting from 0. Thus, if the value after CR00 change
(M) is smaller than that before change (N), it is necessary to restart the timer after changing CR00.
Figure 6-21. Timing After Compare Register Change During Timer Count Operation
Remark
N > X > M
Count pulse
TM0 count value
0000H
Timer start
0001H
0002H
0003H
0004H
Count pulse
CR00 captured value
N
M
TM0 count value
X _ 1
X
FFFFH
0000H
0001H
0002H