P89LPC932A1_3 © NXP B.V. 2007. All rights reserved.
Product data sheet Rev. 03 — 12 March 2007 63 of 64
continued >>
NXP Semiconductors
P89LPC932A1
8-bit microcontroller with accelerated two-clock 80C51 core
17. Contents
1 General description. . . . . . . . . . . . . . . . . . . . . . 1
2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
2.1 Principal features . . . . . . . . . . . . . . . . . . . . . . . 1
2.2 Additional features . . . . . . . . . . . . . . . . . . . . . . 1
2.3 Comparison to the P89LPC932 . . . . . . . . . . . . 2
3 Ordering information. . . . . . . . . . . . . . . . . . . . . 3
4 Block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . 4
5 Functional diagram . . . . . . . . . . . . . . . . . . . . . . 5
6 Pinning information. . . . . . . . . . . . . . . . . . . . . . 5
6.1 Pinning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
6.2 Pin description . . . . . . . . . . . . . . . . . . . . . . . . . 7
7 Functional description . . . . . . . . . . . . . . . . . . 11
7.1 Special function registers . . . . . . . . . . . . . . . . 11
7.2 Enhanced CPU. . . . . . . . . . . . . . . . . . . . . . . . 17
7.3 Clocks. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
7.3.1 Clock definitions . . . . . . . . . . . . . . . . . . . . . . . 17
7.3.2 CPU clock (OSCCLK). . . . . . . . . . . . . . . . . . . 17
7.3.3 Low speed oscillator option . . . . . . . . . . . . . . 17
7.3.4 Medium speed oscillator option . . . . . . . . . . . 17
7.3.5 High speed oscillator option . . . . . . . . . . . . . . 17
7.3.6 Clock output . . . . . . . . . . . . . . . . . . . . . . . . . . 17
7.4 On-chip RC oscillator option. . . . . . . . . . . . . . 18
7.5 Watchdog oscillator option . . . . . . . . . . . . . . . 18
7.6 External clock input option . . . . . . . . . . . . . . . 18
7.7 CCLK wake-up delay . . . . . . . . . . . . . . . . . . . 19
7.8 CCLK modification: DIVM register . . . . . . . . . 19
7.9 Low power select . . . . . . . . . . . . . . . . . . . . . . 19
7.10 Memory organization . . . . . . . . . . . . . . . . . . . 19
7.11 Data RAM arrangement . . . . . . . . . . . . . . . . . 20
7.12 Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
7.12.1 External interrupt inputs . . . . . . . . . . . . . . . . . 20
7.13 I/O ports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
7.13.1 Port configurations . . . . . . . . . . . . . . . . . . . . . 22
7.13.1.1 Quasi-bidirectional output configuration . . . . . 22
7.13.1.2 Open-drain output configuration . . . . . . . . . . . 22
7.13.1.3 Input-only configuration . . . . . . . . . . . . . . . . . 22
7.13.1.4 Push-pull output configuration . . . . . . . . . . . . 23
7.13.2 Port 0 analog functions. . . . . . . . . . . . . . . . . . 23
7.13.3 Additional port features. . . . . . . . . . . . . . . . . . 23
7.14 Power monitoring functions. . . . . . . . . . . . . . . 23
7.14.1 Brownout detection. . . . . . . . . . . . . . . . . . . . . 23
7.14.2 Power-on detection. . . . . . . . . . . . . . . . . . . . . 24
7.15 Power reduction modes . . . . . . . . . . . . . . . . . 24
7.15.1 Idle mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
7.15.2 Power-down mode . . . . . . . . . . . . . . . . . . . . . 24
7.15.3 Total Power-down mode . . . . . . . . . . . . . . . . . 24
7.16 Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
7.16.1 Reset vector . . . . . . . . . . . . . . . . . . . . . . . . . . 25
7.17 Timers/counters 0 and 1 . . . . . . . . . . . . . . . . 25
7.17.1 Mode 0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
7.17.2 Mode 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
7.17.3 Mode 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
7.17.4 Mode 3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
7.17.5 Mode 6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
7.17.6 Timer overflow toggle output . . . . . . . . . . . . . 26
7.18 RTC/system timer. . . . . . . . . . . . . . . . . . . . . . 26
7.19 CCU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
7.19.1 CCU clock . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
7.19.2 CCUCLK prescaling . . . . . . . . . . . . . . . . . . . . 27
7.19.3 Basic timer operation . . . . . . . . . . . . . . . . . . . 27
7.19.4 Output compare . . . . . . . . . . . . . . . . . . . . . . . 27
7.19.5 Input capture . . . . . . . . . . . . . . . . . . . . . . . . . 27
7.19.6 PWM operation . . . . . . . . . . . . . . . . . . . . . . . 28
7.19.7 Alternating output mode. . . . . . . . . . . . . . . . . 29
7.19.8 PLL operation. . . . . . . . . . . . . . . . . . . . . . . . . 29
7.19.9 CCU interrupts . . . . . . . . . . . . . . . . . . . . . . . . 30
7.20 UART . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
7.20.1 Mode 0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
7.20.2 Mode 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
7.20.3 Mode 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.20.4 Mode 3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.20.5 Baud rate generator and selection . . . . . . . . . 31
7.20.6 Framing error . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.20.7 Break detect. . . . . . . . . . . . . . . . . . . . . . . . . . 31
7.20.8 Double buffering. . . . . . . . . . . . . . . . . . . . . . . 32
7.20.9 Transmit interrupts with double buffering
enabled (modes 1, 2 and 3) . . . . . . . . . . . . . . 32
7.20.10 The 9
th
bit (bit 8) in double buffering
(modes 1, 2 and 3). . . . . . . . . . . . . . . . . . . . . 32
7.21 I
2
C-bus serial interface. . . . . . . . . . . . . . . . . . 33
7.22 Serial Peripheral Interface (SPI). . . . . . . . . . . 35
7.22.1 Typical SPI configurations . . . . . . . . . . . . . . . 36
7.23 Analog comparators. . . . . . . . . . . . . . . . . . . . 38
7.23.1 Internal reference voltage. . . . . . . . . . . . . . . . 38
7.23.2 Comparator interrupt . . . . . . . . . . . . . . . . . . . 38
7.23.3 Comparators and power reduction modes . . . 39
7.24 Keypad interrupt. . . . . . . . . . . . . . . . . . . . . . . 39
7.25 Watchdog timer . . . . . . . . . . . . . . . . . . . . . . . 40
7.26 Additional features . . . . . . . . . . . . . . . . . . . . . 40
7.26.1 Software reset . . . . . . . . . . . . . . . . . . . . . . . . 40
7.26.2 Dual data pointers . . . . . . . . . . . . . . . . . . . . . 40
7.27 Data EEPROM. . . . . . . . . . . . . . . . . . . . . . . . 41
7.28 Flash program memory . . . . . . . . . . . . . . . . . 41
7.28.1 General description . . . . . . . . . . . . . . . . . . . . 41
7.28.2 Features. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41