Datasheet

Index-3
4.3.4 Port input mode register (PIM1) ..................................................................................................... 109
4.3.5 Port output mode register (POM1) ................................................................................................. 109
4.3.6 Port mode control registers (PMCxx) ............................................................................................. 110
4.3.7 A/D port configuration register (ADPC) .......................................................................................... 111
4.3.8 Peripheral I/O redirection register (PIOR)....................................................................................... 112
4.3.9 LCD port function registers 0 to 4 (PFSEG0 to PFSEG4) .............................................................. 113
4.3.10 LCD input switch control register (ISCLCD) ................................................................................. 115
4.4 Port Function Operations .......................................................................................................... 116
4.4.1 Writing to I/O port ........................................................................................................................... 116
4.4.2 Reading from I/O port ..................................................................................................................... 116
4.4.3 Operations on I/O port .................................................................................................................... 116
4.4.4 Connecting to external device with different potential (1.8 V, 2.5 V, 3 V) ....................................... 117
4.4.5 Handling different potential (1.8 V, 2.5 V, 3 V) by using I/O buffers ............................................... 117
4.5 Register Settings When Using Alternate Function ................................................................. 119
4.5.1 Basic concept when using alternate function .................................................................................. 119
4.5.2 Register settings for alternate function whose output function is not used ..................................... 120
4.5.3 Register setting examples for used port and alternate functions .................................................... 121
4.6 Cautions When Using Port Function ........................................................................................ 128
4.6.1 Cautions on 1-Bit Manipulation Instruction for Port Register n (Pn) ............................................... 128
4.6.2 Notes on specifying the pin settings ............................................................................................... 129
CHAPTER 5 CLOCK GENERATOR .................................................................................................... 130
5.1 Functions of Clock Generator ................................................................................................... 130
5.2 Configuration of Clock Generator ............................................................................................ 132
5.3 Registers Controlling Clock Generator .................................................................................... 134
5.3.1 Clock operation mode control register (CMC) ................................................................................ 134
5.3.2 System clock control register (CKC) ............................................................................................... 137
5.3.3 Clock operation status control register (CSC) ................................................................................ 138
5.3.4 Oscillation stabilization time counter status register (OSTC) .......................................................... 139
5.3.5 Oscillation stabilization time select register (OSTS) ....................................................................... 141
5.3.6 Peripheral enable register 0 (PER0) ............................................................................................... 143
5.3.7 Subsystem clock supply mode control register (OSMC) ................................................................ 145
5.3.8 High-speed on-chip oscillator frequency select register (HOCODIV) ............................................. 146
5.3.9 High-speed on-chip oscillator trimming register (HIOTRM) ............................................................ 147
5.4 System Clock Oscillator ............................................................................................................ 148
5.4.1 X1 oscillator .................................................................................................................................... 148
5.4.2 XT1 oscillator .................................................................................................................................. 148
5.4.3 High-speed on-chip oscillator ......................................................................................................... 152
5.4.4 Low-speed on-chip oscillator .......................................................................................................... 152
5.5 Clock Generator Operation ....................................................................................................... 153
5.6 Controlling Clock ........................................................................................................................ 155