English
Language : 

W78ERD2 Datasheet, PDF (47/72 Pages) Winbond – 8-BIT MICROCONTROLLER
W78ERD2
11.3 High Speed Output Mode
In this mode the CEX output (on port1) associated with the PCA module will toggle each time a match
occurs between the PCA counter and the module’s capture registers. To activate this mode the TOG,
MAT, and ECOM(CCAPMn) bits must be set.
Write To
CCAPnL
0
CF
CR
-
CCF4 CCF3 CCF2 CCF1 CCF0 CCON(D8H)
CCAPnH CCAPnL
Write To
CCAPnH
16-bit Comparator
1
Enable
Match
CH
CL
PCA Timer/Counter
To CCFn
-
ECOMn CAPPn CAPNn MATn TOGn PWMn ECCFn
0
0
1
0
PCA INTERRUPT
CEXn
CCAPMn, n=0~4
(DAH~DEH)
PCA High Speed Output Mode
11.4 Pulse Width Modulator Mode
All of the PCA modules can be use as PWM outputs. The frequency of the output depends on the
source for the PCA timer. All of the modules will have the same frequency of output because they all
share the PCA timer. The duty cycle of each module is independently variable using the module’s
capture register CCAPLn When the value of the PCA CL SFR is less than the value in the module’s
CCAPLn SFR the output will be low, when it is equal to or greater than the output will be high. When
CL overflows from FF to 00, CCAPLn is reloaded with the value in CCApHn. This allows updating the
PWM with out glitches. The PWM and ECOM(CCAPM) bits must be set to enable the PWM mode.
CCAPnH
CCAPnL
Enable
8-BIT
COMPARATOR
0
CL < CCAPnL
CL >= CCAPnL
1
CEXn
Overflow CL
PCA Timer/Counter
-
ECOMn CAPPn CAPNn MATn TOGn PWMn ECCFn
CCAPMn, n=0~4
(DAH~DEH)
0
0
0
0
0
PAC PWM Mode
- 47 -
Publication Release Date: April 20, 2005
Revision A4