Panasonic MN103001G/F01K User Manual page 252

Panax series microcomputer
Table of Contents

Advertisement

8-bit Timers
Once the counting operation is enabled, the PWM waveform is output and an underflow interrupt request is generated.
(Refer to Fig. 10-6-8 and 10-6-9.)
If the value in the TMnBR register is changed while the counting operation is in progress, that value is loaded as the
initial value when the next underflow is generated, and the cycle of the PWM waveform changes.
If the value in the TMnCMP register is changed while the counting operation is in progress, that value is loaded into
the compare register when the next underflow is generated, and the duty ratio of the PWM waveform changes.
Procedure for ending operation
(1) Stop the timer counting operation.
Set TMnCNE to "0" in the TMnMD register, stopping the counting operation.
(2) Initialize the timer, if necessary.
If TMnLDE is set to "1" in the TMnMD register, the timer is initialized.
The value set in TMnBR is loaded into TMnBC as the initial value.
The value in the compare register buffer is loaded into the TMnCMP register.
PWM output is initialized.
If only the timer is stopped and "1" is not written to TMnLDE, the status of the binary counter is maintained as
it was before the counting operation was stopped. If TMnCNE is set to "1", the count resumes from the state
that was in effect immediately before the counting operation was stopped.
10-32

Advertisement

Table of Contents
loading

Table of Contents