FlashFlex51 MCU
SST89E52RD2 / SST89E54RD2 / SST89E58RD2 / SST89E516RD2
SST89V52RD2 / SST89V54RD2 / SST89V58RD2 / SST89V516RD2
Preliminary Specifications
8.0 PROGRAMMABLE COUNTER ARRAY
The Programmable Counter Array (PCA) present on the
SST89E/V5xRD2 is a special 16-bit timer that has five 16-
bit capture/compare modules. Each of the modules can be
programmed to operate in one of four modes: rising and/or
falling edge capture, software timer, high-speed output, or
pulse width modulator. The 5th module can be pro-
grammed as a Watchdog Timer in addition to the other four
modes. Each module has a pin associated with it in port 1.
Module 0 is connected to P1.3 (CEX0), module 1 to P1[4]
(CEX1), module 2 to P1[5] (CEX2), module 3 to P1[6]
(CEX3), and module 4 to P1[7] (CEX4). PCA configuration
is shown in Figure 8-1.
PCA. External events associated with modules are shared
with corresponding Port 1 pins. Modules not using the port
pins can still be used for standard I/O.
Each of the five modules can be programmed in any of the
following modes:
•
•
•
•
•
Rising and/or falling edge capture
Software timer
High speed output
Watchdog Timer (Module 4 only)
Pulse Width Modulator (PWM)
8.2 PCA Timer/Counter
8.1 PCA Overview
The PCA timer is a free-running 16-bit timer consisting of
registers CH and CL (the high and low bytes of the count
values). The PCA timer is common time base for all five
modules and can be programmed to run at: 1/6 the oscilla-
tor frequency, 1/2 the oscillator frequency, Timer 0 overflow,
or the input on the ECI pin (P1.2). The timer/counter source
is determined from the CPS1 and CPS0 bits in the CMOD
SFR as follows (see “PCA Timer/Counter Mode Register
(CMOD)” on page 28):
PCA provides more timing capabilities with less CPU inter-
vention than the standard timer/counter. Its advantages
include reduced software overhead and improved accuracy.
The PCA consists of a dedicated timer/counter which
serves as the time base for an array of five compare/cap-
ture modules. Figure 8-1 shows a block diagram of the
TABLE
8-1: PCA TIMER/COUNTER SOURCE
CPS1
CPS0
12 Clock Mode
6 Clock Mode
fOSC /6
0
0
1
1
0
1
0
1
fOSC /12
fOSC /4
fOSC /2
Timer 0 overflow
Timer 0 overflow
External clock at ECI pin
(maximum rate = fOSC /8)
External clock at ECI pin
(maximum rate = fOSC /4)
T8-1.0 1255
16 Bits Each
Module 0
P1.3/CEX0
P1.4/CEX1
P1.5/CEX2
P1.6/CEX3
Module 1
Module 2
Module 3
Module 4
16 Bits
PCA Timer/Counter
P1.7/CEX4
1255 F23.0
FIGURE
8-1: PCA TIMER/COUNTER AND COMPARE/CAPTURE MODULES
©2004 Silicon Storage Technology, Inc.
S71255-00-000
3/04
51