Chapter 8
8-bit Timer
VIII - 28 8-bit PWM Output
8.6.3 PWM Output With Additional Pulse (Timer 0, Timer 2, Timer 4)
PWM Output with Additional Pulse Method
In this method, a pulse, whose period equals to one count clock period, can be added on a PWM basic waveform.
Up to 3 pulses can be added in 4 cycles of the basic PWM waveform.
Where to place, or not to place additional pulses during 4 cycles of the basic PWM waveform is controlled by set-
ting CKnMD.TMnADD1-0.
Figure:8.6.5 shows the setting value of CKnMD.TMnADD1-0 and the location of additional pulses.
Figure:8.6.5 Count timing of PWM Output with Additional Pulses Method
..
An interrupt occurs at the 4th cycle of the PWM basic waveform.
..
KnMD.TMnADD1-0
"00"
No additional pulse
KnMD.TMnADD1-0
"11"
KnMD.TMnADD1-0
"01"
KnMD.TMnADD1-0
"10"
Interrupt request
PWM basic waveform (4 cycles)
additional pulse
additional pulse
additional pulse(PWM basic waveform 1/256 pulse width
During 4 cycles of the PWM basic waveform, additional pulses (1/256 pulse width of PWM basic waveform
can be added in any of the cycles 0 to 3.
PWM basic waveform
8bit 256 resolution