TMP91C824
91C824-92
(3) Timer registers (TA0REG and TA1REG)
These are 8-bit registers which can be used to set a time interval. When the value set in the timer
register TA0REG or TA1REG matches the value in the corresponding up-counter, the Comparator
Match Detect signal goes Active. If the value set in the timer register is 00H, the signal goes Active
when the up-counter overflows.
The TA0REG are double buffer structure, each of which makes a pair with register buffer.
The setting of the bit TA01RUN<TA0RDE> determines whether TA0REG’s double buffer
structure is enabled or disabled. It is disabled if <TA0RDE> = “0” and enabled if <TA0RDE> = “1”.
When the double buffer is enabled, data is transferred from the register buffer to the timer register
when a 2
n
−
1 overflow occurs in PWM Mode, or at the start of the PPG cycle in PPG Mode. Hence
the double buffer cannot be used in Timer Mode.
A Reset initializes <TA0RDE> to “0”, disabling the double buffer. To use the double buffer, write
data to the timer register, set <TA0RDE> to “1”, and write the following data to the register buffer.
Figure 3.7.3 show the configuration of TA0REG.
Selector
Y
S
A
B
Write
Shift trigger
Write to TA0REG
2
n
-1 overflow of PWM
TA01RUN<TA0RDE>
Up-counter
Comparator (CP0)
Timer Registers 0 (TA0REG)
Register Buffers 0
Internal bus
Matching detection in PPG cycle
Figure 3.7.3 Configuration of TA0REG
(note): The same memory address is allocated to the timer register and the register buffer. When <TA0RDE>
= 0, the same value is written to the register buffer and the timer register; when <TA0RDE> = 1, only
the register buffer is written to.
The address of each timer register is as follows.
TA0REG: 000102H
TA1REG: 000103H
TA2REG: 00010AH
TA3REG: 00010BH
All these registers are write only and cannot be read.