AT89C51CC03
Figure 69. PCA Capture Mode
CEXn
n = 0, 4
PCA Counter
CH CL
(8bits) (8bits)
CCFn
CCON
CCAPnH CCAPnL
PCA
Interrupt
Request
CAPMnECOMn CAPPn CAPNn MATn TOGn PWMn ECCFn
7
0
CCAPMn Register (n = 0, 4)
16-bit Software Timer
Mode
The PCA modules can be used as software timers by setting both the ECOM and MAT
bits in the modules CCAPMn register. The PCA timer will be compared to the module’s
capture registers and when a match occurs an interrupt will occur if the CCFn (CCON
SFR) and the ECCFn (CCAPMn SFR) bits for the module are both set.
Figure 70. PCA 16-bit Software Timer and High Speed Output Mode
PCA Counter
CH
CL
(8 bits) (8 bits)
Compare/Capture Module
CCAPnH CCAPnL
(8 bits)
(8 bits)
Match
16-Bit Comparator
Enable
Toggle
CCFn
CCON reg
CEXn
PCA
Interrupt
Request
“0”
Reset
Write to
CCAPnL
“1”
Write to CCAPnH
CAPMn ECOMn CAPPn
7
0
CAPNn MATn TOGn
CCAPMn Register
(n = 0, 4)
PWMn ECCFn
For software Timer mode, set ECOMn and MATn.
For high speed output mode, set ECOMn, MATn and TOGn.
4182K–CAN–05/06
145