Hallo Andi,

siehe Seite 230 des C164 Manuals.

CC24 bis 27 sind nur für Capture, d.h. für Input zuständig.
Output (PWM) geht über CC16-19.
Dann geht es einwandfrei ))

Bernhard

Hier ein kleiner Beispielscode:
//PWM Output für Motortreiber konfigurieren
_putbit(1,DP8,0); //CC16IO MC0_IN1 auf Output
_bfld(CCM4, 0x0000F, 0x00007); //CC16 an T7 haengen, Compare Mode 3 kein Interrupt
CC16 = 64500;

_putbit(1,DP8,2); //CC18IO MC1_IN1 auf Output
_bfld(CCM4, 0x00F00, 0x00700); //CC18 an T7 haengen, Compare Mode 3 kein Interrupt
CC18 = 64500;

_putbit(1,DP8,3); //CC19IO MC1_IN1 auf Output
_bfld(CCM4, 0x0F000, 0x07000); //CC19 an T7 haengen, Compare Mode 3 kein Interrupt
CC19 = 64500;



Each capture/compare register may be programmed individually for capture or compare function,
and each register may be allocated to either timer. Each capture/compare register has one port pin
associated with it which serves as an input pin for the capture function or as an output pin for the
compare function (except for CC27...CC24, which only provide the capture function). The capture
function causes the current timer contents to be latched into the respective capture/compare
register triggered by an event (transition) on its associated port pin. The compare function may
cause an output signal transition on that port pin whose associated capture/compare register
matches the current timer contents. Specific interrupt requests are generated upon each capture/
compare event or upon timer overflow.