DF2117VT20HV Renesas Electronics America, DF2117VT20HV Datasheet
DF2117VT20HV
Specifications of DF2117VT20HV
Available stocks
Related parts for DF2117VT20HV
DF2117VT20HV Summary of contents
Page 1
To our customers, Old Company Name in Catalogs and Other Documents st On April 1 , 2010, NEC Electronics Corporation merged with Renesas Technology Corporation, and Renesas Electronics Corporation took over all the business of both companies. Therefore, although the ...
Page 2
All information included in this document is current as of the date this document is issued. Such information, however, is subject to change without any prior notice. Before purchasing or using any Renesas Electronics products listed herein, please confirm ...
Page 3
The revision list can be viewed directly by clicking the title page. The revision list summarizes the locations of revisions and additions. Details should always be checked by referring to the relevant text. H8S/2117R Group 16 Hardware Manual Renesas 16-Bit ...
Page 4
This document is provided for reference purposes only so that Renesas customers may select the appropriate Renesas products for their use. Renesas neither makes warranties or representations with respect to the accuracy or completeness of the information contained in ...
Page 5
General Precautions in the Handling of MPU/MCU Products The following usage notes are applicable to all MPU/MCU products from Renesas. For detailed usage notes on the products covered by this manual, refer to the relevant sections of the manual. If ...
Page 6
Rev. 2.00 Sep. 28, 2009 Page REJ09B0452-0200 ...
Page 7
Objective and Target Users This manual was written to explain the hardware functions and electrical characteristics of this LSI to the target users, i.e. those who will be using this LSI in the design of application systems. Target users ...
Page 8
Description of Numbers and Symbols Aspects of the notations for register names, bit names, numbers, and symbolic names in this manual are explained below. (1) Overall notation In descriptions involving the names of bits and bit fields within this ...
Page 9
Description of Registers Each register description includes a bit chart, illustrating the arrangement of bits, and a table of bits, describing the meanings of the bit settings. The standard format and notation for bit charts and tables are described ...
Page 10
Description of Abbreviations The abbreviations used in this manual are listed below. • Abbreviations specific to this product Abbreviation Description BSC Bus controller CPG Clock pulse generator INT Interrupt controller SCI Serial communication interface TMR 8-bit timer TPU 16-bit ...
Page 11
Main Revisions for This Edition Item Page 2.4.3 Extended Control 39 Register (EXR) 2.4.4 Condition-Code 40 Register (CCR) 7.2.15 Port F 178 (1) PF7/PWMU5A, PF6/PWMU4A, PF5/PWMU3A, PF4/PWMU2A 7.2.19 Port J 189 Table 7.4 Available Output Signals and Settings in Each ...
Page 12
Item Page 8.4.2 Pulse Division 215 Mode Figure 8.8 Example of Additional Pulse Timing (Upper 4 Bits in PWMREG = B'1000) Figure 8.9 Example of 216 WMU Setting 10.3.3 Timer I/O 253 Control Register (TIOR) Table 10.13 TIORL_0 (channel 0) ...
Page 13
Item Page 15.1 Features 403 Figure 15.1 Block Diagram of SCI 15.3 Register 406 Descriptions Table 15.2 Register Configuration 15.4.6 Serial Data 433 Reception (Asynchronous Mode) Figure 15.9 Sample Serial Reception Flowchart (1) 15.5.1 Multiprocessor 437 Serial Data Transmission Figure ...
Page 14
Item Page 15.6.3 Serial Data 444 Transmission (Clocked Synchronous Mode) Figure 15.17 Sample Serial Transmission Flowchart 15.6.4 Serial Data 446 Reception (Clocked Synchronous Mode) Figure 15.19 Sample Serial Reception Flowchart 15.6.5 Simultaneous 448 Serial Data Transmission and Reception (Clocked Synchronous ...
Page 15
Item Page 17.3.8 FIFO Control 502 Register (FFCR) 17.4.4 Data 519 Transmission/Reception with Flow Control Figure 17.6 Example of Initialization Flowchart Figure 17.10 Example 523 of Data Reception Flowchart 17.6.2 FLCR Access 528 During Serial Transmission and Reception Revision (See ...
Page 16
Item Page 18.4.5 Slave Receive 573 Operation Figure 18.15 Example of Slave Receive Mode Operation Timing (2) (MLS = 0) 19.3.2 Keyboard Buffer 593 Control Register 2 (KBCR2) 19.3.6 Keyboard Buffer 598 Transmit Data Register (KBTR) 19.4.1 Receive 565 Operation ...
Page 17
Item Page 20.1 Features 616 Figure 20.1 Block Diagram of LPC 20.3 Register 619 Descriptions Table 20.2 Register Configuration 20.3.1 Host Interface 625 Control Registers 0 and 1 (HICR0 and HICR1) • HICR1 20.3.2 Host Interface 627 Control Registers 2 ...
Page 18
Item Page 20.3.11 Bidirectional 638 Data Registers (TWR0 to TWR15) 20.3.12 Status 644 Registers (STR1 to STR4) • STR4 21.4.5 FSI Memory 716 Cycle (LPC-SPI Command Transfer) Figure 21.13 FSI Command Read (Example) 21.5 ...
Page 19
Item Page 22.4.3 Input Sampling 738 and A/D Conversion Time Table 22.5 A/D Conversion Time (Scan Mode) 22.7.2 Permissible 741 Signal Source Impedance Figure 22.5 Example of Analog Input Circuit 22.7.6 Notes on Noise 743 Countermeasures Figure 22.6 Example of ...
Page 20
Item Page 24.1 Features 749 24.2 Mode Transition 751 Diagram Table 24.1 Differences between Boot Mode, User Program Mode, and Programmer Mode 752 Rev. 2.00 Sep. 28, 2009 Page xviii of xl REJ09B0452-0200 Revision (See Manual for Details) Description amended ...
Page 21
Item Page 24.5 754 Programming/Erasing Interface 24.7.1 763 Programming/Erasing Interface Registers (5) Flash MAT Select Register (FMATS) 24.8.4 Storable Areas 793 for On-Chip Program and Program Data Table 24.10 Usable 794 Area for Programming in User Program Mode Revision (See ...
Page 22
Item Page 24.8.4 Storable Areas 795 for On-Chip Program and Program Data Table 24.11 Usable Area for Erasure in User Program Mode Table 24.12 Usable 796 Area for Programming in User Boot Mode Table 24.13 Usable 797 Area for Erasure ...
Page 23
Item Page 24.12 Standard Serial 803 Communication Interface Specifications for Boot Mode Figure 24.18 Boot Program States (3) Inquiry and Selection 811 States (f) Operating Clock Frequency Inquiry (8) Programming/Erasing 823 State 3. Programming/Erasing State Information (c) 128-Byte Programming (f) ...
Page 24
Item Page 27.1 Register 863 Addresses (Address Order) 28.2 DC Characteristics 958 Table 28.2 DC Characteristics (1) Table 28.2 DC 961 Characteristics (4) Using FSI Function 28.3.2 Control Signal 967 Timing Figure 28.8 Interrupt Input Timing All trademarks and registered ...
Page 25
Section 1 Overview..................................................................................................1 1.1 Features.................................................................................................................................. 1 1.1.1 Applications .............................................................................................................. 1 1.1.2 Overview of Functions.............................................................................................. 2 1.2 List of Products ...................................................................................................................... 7 1.3 Block Diagram ....................................................................................................................... 8 1.4 Pin Descriptions ..................................................................................................................... 9 1.4.1 Pin Assignments ....................................................................................................... 9 1.4.2 Pin Assignment in ...
Page 26
Register Indirect with Displacement⎯@(d:16, ERn) or @(d:32, ERn)................. 58 2.7.4 Register Indirect with Post-Increment or Pre-Decrement⎯@ERn+ or @-ERn..... 58 2.7.5 Absolute Address⎯@aa:8, @aa:16, @aa:24, or @aa:32....................................... 58 2.7.6 Immediate⎯#xx:8, #xx:16, or #xx:32.................................................................... 59 2.7.7 Program-Counter Relative⎯@(d:8, PC) or @(d:16, ...
Page 27
Address Break Control Register (ABRKCR) ......................................................... 91 5.3.3 Break Address Registers (BARA to BARC) ............................................... 92 5.3.4 IRQ Sense Control Registers (ISCR16H, ISCR16L, ISCRH, ISCRL) ................... 93 5.3.5 IRQ Enable Registers (IER16, IER) ....................................................................... 96 5.3.6 ...
Page 28
Section 7 I/O Ports...............................................................................................135 7.1 Register Descriptions ......................................................................................................... 143 7.1.1 Data Direction Register (PnDDR and ............... 144 7.1.2 Data Register (PnDR ...
Page 29
Section 8 8-Bit PWM Timer (PWMU)................................................................197 8.1 Features.............................................................................................................................. 197 8.2 Input/Output Pins ............................................................................................................... 199 8.3 Register Descriptions ......................................................................................................... 200 8.3.1 PWM Control Register A (PWMCONA) ............................................................. 202 8.3.2 PWM Control Register B (PWMCONB).............................................................. 202 8.3.3 PWM Control Register C (PWMCONC).............................................................. ...
Page 30
Timer Counter (TCNT)......................................................................................... 263 10.3.7 Timer General Register (TGR) ............................................................................. 263 10.3.8 Timer Start Register (TSTR) ................................................................................ 263 10.3.9 Timer Synchro Register (TSYR) .......................................................................... 264 10.4 Interface to Bus Master...................................................................................................... 265 10.4.1 16-Bit Registers .................................................................................................... 265 10.4.2 8-Bit Registers ...
Page 31
TCM Cycle Lower Limit Register (TCMMINCM) .............................................. 310 11.3.4 TCM Input Capture Register (TCMICR).............................................................. 310 11.3.5 TCM Input Capture Buffer Register (TCMICRF) ................................................ 310 11.3.6 TCM Status Register (TCMCSR) ......................................................................... 311 11.3.7 TCM Control Register (TCMCR)......................................................................... 313 11.3.8 TCM ...
Page 32
Usage Notes ....................................................................................................................... 351 12.6.1 Conflict between TDPCNT Write and Count-Up Operation ................................ 351 12.6.2 Conflict between TDPPDMX Write and Compare Match.................................... 351 12.6.3 Conflict between Input Capture and TDPICR Read ............................................. 352 12.6.4 Conflict between Edge Detection in ...
Page 33
Input Capture Operation ....................................................................................... 382 13.8 Interrupt Sources................................................................................................................ 384 13.9 Usage Notes ....................................................................................................................... 385 13.9.1 Conflict between TCNT Write and Counter Clear................................................ 385 13.9.2 Conflict between TCNT Write and Count-Up ...................................................... 385 13.9.3 Conflict between TCOR Write and Compare-Match............................................ ...
Page 34
Bit Rate Register (BRR) ....................................................................................... 419 15.4 Operation in Asynchronous Mode ..................................................................................... 424 15.4.1 Data Transfer Format............................................................................................ 425 15.4.2 Receive Data Sampling Timing and Reception Margin in Asynchronous Mode............................................................................................. 426 15.4.3 Clock..................................................................................................................... 427 15.4.4 SCI Initialization (Asynchronous Mode).............................................................. 428 ...
Page 35
Note on Writing to Registers in Transmission, Reception, and Simultaneous Transmission and Reception .......................................................... 467 Section 16 CIR Interface......................................................................................469 16.1 Features.............................................................................................................................. 469 16.2 Input Pins ........................................................................................................................... 471 16.3 Register Description........................................................................................................... 471 16.3.1 Receive Control Register 1 (CCR1)...................................................................... 472 16.3.2 ...
Page 36
Interrupt Identification Register (FIIR)................................................................. 500 17.3.8 FIFO Control Register (FFCR)............................................................................. 502 17.3.9 Line Control Register (FLCR) .............................................................................. 503 17.3.10 Modem Control Register (FMCR)........................................................................ 504 17.3.11 Line Status Register (FLSR)................................................................................. 506 17.3.12 Modem Status Register (FMSR)........................................................................... 510 17.3.13 Scratch Pad ...
Page 37
Initialization of Internal State ............................................................................... 579 18.5 Interrupt Sources................................................................................................................ 581 18.6 Usage Notes ....................................................................................................................... 582 18.6.1 Module Stop Mode Setting ................................................................................... 585 Section 19 Keyboard Buffer Control Unit (PS2).................................................587 19.1 Features.............................................................................................................................. 587 19.2 Input/Output Pins ............................................................................................................... 589 19.3 Register ...
Page 38
Host Interface Control Register 5 (HICR5) .......................................................... 630 20.3.5 LPC Channel 1 Address Registers H and L (LADR1H and LADR1L)................ 631 20.3.6 LPC Channel 2 Address Registers H and L (LADR2H and LADR2L)................ 632 20.3.7 LPC Channel 3 Address ...
Page 39
FSI Program Instruction Register (FSIPPINS) ..................................................... 691 21.3.7 FSI Status Register (FSISTR) ............................................................................... 691 21.3.8 FSI Transmit Data Registers (FSITDR0 to FSITDR7)............................... 693 21.3.9 FSI Receive Data Register (FSIRDR)................................................................... 693 21.3.10 FSI Access Host Base Address ...
Page 40
Interrupt Source ................................................................................................................. 739 22.6 A/D Conversion Accuracy Definitions .............................................................................. 739 22.7 Usage Notes ....................................................................................................................... 741 22.7.1 Module Stop Mode Setting ................................................................................... 741 22.7.2 Permissible Signal Source Impedance .................................................................. 741 22.7.3 Influences on Absolute Accuracy ......................................................................... 742 22.7.4 Setting ...
Page 41
Connecting Crystal Resonator .............................................................................. 834 25.1.2 External Clock Input Method................................................................................ 835 25.2 Duty Correction Circuit ..................................................................................................... 838 25.3 Subclock Input Circuit ....................................................................................................... 838 25.4 Subclock Waveform Forming Circuit ................................................................................ 839 25.5 Clock Select Circuit ........................................................................................................... 839 25.6 Usage Notes ...
Page 42
A/D Conversion Characteristics......................................................................................... 979 28.5 Flash Memory Characteristics ........................................................................................... 980 28.6 Usage Notes ....................................................................................................................... 981 Appendix .........................................................................................................983 A. I/O Port States in Each Pin State........................................................................................ 983 B. Product Lineup................................................................................................................... 984 C. Package Dimensions .......................................................................................................... 985 D. Treatment of Unused ...
Page 43
Features The core of each product in the H8S/2117R Group of CISC (complex instruction set computer) microcomputers is an H8S/2600 CPU, which has an internal 16-bit architecture. The H8S/2600 CPU provides upward-compatibility with the CPUs of other Renesas Technology-original ...
Page 44
Overview of Functions Table 1.1 lists the functions of this LSI in outline. Table 1.1 Overview of Functions Module/ Classification Function Memory ROM RAM CPU CPU Operating mode Rev. 2.00 Sep. 28, 2009 Page 2 of 994 REJ09B0452-0200 Description ...
Page 45
Module/ Function Classification CPU MCU operating mode Interrupt Interrupt (source) controller Clock Clock pulse generator (CPG) A/D converter A/D converter (ADC) Description Mode 2: Single-chip mode (selected by driving the MD2 and MD0 pins low and MD1 pin high) Mode ...
Page 46
Module/ Function Classification Timer 8-bit PWM timer (PWMU) 14-bit PWM timer (PWMX) 16-bit timer pulse unit (TPU) 16-bit cycle measurem- ent timer (TCM) 16-bit duty period measurem- ent timer (TDP) Rev. 2.00 Sep. 28, 2009 Page 4 of 994 REJ09B0452-0200 ...
Page 47
Module/ Function Classification Timer 8-bit timer (TMR) Watchdog timer Watchdog timer (WDT) Serial interface Serial communi- cation interface with FIFO (SCIF) Serial communi- cation interface (SCI) Smart card/ SIM 2 High bus performance interface communication (IIC) Keyboard buffer ...
Page 48
Module/ Function Classification High- FSI performance interface communication (FSI) CIR interface (CIR) I/O ports Package Operating frequency/ Power supply voltage Operating peripheral temperature (°C) Rev. 2.00 Sep. 28, 2009 Page 6 of 994 REJ09B0452-0200 Description • One channel • Supports ...
Page 49
List of Products Table 1.2 is the list of products, and figure 1.1 shows how to read the product name code. Table 1.2 List of Products Part No. ROM Capacity R4F2117R 160 Kbytes Part no Figure ...
Page 50
Block Diagram VCC VCC VCC VCL VSS VSS VSS VSS VSS RES XTAL EXTAL MD2 MD1 NMI ETRST 2 PJ0* 2 PJ1* 2 PJ2* 2 PJ3* 2 PJ4* 2 PJ5* 2 PJ6* 2 PJ7* 2 PI0* 2 PI1* 2 ...
Page 51
Pin Descriptions 1.4.1 Pin Assignments 108 107 106 109 P12 110 P11 111 VSS 112 P10 FSISS/PB7/RTS 113 FSICK/PB6/CTS 114 FSIDI/PB5/DTR 115 FSIDO/PB4/DSR 116 117 PB3/DCD/PWMU1B 118 PB2/RI/PWMU0B 119 PB1/LSCI PB0/LSMI 120 P30/LAD0 121 P31/LAD1 122 123 P32/LAD2 124 ...
Page 52
P12 P14 P17 14 PJ4 P13 P15 13 VSS VSS P11 12 PB6 P10 PJ3 11 PB3 PB4 PB5 10 PB1 PB0 PJ2 9 P32 P33 P31 8 P36 PJ1 P35 7 P81 P82 P80 6 P85 P86 P84 ...
Page 53
P11 P13 P15 P20 13 P12 P10 P16 P22 12 PB7 VSS PB6 P14 11 PB3 PB5 PB4 P17 10 P30 PB2 PB1 P31 9 P34 PB0 P32 P35 8 P80 P33 P82 P36 7 P84 P81 P86 P37 6 ...
Page 54
Pin Assignment in Each Operating Mode Table 1.3 H8S/2117R Group Pin Assignment in Each Operating Mode Pin No. TFP- BP- TLP- 144V 176V 145V ...
Page 55
Pin No. Single-Chip Mode TFP- BP- TLP- 144V 176V 145V Mode 2 (EXPE = P92/IRQ0 P91/IRQ1 P90/IRQ2 ⎯ ⎯ K3 (N) PI4 MD2 PH2/CIRI ...
Page 56
Pin No. Single-Chip Mode TFP- BP- TLP- 144V 176V 145V Mode 2 (EXPE = PF5/PWMU3A PF4/PWMU2A PF3/IRQ11/TMOX/TDPCKI0/TDPMCI0 PF2/IRQ10/TMOY/TDPCYI0 PF1/IRQ9/PWMU1A PF0/IRQ8/PWMU0A ⎯ ...
Page 57
Pin No. Single-Chip Mode TFP- BP- TLP- 144V 176V 145V Mode 2 (EXPE = 0) ⎯ ⎯ M12 NC 70 P13 L10 P72/AN2 71 R14 N11 P73/AN3 72 P14 N12 P74/AN4 73 R15 M13 P75/AN5 74 N13 N13 P76/AN6 75 ...
Page 58
Pin No. TFP- BP- TLP- 144V 176V 145V 92 G13 F12 93 G15 G13 94 G14 G11 95 F12 F10 ⎯ ⎯ F13 ⎯ ⎯ F15 96 F14 E10 97 E13 F13 98 E15 E12 99 E14 E13 100 E12 ...
Page 59
Pin No. Single-Chip Mode TFP- BP- TLP- 144V 176V 145V Mode 2 (EXPE = 0) 116 B11 C10 PB4/DSR/FSIDO 117 A11 A10 PB3/DCD/PWMU1B 118 D10 B9 PB2/RI/PWMU0B ⎯ ⎯ C10 PJ2 119 A10 C9 PB1/LSCI 120 B10 B8 PB0/LSMI 121 ...
Page 60
Pin No. Single-Chip Mode TFP- BP- TLP- 144V 176V 145V Mode 2 (EXPE = 0) ⎯ ⎯ 141 D4 B3 PH4 142 B3 C4 PH5 143 A2 A3 XTAL 144 B2 A2 EXTAL Notes: (N) in Pin No. ...
Page 61
Pin Functions Table 1.4 Pin Functions Type Symbol TFP-144V BP-176V TLP-145V I/O Power VCC 1, 36, 86 supply VCL 13 VSS 7, 42, 95, 111, 139 Clock XTAL 143 EXTAL 144 φ 18 EXCL 18 ExEXCL 32 Operating MD2 ...
Page 62
Type Symbol TFP-144V BP-176V TLP-145V I/O Interrupts NMI 11 IRQ15 to 17, IRQ0 50, 85, 84, 135 to 133 ExIRQ15 51 to 58, to 12, 10 ExIRQ6 ETRST* 2 H-UDI 27 ETMS ...
Page 63
Type Symbol TFP-144V BP-176V TLP-145V I/O 16-bit timer TCLKA 92 pulse unit TCLKB 91 (TPU) TCLKC 89 TCLKD 87 TIOCA0 94 TIOCB0 93 TIOCC0 92 TIOCD0 91 TIOCA1 90 TIOCB1 89 TIOCA2 88 TIOCB2 87 16-bit cycle TCMCKI3 6, 4, ...
Page 64
Type Symbol TFP-144V 14-bit PWM PWX0 5 timer PWX1 6 (PWMX) Serial TxD1 133 communi- TxD2 136 cation RxD1 134 interface RxD2 137 (SCI_1, SCK1 135 SCI_2) SCK2 2 Keyboard PS2AC 39 buffer PS2BC 37 control unit PS2CC 34 (PS2) ...
Page 65
Type Symbol TFP-144V Serial FTxD 16 communi- FRxD 15 cation RI 118 interface DCD with FIFO 117 (SCIF) DSR 116 DTR 115 CTS 114 RTS 113 LPC LAD3 to 124 to 121 B9, A9, Interface LAD0 (LPC) LFRAME 125 LRESET ...
Page 66
Type Symbol TFP-144V FSI FSISS 113 interface FSICK 114 (FSI) FSIDI 115 FSIDO 116 CIR CIRI 26 interface (CIR) A/D AN15 66, converter AN0 AVCC 76 AVref 77 AVSS 67 Rev. 2.00 Sep. 28, ...
Page 67
Type Symbol TFP-144V bus SCL0 14 interface SCL1 135 (IIC) SCL2 55 ExSCLA 53 ExSCLB 51 SDA0 17 SDA1 138 SDA2 56 ExSDAA 54 ExSDAB 52 I/O port P17 to 104 to 110, P10 112 P27 to ...
Page 68
Type Symbol TFP-144V I/O port P77 P70 P86 to 135 to 129 B6, A6, C6, P80 P97 P90 PA7 35, PA0 PB7 to 113 to 120 ...
Page 69
Type Symbol TFP-144V I/O port PH5 to 142 to 140, PH0 26, 12, 10 PI7 to PI0 ⎯ ⎯ PJ7 to PJ0 Notes: 1. Pins PE4 to PE1 are not supported by the system development tool (emulator). 2. Following precautions ...
Page 70
Rev. 2.00 Sep. 28, 2009 Page 28 of 994 REJ09B0452-0200 ...
Page 71
The H8S/2600 CPU is a high-speed central processing unit with an internal 32-bit architecture that is upward-compatible with the H8/300 and H8/300H CPUs. The H8S/2600 CPU has sixteen 16-bit general registers, can address a 16-Mbyte linear address space, and is ...
Page 72
Two CPU operating modes ⎯ Normal mode* ⎯ Advanced mode • Power-down state ⎯ Transition ...
Page 73
Differences from H8/300 CPU In comparison to the H8/300 CPU, the H8S/2600 CPU has the following enhancements: • More general registers and control registers ⎯ Eight 16-bit extended registers, and one 8-bit and two 32-bit control registers, have been ...
Page 74
CPU Operating Modes The H8S/2600 CPU has two operating modes: normal and advanced. Normal mode supports a maximum 64-kbyte address space. Advanced mode supports a maximum 16-Mbyte total address space. The mode is selected by the mode pins. 2.2.1 ...
Page 75
H'0000 Exception vector 1 H'0001 H'0002 Exception vector 2 H'0003 H'0004 Exception vector 3 H'0005 H'0006 Exception vector 4 H'0007 H'0008 Exception vector 5 H'0009 H'000A Exception vector 6 H'000B Figure 2.1 Exception Vector Table (Normal Mode (16 ...
Page 76
Advanced Mode • Address Space Linear access to a 16-Mbyte maximum address space is provided. • Extended Registers (En) The extended registers (E0 to E7) can be used as 16-bit registers the upper 16-bit segments of 32-bit ...
Page 77
The memory indirect addressing mode (@@aa:8) employed in the JMP and JSR instructions uses an 8-bit absolute address included in the instruction code to specify a memory operand that contains a branch address. In advanced mode the operand is a ...
Page 78
Address Space Figure 2.5 shows a memory map for the H8S/2600 CPU. The H8S/2600 CPU provides linear access to a maximum 64-kbyte address space in normal mode, and a maximum 16-Mbyte (architecturally 4-Gbyte) address space in advanced mode. The ...
Page 79
Registers The H8S/2600 CPU has the internal registers shown in figure 2.6. There are two types of registers; general registers and control registers. The control registers are a 24-bit program counter (PC), an 8-bit extended control register (EXR), an ...
Page 80
General Registers The H8S/2600 CPU has eight 32-bit general registers. These general registers are all functionally identical and can be used as both address registers and data registers. When a general register is used as a data register, it ...
Page 81
SP (ER7) 2.4.2 Program Counter (PC) This 24-bit counter indicates the address of the next instruction the CPU will execute. The length of all CPU instructions is 2 bytes (one word), so the least significant PC bit is ignored. (When ...
Page 82
Condition-Code Register (CCR) This 8-bit register contains internal CPU status information, including an interrupt mask bit (I) and half-carry (H), negative (N), zero (Z), overflow (V), and carry (C) flags. Operations can be performed on the CCR bits by ...
Page 83
Initial Value Bit Bit Name 1 V Undefined R Undefined R/W 2.4.5 Multiply-Accumulate Register (MAC) This 64-bit register stores the results of multiply-and-accumulate operations. It consists of two 32- bit registers denoted MACH and MACL. The lower 10 ...
Page 84
Data Formats The H8S/2600 CPU can process 1-bit, 4-bit (BCD), 8-bit (byte), 16-bit (word), and 32-bit (longword) data. Bit-manipulation instructions operate on 1-bit data by accessing bit … byte operand data. ...
Page 85
Data Type Register Number Word data Rn Word data En 15 MSB Longword data ERn 31 MSB En [Legend] ERn: General register ER En: General register E Rn: General register R RnH: General register RH RnL: General register RL MSB: ...
Page 86
Memory Data Formats Figure 2.10 shows the data formats in memory. The H8S/2600 CPU can access word data and longword data in memory, however word or longword data must begin at an even address attempt is made ...
Page 87
Instruction Set The H8S/2600 CPU has 69 instructions. The instructions are classified by function in table 2.1. Table 2.1 Instruction Classification Function Instructions Data transfer MOV 1 POP* , PUSH* LDM, STM MOVFPE* Arithmetic ADD, SUB, CMP, NEG operation ...
Page 88
Table of Instructions Classified by Function Tables 2.3 to 2.10 summarize the instructions in each functional category. The notation used in tables 2.3 to 2.10 is defined below. Table 2.2 Operation Notation Symbol Description Rd General register (destination)* Rs ...
Page 89
Symbol Description :8/:16/:24/:32 8-, 16-, 24-, or 32-bit length Note: * General registers include 8-bit registers (R0H to R7H, R0L to R7L), 16-bit registers ( E7), and 32-bit registers (ER0 to ER7). Table 2.3 Data Transfer ...
Page 90
Table 2.4 Arithmetic Operations Instructions (1) Instruction Size* Function Rd ± Rs → Rd, Rd ± #IMM → Rd ADD B/W/L SUB Performs addition or subtraction on data in two general registers immediate data and data in a ...
Page 91
Table 2.4 Arithmetic Operations Instructions (2) 1 Instruction Size* Function Rd ÷ Rs → Rd DIVXS B/W Performs signed division on data in two general registers: either 16 bits ÷ 8 bits → 8-bit quotient and 8-bit remainder or 32 ...
Page 92
Table 2.5 Logic Operations Instructions Instruction Size* Function Rd ∧ Rs → Rd, Rd ∧ #IMM → Rd AND B/W/L Performs a logical AND operation on a general register and another general register or immediate data. Rd ∨ Rs → ...
Page 93
Table 2.7 Bit Manipulation Instructions (1) Instruction Size* Function 1 → (<bit-No.> of <EAd>) BSET B Sets a specified bit in a general register or memory operand to 1. The bit number is specified by 3-bit immediate data or the ...
Page 94
Table 2.7 Bit Manipulation Instructions (2) 1 Instruction Size* Function C ⊕ (<bit-No.> of <EAd>) → C BXOR B XORs the carry flag with a specified bit in a general register or memory operand and stores the result in the ...
Page 95
Table 2.8 Branch Instructions Instruction Size Function ⎯ Bcc Branches to a specified address if a specified condition is true. The branching conditions are listed below. Mnemonic BRA(BT) BRN(BF) BHI BLS BCC(BHS) BCS(BLO) BNE BEQ BVC BVS BPL BMI BGE ...
Page 96
Table 2.9 System Control Instructions Instruction Size* Function ⎯ TRAPA Starts trap-instruction exception handling. ⎯ RTE Returns from an exception-handling routine. ⎯ SLEEP Causes a transition to a power-down state. (EAs) → CCR, (EAs) → EXR LDC B/W Moves general ...
Page 97
Table 2.10 Block Data Transfer Instructions Instruction Size Function ⎯ EEPMOV.B ⎯ EEPMOV.W Transfers a data block. Starting from the address set in ER5, transfers data for the number of bytes set in R4L the address location ...
Page 98
Basic Instruction Formats The H8S/2600 CPU instructions consist of 2-byte (1-word) units. An instruction consists of an operation field (op field), a register field (r field), an effective address extension (EA field), and a condition field (cc). Figure 2.11 ...
Page 99
Addressing Modes and Effective Address Calculation The H8S/2600 CPU supports the eight addressing modes listed in table 2.11. Each instruction uses a subset of these addressing modes. Arithmetic and logic instructions can use the register direct and immediate modes. ...
Page 100
Register Indirect with Displacement⎯@(d:16, ERn) or @(d:32, ERn) A 16-bit or 32-bit displacement contained in the instruction is added to an address register (ERn) specified by the register field of the instruction, and the sum gives the address of ...
Page 101
Table 2.12 Absolute Address Access Ranges Absolute Address Data address 8 bits (@aa:8) 16 bits (@aa:16) 32 bits (@aa:32) Program instruction 24 bits (@aa:24) address Note: Normal mode is not available in this LSI. 2.7.6 Immediate⎯#xx:8, #xx:16, or #xx:32 The ...
Page 102
Memory Indirect⎯@@aa:8 This mode can be used by the JMP and JSR instructions. The instruction code contains an 8-bit absolute address specifying a memory operand. This memory operand contains a branch address. The upper bits of the absolute address ...
Page 103
Effective Address Calculation Table 2.13 indicates how effective addresses are calculated in each addressing mode. In normal mode the upper 8 bits of the effective address are ignored in order to generate a 16-bit address. Note: Normal mode is ...
Page 104
Table 2.13 Effective Address Calculation (2) Addressing Mode and Instruction Format Absolute address Immediate Note: * Normal mode is not available in this LSI. Rev. 2.00 Sep. 28, 2009 Page 62 of 994 REJ09B0452-0200 Effective Address Calculation PC contents Sign ...
Page 105
Processing States The H8S/2600 CPU has four main processing states: the reset state, exception handling state, program execution state and power-down state. Figure 2.13 indicates the state transitions. • Reset State In this state, the CPU and all on-chip ...
Page 106
End of exception handling Exception-handling state RES = high *1 Reset state From any state, a transition to the reset state is made whenever the RES pin Notes: 1. goes low. A transition can also be made to the reset ...
Page 107
Usage Note 2.9.1 Notes on Using the Bit Operation Instruction Instructions BSET, BCLR, BNOT, BST, and BIST read data in byte units, and write data in byte units after bit operation. Therefore, attention must be paid when these instructions ...
Page 108
Rev. 2.00 Sep. 28, 2009 Page 66 of 994 REJ09B0452-0200 ...
Page 109
Section 3 MCU Operating Modes 3.1 Operating Mode Selection This LSI supports three operating modes (modes 2, 4, and 6). The operating mode is determined by the setting of the mode pins (MD2 and MD1). Table 3.1 shows the MCU ...
Page 110
Register Descriptions The following registers are related to the operating modes. Table 3.2 Register Configuration Register Name Mode control register System control register Serial timer control register System control register 3 3.2.1 Mode Control Register (MDCR) MDCR is used ...
Page 111
System Control Register (SYSCR) SYSCR monitors a reset source, selects the interrupt control mode and the detection edge for NMI, enables or disables access to the on-chip peripheral module registers, and enables or disables the on-chip RAM address space. ...
Page 112
Initial Value Bit Bit Name 1 KINWUE 0 0 RAME 1 Rev. 2.00 Sep. 28, 2009 Page 70 of 994 REJ09B0452-0200 R/W Description R/W Keyboard Control Register Access Enable When the RELOCATE bit is cleared to 0, this bit enables ...
Page 113
Serial Timer Control Register (STCR) STCR enables or disables register access, IIC operating mode, and on-chip flash memory, and selects the input clock of the timer counter. Initial Bit Bit Name Value 7 IICX2 0 6 IICX1 0 5 ...
Page 114
Initial Value Bit Bit Name 3 FLSHE 0 2 IICS 0 1 ICKS1 0 0 ICKS0 0 Rev. 2.00 Sep. 28, 2009 Page 72 of 994 REJ09B0452-0200 R/W Description R/W Flash Memory Control Register Enable Enables or disables CPU access ...
Page 115
System Control Register 3 (SYSCR3) SYSCR3 selects the register map and interrupt vector. Initial Bit Bit Name Value 7 — EIVS RELOCATE — All 0 Note: * Switch the modes when ...
Page 116
Address Map Figures 3.1 shows the address map in each operating mode. Rev. 2.00 Sep. 28, 2009 Page 74 of 994 REJ09B0452-0200 Mode 2 (EXPE = 0) Advanced mode Single-chip mode ROM: 160 Kbytes RAM: 8 Kbytes H'000000 On-chip ...
Page 117
Section 4 Exception Handling 4.1 Exception Handling Types and Priority As table 4.1 indicates, exception handling may be caused by a reset, illegal instruction, interrupt, direct transition, or trap instruction. Exception handling is prioritized as shown in table 4.1. If ...
Page 118
Exception Sources and Exception Vector Table Different vector addresses are assigned to exception sources. Table 4.2 and table 4.3 list the exception sources and their vector addresses. The EIVS bit in the system control register 3 (SYSCR3) allows the ...
Page 119
Exception Source Internal interrupt* Reserved for system use Reserved for system use Reserved for system use External interrupt WUE15 to WUE8 Internal interrupt* External interrupt IRQ8 IRQ9 IRQ10 IRQ11 IRQ12 IRQ13 IRQ14 IRQ15 Internal interrupt* Note: * For details on ...
Page 120
Table 4.3 Exception Handling Vector Table (Extended Vector Mode) Exception Source Reset Reserved for system use Illegal instruction Reserved for system use Direct transition External interrupt (NMI) Trap instruction (four sources) Reserved for system use External interrupt IRQ0 IRQ1 IRQ2 ...
Page 121
Exception Source Internal interrupt* External interrupt IRQ8 IRQ9 IRQ10 IRQ11 IRQ12 IRQ13 IRQ14 IRQ15 Internal interrupt* Note: * For details on the internal interrupt vector table, see section 5.5, Interrupt Exception Handling Vector Tables. 4.3 Reset A reset has the ...
Page 122
Figure 4.1 shows an example of the reset sequence. φ RES Internal address bus Internal read signal Internal write signal Internal data bus (1) Reset exception handling vector address ( H'000000 ( H'000002 (2) Start address ...
Page 123
Interrupt Exception Handling Interrupts are controlled by the interrupt controller. The sources to start interrupt exception handling are external interrupt sources (NMI, IRQ15 to IRQ0, KIN15 to KIN0, and WUE15 to WUE8) and internal interrupt sources from the on-chip ...
Page 124
Exception Handling by Illegal Instruction The exception handling by the illegal instruction starts when an undefined code is executed. The exception handling by the illegal instruction is always executable in the program execution state. The exception handling operates as ...
Page 125
Stack Status after Exception Handling Figure 4.2 shows the stack after completion of trap instruction exception handling and interrupt exception handling. Normal mode SP Notes: * Ignored on return. Normal mode is not available in this LSI. Figure 4.2 ...
Page 126
Usage Note When accessing word data or longword data, this LSI assumes that the lowest address bit is 0. The stack should always be accessed in words or longwords, and the value of the stack pointer (SP: ER7) should ...
Page 127
Section 5 Interrupt Controller 5.1 Features • Two interrupt control modes Two interrupt control modes can be set by means of the INTM1 and INTM0 bits in the system control register (SYSCR). • Priorities settable with ICR An interrupt control ...
Page 128
SYSCR3 SYSCR NMIEG NMI input IRQ input KIN input WUE input Internal interrupt sources WOVI0 to IBFI3 Interrupt controller [Legend] Interrupt control register ICR: IRQ sense control register ISCR: IRQ enable register IER: IRQ status register ISR: Keyboard matrix interrupt ...
Page 129
Input/Output Pins Table 5.1 summarizes the pins of the interrupt controller. Table 5.1 Pin Configuration Pin Name I/O NMI Input IRQ15 to IRQ0, Input ExIRQ15 to ExIRQ6 KIN15 to KIN0 Input WUE15 to WUE8 Input Function Nonmaskable external interrupt ...
Page 130
Register Descriptions The interrupt controller has the following registers. For details on the system control register (SYSCR), see section 3.2.2, System Control Register (SYSCR). For details on system control register 3 (SYSCR3), see section 3.2.4, System Control Register 3 ...
Page 131
Register Name Wake-up sense control register Wake-up input interrupt status register Wake-up enable register 1. Address in the upper cell: when RELOCATE = 0, address in the lower cell: when Note: RELOCATE = 1 2. Address in the upper cell: ...
Page 132
Table 5.3 Correspondence between Interrupt Source and ICR (H8S/2140B Group Compatible Vector Mode: EIVS = 0) Bit Bit Name ICRA 7 ICRn7 IRQ0 6 ICRn6 IRQ1 5 ICRn5 IRQ2, IRQ3 4 ICRn4 IRQ4, IRQ5 3 ICRn3 IRQ6, IRQ7 2 ICRn2 ...
Page 133
Address Break Control Register (ABRKCR) ABRKCR controls the address breaks. When both the CMF flag and BIE bit are set address break is requested. Bit Bit Name Initial Value 7 CMF Undefined — ...
Page 134
Break Address Registers (BARA to BARC) The BAR registers specify an address that break address. An address in which the first byte of an instruction exists should be set as a break ...
Page 135
IRQ Sense Control Registers (ISCR16H, ISCR16L, ISCRH, ISCRL) The ISCR registers select the source that generates an interrupt request at pins IRQ15 to IRQ0 or pins ExIRQ15 to ExIRQ6. • ISCR16H Bit Bit Name Initial Value R/W 7 IRQ15SCB ...
Page 136
ISCR16L Bit Bit Name Initial Value 7 IRQ11SCB 0 6 IRQ11SCA 0 5 IRQ10SCB 0 4 IRQ10SCA 0 3 IRQ9SCB 0 2 IRQ9SCA 0 1 IRQ8SCB 0 0 IRQ8SCA 0 • ISCRH Bit Bit Name Initial Value 7 IRQ7SCB ...
Page 137
ISCRL Bit Bit Name Initial Value 7 IRQ3SCB 0 6 IRQ3SCA 0 5 IRQ2SCB 0 4 IRQ2SCA 0 3 IRQ1SCB 0 2 IRQ1SCA 0 1 IRQ0SCB 0 0 IRQ0SCA 0 R/W Description R/W IRQn Sense Control B R/W IRQn ...
Page 138
IRQ Enable Registers (IER16, IER) The IER registers enable and disable interrupt requests IRQ15 to IRQ0. • IER16 Bit Bit Name Initial Value 7 IRQ15E 0 6 IRQ14E 0 5 IRQ13E 0 4 IRQ12E 0 3 IRQ11E 0 2 ...
Page 139
IRQ Status Registers (ISR16, ISR) The ISR registers are flag registers that indicate the status of IRQ15 to IRQ0 interrupt requests. • ISR16 Bit Bit Name Initial Value 7 IRQ15F 0 6 IRQ14F 0 5 IRQ13F 0 4 IRQ12F ...
Page 140
ISR Bit Bit Name Initial Value 7 IRQ7F 0 6 IRQ6F 0 5 IRQ5F 0 4 IRQ4F 0 3 IRQ3F 0 2 IRQ2F 0 1 IRQ1F 0 0 IRQ0F 0 Note: * Only 0 can be written for clearing ...
Page 141
Keyboard Matrix Interrupt Mask Registers (KMIMRA KMIMR) Wake-Up Event Interrupt Mask Registers (WUEMR) The KMIMR and WUEMR registers enable or disable key-sensing interrupt inputs (KIN15 to KIN0) and wake-up event interrupt inputs (WUE15 to WUE8). • KMIMRA Bit Bit ...
Page 142
WUEMR Bit Bit Name Initial Value 7 WUEMR15 1 6 WUEMR14 1 5 WUEMR13 1 4 WUEMR12 1 3 WUEMR11 1 2 WUEMR10 1 1 WUEMR9 1 0 WUEMR8 1 Rev. 2.00 Sep. 28, 2009 Page 100 of 994 ...
Page 143
Figure 5.2 shows the relation between the IRQ7 and IRQ6 interrupts, KMIMR, and KMIMRA in H8S/2140B Group compatible vector mode. The relation in extended vector mode is shown in figure 5.3. KMIMR0 (Initial value of 1) P60/KIN0 KMIMR5 (Initial value ...
Page 144
In H8S/2140B Group compatible vector mode, interrupt input from the IRQ7 pin is ignored when even one of the KMIMR15 to KMIMR8 bits is cleared the KIN7 to KIN0 pins or KIN15 to KIN8 pins are specified ...
Page 145
IRQ Sense Port Select Register 16 (ISSR16) IRQ Sense Port Select Register (ISSR) ISSR16 and ISSR select the IRQ15 to IRQ0 interrupt external input from the IRQ15 to IRQ7 pins and ExIRQ15 to ExIRQ7 pins. • ISSR16 Bit Bit ...
Page 146
Wake-Up Sense Control Register (WUESCR) Wake-Up Input Interrupt Status Register (WUESR) Wake-Up Enable Register (WER) WUESCR selects the interrupt source of the wake-up event interrupt inputs (WUE15 to WUE8). WUESR is an interrupt request flag register. WER enables/disables interrupts. ...
Page 147
WER Bit Bit Name Initial Value 7 WUEE ⎯ All 0 5.4 Interrupt Sources 5.4.1 External Interrupt Sources The interrupt sources of external interrupts are NMI, IRQ15 to IRQ0, KIN15 to KIN0 and WUE15 to ...
Page 148
When the interrupts are requested while IRQ15 to IRQ0 interrupt requests are generated at low level of IRQn input, hold the corresponding IRQ input at low level until the interrupt handling starts. Then put the relevant IRQ input back to ...
Page 149
When using the IRQ6 pin as the IRQ6 interrupt input pin, the KMIMR6 bit must be cleared to 0. When using the IRQ7 pin as the IRQ7 interrupt input pin, the KMIMR15 to KMIMR8 bits must all be set ...
Page 150
Internal Interrupt Sources Internal interrupts issued from the on-chip peripheral modules have the following features: • For each on-chip peripheral module there are flags that indicate the interrupt request status, and enable bits that individually select enabling or disabling ...
Page 151
Origin of Interrupt Source Name — Reserved for system use WDT_0 WOVI0 (Interval timer) WDT_1 WOVI1 (Interval timer) — Address break A/D converter ADI (A/D conversion end) — Reserved for system use External pin WUE15 to WUE8 TPU_0 TGI0A (TGR0A ...
Page 152
Origin of Interrupt Source Name TCM_2 TICI2 (Input capture) TCMI2 (Compare match) TOVMI2 (Cycle overflow) TUDI2 (Cycle underflow) TOVI2 (Overflow) TCM_3 TICI3 (Input capture) TCMI3 (Compare match) TOVMI3 (Cycle overflow) TUDI3 (Cycle underflow) TOVI3 (Overflow) TDP_0 TICI0 (Input capture) TCMI0 ...
Page 153
Origin of Interrupt Source Name TMR_0 CMIA0 (Compare match A) CMIB0 (Compare match B) OVI0 (Overflow) — Reserved for system use TMR_1 CMIA1 (Compare match A) CMIB1 (Compare match B) OVI1 (Overflow) — Reserved for system use TMR_X CMIAY (Compare ...
Page 154
Origin of Interrupt Source Name PS2 KBIA (Reception completion A) KBIB (Reception completion B) KBIC (Reception completion C) KBTIA (Transmission completion A)/ KBCA (1st KCLKA) KBTIB (Transmission completion B)/ KBCB (1st KCLKB) KBTIC (Transmission completion C)/ KBCC (1st KCLKC) KBID ...
Page 155
Table 5.6 Interrupt Sources, Vector Addresses, and Interrupt Priorities (Extended Vector Mode) Origin of Interrupt Source Name External pin NMI IRQ0 IRQ1 IRQ2 IRQ3 IRQ4 IRQ5 IRQ6 IRQ7 — Reserved for system use WDT_0 WOVI0 (Interval timer) WDT_1 WOVI1 (Interval ...
Page 156
Origin of Interrupt Source Name TPU_2 TGI2A (TGR2A input capture/compare match) TGI2B (TGR2B input capture/compare match) TGI2V (Overflow 1) TGI2U (Underflow 2) — Reserved for system use TCM_0 TICI0 (Input capture) TCMI0 (Compare match) TOVMI0 (Cycle overflow) TUDI0 (Cycle underflow) ...
Page 157
Origin of Interrupt Source Name TDP_2 TICI2 (Input capture) TCMI2 (Compare match) TPDMXI2 (Cycle overflow) TPDMNI2 (Cycle underflow) TWDMNI2 (Pulse width lower limit underflow) TWDMXI2 (Pulse width upper limit overflow) TOVI2 (Overflow) — Reserved for system use External IRQ8 pin ...
Page 158
Origin of Interrupt Source Name SCI_2 ERI2 (Reception error) RXI2 (Reception completion) TXI2 (Transmission data empty 2) TEI2 (Transmission end 2) IIC_0 IICI0 (1-byte transmission/reception completion) CIR RENDI (Reception end) OVEI (Overrun error) REPI (Repeat detection) FREI (Framing error) ABI ...
Page 159
Interrupt Control Modes and Interrupt Operation The interrupt controller has two modes: interrupt control mode 0 and interrupt control mode 1. Interrupt operations differ depending on the interrupt control mode. NMI and address break interrupts are always accepted except ...
Page 160
Interrupt Acceptance Control and 3-Level Control In interrupt control modes 0 and 1, interrupt acceptance control and 3-level mask control is performed by means of the I and UI bits in CCR and ICR (control level). Table 5.8 shows ...
Page 161
Table 5.9 shows operations and control signal functions in each interrupt control mode. Table 5.9 Operations and Control Signal Functions in Each Interrupt Control Mode Setting Interrupt Control Mode INTM1 [Legend] Ο: Interrupt operation control is performed ...
Page 162
The CPU generates a vector address for the accepted interrupt request and starts execution of the interrupt handling routine at the address indicated by the contents of the vector address in the vector table. An interrupt with interrupt control ...
Page 163
Interrupt Control Mode 1 In interrupt control mode 1, mask control is applied to three levels for interrupt requests other than NMI and address break by comparing the I and UI bits in CCR in the CPU, and the ...
Page 164
Figure 5.9 shows a flowchart of the interrupt acceptance operation interrupt source occurs when the corresponding interrupt enable bit is set interrupt request is sent to the interrupt controller. 2. According to the interrupt ...
Page 165
An interrupt with interrupt control level 1? IRQ0 Yes Figure 5.9 Flowchart of Procedure up to Interrupt Acceptance in Interrupt Control Mode 1 Program execution state Interrupt generated? Yes Yes NMI No No Yes No IRQ0 No Yes IRQ1 Yes ...
Page 166
Interrupt Exception Handling Sequence Figure 5.10 shows the interrupt exception handling sequence. The example shown is for the case where interrupt control mode 0 is set in advanced mode, and the program area and stack area are in on-chip ...
Page 167
Interrupt Response Times Table 5.10 shows interrupt response times − the intervals between generation of an interrupt request and execution of the first instruction in the interrupt handling routine. Table 5.10 Interrupt Response Times No. Execution Status 1 Interrupt ...
Page 168
Address Breaks 5.7.1 Features With this LSI possible to identify the prefetch of a specific address by the CPU and generate an address break interrupt, using the ABRKCR and BAR registers. When an address break interrupt is ...
Page 169
Operation ABRKCR and BAR settings can be made so that an address break interrupt is generated when the CPU prefetches the address set in BAR. This address break function issues an interrupt request to the interrupt controller when the ...
Page 170
Program area in on-chip memory, 1-state execution instruction at specified break address Instruction Instruction fetch fetch φ Address bus H'0310 H'0312 H'0314 H'0316 NOP execution Break request signal H'0310 NOP H'0312 NOP H'0314 NOP H'0316 NOP • Program area ...
Page 171
Usage Notes 5.8.1 Conflict between Interrupt Generation and Disabling When an interrupt enable bit is cleared disable interrupt requests, the disabling becomes effective after execution of the instruction. When an interrupt enable bit is cleared to ...
Page 172
Instructions for Disabling Interrupts The instructions that disable interrupts are LDC, ANDC, ORC, and XORC. After any of these instructions are executed, all interrupts including NMI are disabled and the next instruction is always executed. When the I bit ...
Page 173
External Interrupt Pin in Software Standby Mode and Watch Mode • When the pins (IRQ15 to IRQ0, ExIRQ15 to ExIRQ6, KIN15 to KIN0, and WUE15 to WUE8) are used as external input pins in software standby mode or watch ...
Page 174
Rev. 2.00 Sep. 28, 2009 Page 132 of 994 REJ09B0452-0200 ...
Page 175
Section 6 Bus Controller (BSC) Since this LSI does not have an externally extended function, it does not have an on-chip bus controller (BSC). Considering the software compatibility with similar products, you must be careful to set appropriate values to ...
Page 176
Wait State Control Register (WSCR) Initial Bit Bit Name Value 7, 6 — All 1 5 ABW 1 4 AST 1 3 WMS1 0 2 WMS0 0 1 WC1 1 0 WC0 1 Rev. 2.00 Sep. 28, 2009 Page ...
Page 177
Table 7.1 lists the port functions. The pins of each port also have other functions such as input/output pins of on-chip peripheral modules or interrupt input pins. Each I/O port includes a data direction register (DDR) that controls input/output, a ...
Page 178
Table 7.1 Port Functions Port Description Bit I/O Port 1 General I/O 7 P17 port 6 P16 5 P15 4 P14 3 P13 2 P12 1 P11 0 P10 Port 2 General I/O 7 P27 port 6 P26 5 P25 ...
Page 179
Port Description Bit I/O Port 4 General I/O 7 P47 port also functioning as 6 P46 PWMX and 5 P45 PWMU_B outputs, TCM input, and 4 P44 TMR_0, 3 P43/SCK2 TMR_1, IIC_1, and SCI_2 2 P42/SDA1 inputs/outputs 1 P41 0 ...
Page 180
Port Description Bit I/O ⎯ Port 7 General input 7 port also ⎯ 6 functioning as ⎯ 5 A/D converter analog input ⎯ 4 ⎯ 3 ⎯ 2 ⎯ 1 ⎯ 0 Port 8 General I/O 6 P86/SCK1/ port also ...
Page 181
Port Description Bit I/O Port A General I/O 7 PA7/PS2CD port also 6 PA6/PS2CC functioning as keyboard 5 PA5/PS2BD input and 4 PA4/PS2BC PS2 input/output 3 PA3/PS2AD 2 PA2/PS2AC 1 PA1/PS2DD 0 PA0/PS2DC Port B General I/O 7 PB7 port ...
Page 182
Port Description Bit I/O Port D General I/O 7 PD7 port also 6 PD6 functioning as A/D converter 5 PD5 analog input 4 PD4 3 PD3 2 PD2 1 PD1 0 PD0 ⎯ Port E General input 4 port also ...
Page 183
Port Description Bit I/O PG7/ExSCLB ExIRQ15 Port G General I/O 7 port also PG6/ExSDAB ExIRQ14 6 functioning as PG5/ExSCLA ExIRQ13 interrupt and 5 TDP inputs, PG4/ExSDAA ExIRQ12 4 TMR_X and TMR_Y 3 PG3/SCL2 inputs, and 2 PG2/SDA2 IIC0 to IIC2 ...
Page 184
Port Description Bit I/O 2 Port J General I/O 7 PJ7* port 2 6 PJ6 PJ5 PJ4 PJ3 PJ2 PJ1 PJ0* Notes: 1. Not supported by the system ...
Page 185
Register Descriptions Table 7.2 lists each port registers. Table 7.2 Register Configuration in Each Port Number Port of Pins DDR DR Port Port Port Port 4 8 ...
Page 186
Data Direction Register (PnDDR and DDR specifies the port input or output for each bit. The upper five bits in P5DDR, the upper one bit in ...
Page 187
Data Register (PnDR and register that stores output data of the pins to be used as the general output port. Since the P96DR bit is determined by the state ...
Page 188
Pull-Up MOS Control Register (PnPCR and J) Pull-Up MOS Control Register (KMPCR) (Port 6) PCR is a register that controls on/off of the port input pull-up MOS. If ...
Page 189
Table 7.3 Input Pull-Up MOS State (1) • Port and J Port Pin State Port 1 Port output Port input Port 2 Port output Port input Port 3 Port output Port input Port 6 Port ...
Page 190
Table 7.3 Input Pull-Up MOS State (2) • Port and H Port Pin State Port B Port output Port input Port C Port output Port input Port D Port output Port input Port F Port output ...
Page 191
Output Data Register (PnODR and 7.1.5 ODR is a register that stores output data for ports. The upper two bits in PHODR are reserved. Bit Bit Name Initial Value 7 Pn7ODR 0 ...
Page 192
Noise Canceler Decision Control Register (PnNCMC and G) 7.1.7 NCMC controls whether expected for the input signal to port n pins in bit units. Bit Bit Name Initial Value 7 Pn7NCMC 0 ...
Page 193
Sampling clock selection t Pin Latch Latch input t Sampling clock P6n input PCn input PGn input 1 expected P6n input PCn input PGn input 0 expected P6n input PCn input PGn ...
Page 194
Port Nch-OD Control Register (PnNOCR and 7.1.9 The individual bits of NOCR specify output driver type for the pins of port n that is specified as output. The upper two bits in PHNOCR ...
Page 195
Pin Functions The pin function is switched according to the setting of the PORTS bit in PTCNT2. (Ports and H) PORTS = 0 (1) DDR NOCR ODR 0 N-ch. driver P-ch. driver Input pull-up Off ...
Page 196
Output Buffer Control This section describes the output priority of each pin. The name of each peripheral module pin is followed by “_OE”. This (for example: TIOCA4_OE) indicates whether the output of the corresponding function is valid (1) or ...
Page 197
Port 3 (1) P37/SERIRQ, P36/LCLK, P35/LRESET, P34/LFRAME, P33/LAD3, P32/LAD2, P31/LAD1, P30/LAD0 The pin function is switched as shown below according to the combination of the FSILIE bit in SLCR of FSI, the SCIFE bit in HICR5 and the LPC4E ...
Page 198
P46/PWX0/PWMU4B/TCMCYI3 The pin function is switched as shown below according to the combination of the PWMX and PWMU and the P46DDR bit. Module Name Pin Function PWMX PWX0 output PWMU PWMU4B output I/O port P46 output P46 input (initial ...
Page 199
P44/TMO1/PWMU2B/TCMCYI2 The pin function is switched as shown below according to the combination of the TMR and PWMU and the P44DDR bit. Module Name Pin Function TMR TMO1 output PWMU PWMU2B output I/O port P44 output P44 input (initial ...
Page 200
P42/SDA1/TCMCYI1 The pin function is switched as shown below according to the combination of the IIC1AS and IIC1BS bits in PTCNT1, ICE bit in ICCR of IIC_1, and the P42DDR bit. When the TCMIPE bit in TCMIER_1 of TCM_1 ...