Operation Of 8-Bit Timer H1; Operation As Interval Timer/Square-Wave Output - NEC 78K0S/KA1+ Preliminary User's Manual

8-bit single-chip microcontrollers
Hide thumbs Also See for 78K0S/KA1+:
Table of Contents

Advertisement

www.DataSheet4U.com
8.4

Operation of 8-Bit Timer H1

8.4.1
When 8-bit timer counter H1 and compare register 01 (CMP01) match, an interrupt request signal (INTTMH1) is
generated and 8-bit timer counter H1 is cleared to 00H.
Compare register 11 (CMP11) is not used in interval timer mode. Since a match of 8-bit timer counter H1 and the
CMP11 register is not detected even if the CMP11 register is set, timer output is not affected.
By setting bit 0 (TOEN1) of timer H mode register 1 (TMHMD1) to 1, a square wave of any frequency (duty = 50%)
is output from TOH1.
(1) Usage
Generates the INTTMH1 signal repeatedly at the same interval.
www.DataSheet4U.com
<1> Set each register.
TMHMD1
<2> Count operation starts when TMHE1 = 1.
<3> When the values of 8-bit timer counter H1 and the CMP01 register match, the INTTMH1 signal is generated
<4> Subsequently, the INTTMH1 signal is generated at the same interval. To stop the count operation, clear

Operation as interval timer/square-wave output

Figure 8-6. Register Setting During Interval Timer/Square-Wave Output Operation
(i)
Setting timer H mode register 1 (TMHMD1)
TMHE1
CKS12
CKS11
0
0/1
0/1
(ii) CMP01 register setting
• Compare value (N)
and 8-bit timer counter H1 is cleared to 00H.
Interval time = (N +1)/f
TMHE1 to 0.
CHAPTER 8 8-BIT TIMER H1
CKS10
TMMD11
TMMD10 TOLEV1
0/1
0
0
CNT
Preliminary User's Manual U16898EJ1V0UD
TOEN1
0/1
0/1
Timer output setting
Timer output level inversion setting
Interval timer mode setting
Count clock (f
CNT
Count operation stopped
) selection
131

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mpd78f9221Mpd78f9222

Table of Contents