
S1C88409 TECHNICAL MANUAL
EPSON
125
CHAPTER 5: PERIPHERAL CIRCUITS AND OPERATION (8-bit Programmable Timer)
5.13.4 Interrupt function
The 8-bit programmable timer can generate an
interrupt by the underflow signal of the counter.
Figure 5.13.4.1 shows the configuration of the 8-bit
programmable timer interrupt circuit.
The underflow signal of the timer sets the inter-
rupt factor flag FTU2 to "1". At that point, the
interrupt is generated. The interrupt can also be
prohibited by setting the interrupt enable register
ETU2.
Furthermore, the priority level of the interrupt for
the CPU can be set to an optional level (0–3) using
the interrupt priority register PTM2.
Refer to Section 5.20, "Interrupt and Standby
Mode", for details of the interrupt control registers
and operations subsequent to interrupt generation.
The exception processing vector address for the 8-
bit programmable timer interrupt is set as follows:
8-bit programmable timer interrupt: 000018H
Data
bus
Interrupt
request
Address
Timer underflow
Interrupt factor flag
FTU2
Address
Interrupt enable
register ETU2
Interrupt priority
level judgment
circuit
Address
Interrupt priority register
PTM20, PTM21
Fig. 5.13.4.1 Configuration of 8-bit programmable timer interrupt circuit
Underflow signal
Underflow signal/2
PTOUT
Clock output
Fig. 5.13.5.1 Clock output waveform
5.13.5 Transfer rate setting for
serial interface
The 8-bit programmable timer can supply the
clock, generated by dividing the underflow of the
counter in 1/2, to the serial interface. The clock
output control register PTOUT controls the clock
output from the 8-bit programmable timer.
Figure 5.13.5.1 shows the output waveform of the
clock.
The transfer rate of the serial interface is decided
by the clock output from the prescaler and the
value set in the reload register.
The output clock is divided by 16 in the serial
interface. Therefore, the setting value of the reload
data register according to the transfer rate can be
calculated with the expression below.
RLD = fOSC3
dr / (32 bps) - 1
RLD: Setting value of the reload register
fOSC3: OSC3 oscillation frequency
bps: Transfer rate
dr:
Prescaler division ratio (1/2 to 1/256)
(00H can be set to RLD)