Epson S1C17624 Technical Manual page 144

Cmos 16-bit single chip microcontroller
Table of Contents

Advertisement

13
16-bit PWM Timers (T16A2)
note: T16A2 is available only in the S1C17624/604.
13.1
T16a2 Module Overview
The S1C17624/604 includes a 16-bit PWM timer (T16A2) module that consists of counter blocks and comparator/
capture blocks. This timer can be used as an interval timer, PWM waveform generator, external event counter and a
count capture unit to measure external event periods.
The features of T16A2 are listed below.
• Two channels of 16-bit up counter blocks
• Two channels of comparator/capture blocks to which a counter block to be connected is selectable
• Allows selection of a count clock asynchronously with the CPU clock.
• Supports event counter function using an external clock.
• The comparator compares the counter value with two specified comparison values to generate interrupts and a
PWM waveform.
• The capture unit captures counter values using two external trigger signals and generates interrupts.
Figure 13.1.1 shows the T16A2 configuration.
Clock controller Ch.0
CLKDIV
/T16A_CLK0
/T16A_CLK0
Divider
IOSC
0
(1/1–1/16384)
Divider
OSC1
1
(1/1–1/256)
Divider
OSC3
2
(1/1–1/16384)
EXCL5
3
CLKSRC
/T16A_CLK0
Clock controller Ch.1
EXCL6
Clock controller
T16A2 includes two channels of clock controllers that generate the count clock for the counters. The clock
source and division ratio can be selected with software.
Counter block
The counter block includes a 16-bit up-counter that operates with an IOSC, OSC3, or OSC1 division clock,
or the external count clock input from outside the IC. The T16A2 module allows software to run and stop the
counter of each channel, and to reset the counter value (cleared to 0) as well as selection of the count clock. The
counter can also be reset by the compare B signal output from the comparator/capture block.
S1C17624/604/622/602/621 TeChniCal Manual
Counter block Ch.0
CLKEN
Counter
Gate
T16A_TC0
HCM, TRMD,
PRESET, PRUN
/T16A_CTL0
Counter block Ch.1
1
0
MULTIMD
/T16A_CLK0
Figure 13.
1.1 T16A2 Configuration
Seiko epson Corporation
Comparator/capture block Ch.0
Compare A/Capture A register
T16A_CCA0
Compare A
buffer
CBUFEN
1
0
/T16A_CTL0
CCABCNT
/T16A_CTL0
Comparator
Compare A
circuit
signal
0
1
Comparator
Compare B
circuit
signal
CBUFEN
1
0
/T16A_CTL0
Compare B
buffer
Compare B/Capture B register
T16A_CCB0
Comparator/capture block Ch.1
0
1
CCABCNT
/T16A_CTL1
13 16-BiT PWM TiMeRS (T16a2)
16-bit PWM timer (T16A2)
T16A_IEN0
Interrupt
Interrupt request
control circuit
T16A_IFLG0
TOUT
TOUTA5
control circuit
TOUTB5
Capture
CAPA5
circuit
CAPB5
T16A_CCCTL0
Interrupt request
TOUTA6
TOUTB6
CAPA6
CAPB6
13-1

Advertisement

Table of Contents
loading

This manual is also suitable for:

S1c17604S1c17622S1c17602S1c17621

Table of Contents