Timers
16-Bit Timer Setup Examples
Panasonic Semiconductor Development Company MN102H75K/F75K/85K/F85K LSI User Manual
124
Panasonic
TM5CA (example) x’00FE 94’
3. Set the TM5NLD bit of the TM5MD register to 1 and the TM5EN bit to 0.
This enables TM5BC and the S-R flip-flop. This step ensures stable opera-
tion. If it is omitted, the binary counter may not count the first cycle.
4. Set TM5NLD and TM5EN to 1. This starts the timer. Counting begins at the
start of the next cycle.
From this point on, whenever the TM5IC signal is high, timer 5 will be reset
asynchronously. This is an easy way to synchronize the microcontro ller operation
with an external event. You can use it to adjust motor speed or to initialize the
timers through the hardware.
Timer 5 does not operate in STOP mode, when BOSC is off. If you use an external
clock, it must be synchronized to BOSC.
Figure 4-53 shows an example timing chart.
Bit:1514131211109876543210
TM5
CA15 TM5
CA14 TM5
CA13 TM5
CA12 TM5
CA11 TM5
CA10 TM5
CA9 TM5
CA8 TM5
CA7 TM5
CA6 TM5
CA5 TM5
CA4 TM5
CA3 TM5
CA2 TM5
CA1 TM5
CA0
Setting:0001111111111111
Figure 4-53 External Reset Control Timing (Timer 5)
TM5BC
BOSC/4
TM5IC
0000 0001 00030002000100000002 00040003