NEC V850ES/KE1+ User Manual page 157

32-bit single-chip microcontrollers
Table of Contents

Advertisement

CHAPTER 6 16-BIT TIMER/EVENT COUNTER P (TMP)
(c) Notes on rewriting TP0CCR0 register
To change the value of the TP0CCR0 register to a smaller value, stop counting once and then change the
set value.
If the value of the TP0CCR0 register is rewritten to a smaller value during counting, the 16-bit counter may
overflow.
FFFFH
16-bit counter
0000H
TP0CE bit
TP0CCR0 register
TP0OL0 bit
TOP00 pin output
INTTP0CC0 signal
Remark
Interval time (1): (D
Interval time (NG): (10000H + D
Interval time (2): (D
If the value of the TP0CCR0 register is changed from D
less than D
, the count value is transferred to the CCR0 buffer register as soon as the TP0CCR0 register
1
has been rewritten. Consequently, the value of the 16-bit counter that is compared is D
Because the count value has already exceeded D
overflows, and then counts up again from 0000H. When the count value matches D
signal is generated and the output of the TOP00 pin is inverted.
Therefore, the INTTP0CC0 signal may not be generated at the interval time "(D
+ 1) × Count clock cycle" originally expected, but may be generated at an interval of "(10000H + D
or "(D
2
+ 1) × Count clock cycle".
D
1
D
2
D
1
L
Interval time (1)
Interval time (NG)
+ 1) × Count clock cycle
1
+ 1) × Count clock cycle
2
+ 1) × Count clock cycle
2
2
User's Manual U16896EJ2V0UD
D
1
D
D
2
2
D
2
Interval
time (2)
to D
while the count value is greater than D
1
2
, however, the 16-bit counter counts up to FFFFH,
1
but
2
.
2
, the INTTP0CC0
2
+ 1) × Count clock cycle"
2
157

Advertisement

Table of Contents
loading

This manual is also suitable for:

?pd70f3302?pd703302?pd70f3302y?pd703302y

Table of Contents