NEC UPD703116 User Manual page 224

32-bit single-chip microcontrollers
Table of Contents

Advertisement

(5) Compare registers 003, 013 (CM003, CM013)
CM0n3 is a 16-bit register that always compare its value with the value of TM0n. If the values match, CM0n3
outputs an interrupt signal (INTCM0n3). CM0n3 controls the maximum count value of TM0n, and if the values
match, it performs the following operations at the next timer count clock.
In triangular wave setting mode (PWM modes 0, 1):
Sawtooth wave setting mode (PWM mode 2):
CM0n3 also has a buffer register (BFCMn3) and transfers the buffer contents at the timing of the next transfer
to CM0n3. Transfer enable or disable is controlled by the BFTE3 bit of the TMC0n register.
(6) Buffer registers CM00 to CM02, CM10 to CM12 (BFCM00 to BFCM02, BFCM10 to BFCM12)
BFCMn0 to BFCMn2 are 16-bit registers that transfer data to the compare register (CM0n0 to CM0n2)
corresponding to each buffer register when an interrupt signal (INTCM0n3/INTTM0n) is generated.
BFCMn0 to BFCMn2 can be read/written in 16-bit units.
Caution The set values of the BFCMn0 to BFCMn2 registers are transferred to the CM0n0 to CM0n2
registers in the following timing (n = 0, 1).
• When TM0CEn bit of TMC0n register = 0: Transfer at next operation timing after writing to
BFCMn0 to BFCMn2 registers
• When TM0CEn bit of TMC0n register = 1: Value of BFCMn0 to BFCMn2 registers is
transferred to CM0n0 to CM0n2 registers upon occurrence of INTTM0n or INTCM0n3. At
this time, transfer enable or disable is controlled by the BFTEN bit of the timer control
register (TMC0n).
15
14
13
BFCM00
15
14
13
BFCM10
15
14
13
BFCM01
15
14
13
BFCM11
15
14
13
BFCM02
15
14
13
BFCM12
224
CHAPTER 9 TIMER/COUNTER FUNCTION
12
11
10
9
8
7
12
11
10
9
8
7
12
11
10
9
8
7
12
11
10
9
8
7
12
11
10
9
8
7
12
11
10
9
8
7
User's Manual U14492EJ5V0UD
Switches TM0n operation from up count to down
count
Clears the count value of TM0n
6
5
4
3
2
1
6
5
4
3
2
1
6
5
4
3
2
1
6
5
4
3
2
1
6
5
4
3
2
1
6
5
4
3
2
1
0
Address
Initial value
FFFFF572H
FFFFH
0
Address
Initial value
FFFFF5B2H
FFFFH
0
Address
Initial value
FFFFF574H
FFFFH
0
Address
Initial value
FFFFF5B4H
FFFFH
0
Address
Initial value
FFFFF576H
FFFFH
0
Address
Initial value
FFFFF5B6H
FFFFH

Advertisement

Table of Contents
loading

Table of Contents