![](http://datasheet.mmic.net.cn/370000/PD78F0138M3GK-A--9ET_datasheet_16728522/PD78F0138M3GK-A--9ET_12.png)
User’s Manual U16228EJ2V0UD
12
5.4.1
5.4.2
5.4.3
5.4.4
5.4.5
X1 oscillator..................................................................................................................................126
Subsystem clock oscillator............................................................................................................126
When subsystem clock is not used...............................................................................................129
Ring-OSC oscillator ......................................................................................................................129
Prescaler.......................................................................................................................................129
5.5 Clock Generator Operation.....................................................................................................130
5.6 Time Required to Switch Between Ring-OSC Clock and X1 Input Clock...........................137
5.7 Time Required for CPU Clock Switchover.............................................................................138
5.8 Clock Switching Flowchart and Register Setting.................................................................139
5.8.1
Switching from Ring-OSC clock to X1 input clock.........................................................................139
5.8.2
Switching from X1 input clock to Ring-OSC clock.........................................................................140
5.8.3
Switching from X1 input clock to subsystem clock........................................................................141
5.8.4
Switching from subsystem clock to X1 input clock........................................................................142
5.8.5
Register settings...........................................................................................................................143
CHAPTER 6 16-BIT TIMER/EVENT COUNTERS 00 AND 01.........................................................144
6.1 Functions of 16-Bit Timer/Event Counters 00 and 01...........................................................144
6.2 Configuration of 16-Bit Timer/Event Counters 00 and 01....................................................145
6.3 Registers Controlling 16-Bit Timer/Event Counters 00 and 01 ...........................................150
6.4 Operation of 16-Bit Timer/Event Counters 00 and 01...........................................................160
6.4.1
Interval timer operation.................................................................................................................160
6.4.2
PPG output operations .................................................................................................................163
6.4.3
Pulse width measurement operations...........................................................................................166
6.4.4
External event counter operation..................................................................................................174
6.4.5
Square-wave output operation......................................................................................................177
6.4.6
One-shot pulse output operation...................................................................................................179
6.5 Cautions for 16-Bit Timer/Event Counters 00 and 01...........................................................184
CHAPTER 7 8-BIT TIMER/EVENT COUNTERS 50 AND 51...........................................................187
7.1 Functions of 8-Bit Timer/Event Counters 50 and 51.............................................................187
7.2 Configuration of 8-Bit Timer/Event Counters 50 and 51......................................................189
7.3 Registers Controlling 8-Bit Timer/Event Counters 50 and 51 .............................................191
7.4 Operations of 8-Bit Timer/Event Counters 50 and 51...........................................................196
7.4.1
Operation as interval timer............................................................................................................196
7.4.2
Operation as external event counter.............................................................................................198
7.4.3
Square-wave output operation......................................................................................................199
7.4.4
PWM output operation..................................................................................................................200
7.5 Cautions for 8-Bit Timer/Event Counters 50 and 51.............................................................204
CHAPTER 8 8-BIT TIMERS H0 AND H1 ..........................................................................................205
8.1 Functions of 8-Bit Timers H0 and H1.....................................................................................205
8.2 Configuration of 8-Bit Timers H0 and H1...............................................................................205
8.3 Registers Controlling 8-Bit Timers H0 and H1......................................................................209
8.4 Operation of 8-Bit Timers H0 and H1 .....................................................................................214
8.4.1
Operation as interval timer/square-wave output ...........................................................................214