Motorola MC9S12DT128B User Manual

DOCUMENT NUMBER  
9S12DT128BDGV1/D  
MC9S12DT128B  
Device User Guide  
V01.07  
Covers also  
MC9S12DG128B, MC9S12DJ128B,  
MC9S12DB128B  
Original Release Date: 18 June 2001  
Revised: 16 Aug 2002  
Motorola, Inc  
Motorola reserves the right to make changes without further notice to any products herein to improve reliability, function or  
design. Motorola does not assume any liability arising out of the application or use of any product or circuit described herein;  
neither does it convey any license under its patent rights nor the rights of others. Motorola products are not designed, intended,  
or authorized for use as components in systems intended for surgical implant into the body, or other applications intended to  
support or sustain life, or for any other application in which the failure of the Motorola product could create a situation where  
personal injury or death may occur. Should Buyer purchase or use Motorola products for any such unintended or unauthorized  
application, Buyer shall indemnify and hold Motorola and its officers, employees, subsidiaries, affiliates, and distributors harmless  
against all claims, costs, damages, and expenses, and reasonable attorney fees arising out of, directly or indirectly, any claim of  
personal injury or death associated with such unintended or unauthorized use, even if such claim alleges that Motorola was  
negligent regarding the design or manufacture of the part.  
1
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
MC9S12DT128B Device User Guide — V01.07  
Table of Contents  
2.3.20 PH7 / KWH7 — Port H I/O Pin 7 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .56  
3
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
2.3.56 PS0 / RXD0 — Port S I/O Pin 0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .61  
4
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
5
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
Section 8 Enhanced Capture Timer (ECT) Block Description. . . . . . . . . . . .75  
Section 9 Analog to Digital Converter (ATD) Block Description. . . . . . . . . .75  
Section 10 Inter-IC Bus (IIC) Block Description . . . . . . . . . . . . . . . . . . . . . . .75  
Section 11 Serial Communications Interface (SCI) Block Description. . . . .75  
Section 12 Serial Peripheral Interface (SPI) Block Description . . . . . . . . . .76  
Section 13 J1850 (BDLC) Block Description. . . . . . . . . . . . . . . . . . . . . . . . . .76  
Section 14 Byteflight (BF) Block Description . . . . . . . . . . . . . . . . . . . . . . . . .76  
Section 15 Pulse Width Modulator (PWM) Block Description. . . . . . . . . . . .76  
Section 16 Flash EEPROM 128K Block Description . . . . . . . . . . . . . . . . . . .76  
Section 17 EEPROM 2K Block Description. . . . . . . . . . . . . . . . . . . . . . . . . . .76  
Section 18 RAM Block Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .77  
Section 19 MSCAN Block Description. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .77  
Section 20 Port Integration Module (PIM) Block Description . . . . . . . . . . . .77  
Section 21 Voltage Regulator (VREG) Block Description . . . . . . . . . . . . . . .77  
Section 22 Printed Circuit Board Layout Proposal . . . . . . . . . . . . . . . . . . . .78  
A.1.2  
Power Supply. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .83  
6
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
B.3 80-pin QFP package. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .121  
7
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
MC9S12DT128B Device User Guide — V01.07  
8
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
MC9S12DT128B Device User Guide — V01.07  
List of Figures  
Figure 22-5 112-pin LQFP mechanical dimensions (case no. 987) . . . . . . . . . . . . . . . . . . .120  
9
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
MC9S12DT128B Device User Guide — V01.07  
10  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
MC9S12DT128B Device User Guide — V01.07  
List of Tables  
$0180 - $01BF CAN1 (Motorola Scalable CAN - MSCAN) ..............................................38  
11  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
Table A-20 Expanded Bus Timing Characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .117  
12  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
MC9S12DT128B Device User Guide — V01.07  
Preface  
The Device User Guide provides information about the MC9S12DT128B device made up of standard  
HCS12 blocks and the HCS12 processor core.  
This document is part of the customer documentation. A complete set of device manuals also includes the  
HCS12 Core User Guide and all the individual Block User Guides of the implemented modules. In a effort  
to reduce redundancy all module specific information is located only in the respective Block User Guide.  
If applicable, special implementation details of the module are given in the block description sections of  
this document.  
Table 0-1 shows the availability of peripheral modules on the various derivatives. For details about the  
compatibility within the MC9S12D-Family refer also to engineering bulletin EB386.  
1
Table 0-1 Derivative Differences  
Modules  
# of CANs  
CAN4  
MC9S12DT128B MC9S12DG128B MC9S12DJ128B MC9S12DB128B  
3
2
2
2
CAN1  
CAN0  
J1850/BDLC  
IIC  
Byteflight  
Package  
112 LQFP  
112 LQFP/80 QFP 112 LQFP/80 QFP  
112 LQFP  
Package  
Code  
PV  
PV/FU  
PV/FU  
PV  
Mask set  
L85D  
L85D  
L85D  
L85D  
Temp Options  
M, V, C  
M, V, C  
M, V, C  
M, V, C  
An errata exists  
contact Sales  
Office  
An errata exists  
contact Sales  
Office  
An errata exists  
contact Sales  
Office  
An errata exists  
contact Sales  
Office  
Notes  
NOTES:  
1. : Available for this device, : Not available for this device  
13  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
 
MC9S12DT128B Device User Guide — V01.07  
The following figure provides an ordering number example for the MC9S12D128B devices.  
MC9S12 DJ128B C FU  
Temperature Options  
Package Option  
Temperature Option  
Device Title  
C = -40˚C to 85˚C  
V = -40˚C to 105˚C  
M = -40˚C to 125˚C  
Package Options  
FU = 80QFP  
PV = 112LQFP  
Controller Family  
Figure 0-1 Order Partnumber Example  
See Table 0-2 for names and versions of the referenced documents throughout the Device User Guide.  
Table 0-2 Document References  
User Guide  
Version  
Document Order Number  
HCS12COREUG  
S12CRGV3/D  
HCS12_V1.5 Core User Guide  
1.2  
Clock and Reset Generator (CRG) Block User Guide  
Enhanced Capture Timer 16 Bit 8 Channel (ECT_16B8C) Block User Guide  
Analog to Digital Converter 10 Bit 8 Channel (ATD_10B8C) Block User Guide  
Inter IC Bus (IIC) Block User Guide  
V03  
V01  
V02  
V02  
V02  
V02  
V01  
V01  
V01  
V01  
V02  
V01  
V01  
V01  
S12ECT16B8CV1/D  
S12ATD10B8CV2/D  
S12IICV2/D  
Asynchronous Serial Interface (SCI) Block User Guide  
Serial Peripheral Interface (SPI) Block User Guide  
S12SCIV2/D  
S12SPIV2/D  
Pulse Width Modulator 8 Bit 8 Channel (PWM_8B8C) Block User Guide  
128K Byte Flash (FTS128K) Block User Guide  
S12PWM8B8CV1/D  
S12FTS128KV1/D  
S12EETS2KV1/D  
S12BDLCV1/D  
2K Byte EEPROM (EETS2K) Block User Guide  
Byte Level Data Link Controller -J1850 (BDLC) Block User Guide  
Motorola Scalable CAN (MSCAN) Block User Guide  
Voltage Regulator (VREG) Block User Guide  
S12MSCANV2/D  
S12VREGV1/D  
Port Integration Module (PIM_9DT128) Block User Guide  
Byteflight (BF) Block User Guide  
S12PIMDT128V1/D  
S12BFV1/D  
14  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
   
MC9S12DT128B Device User Guide — V01.07  
Section 1 Introduction  
1.1 Overview  
The MC9S12DT128B microcontroller unit (MCU) is a 16-bit device composed of standard on-chip  
peripherals including a 16-bit central processing unit (HCS12 CPU), 128K bytes of Flash EEPROM, 8K  
bytes of RAM, 2K bytes of EEPROM, two asynchronous serial communications interfaces (SCI), two  
serial peripheral interfaces (SPI), an 8-channel IC/OC enhanced capture timer, two 8-channel, 10-bit  
analog-to-digital converters (ADC), an 8-channel pulse-width modulator (PWM), a digital Byte Data Link  
Controller (BDLC), 29 discrete digital I/O channels (Port A, Port B, Port K and Port E), 20 discrete digital  
I/O lines with interrupt and wakeup capability, three CAN 2.0 A, B software compatible modules  
(MSCAN12), a Byteflight module and an Inter-IC Bus. The MC9S12DT128B has full 16-bit data paths  
throughout. However, the external bus can operate in an 8-bit narrow mode so single 8-bit wide memory  
can be interfaced for lower cost systems. The inclusion of a PLL circuit allows power consumption and  
performance to be adjusted to suit operational requirements.  
1.2 Features  
HCS12 Core  
– 16-bit HCS12 CPU  
i. Upward compatible with M68HC11 instruction set  
ii. Interrupt stacking and programmer’s model identical to M68HC11  
iii.20-bit ALU  
iv. Instruction queue  
v. Enhanced indexed addressing  
– MEBI (Multiplexed External Bus Interface)  
– MMC (Module Mapping Control)  
– INT (Interrupt control)  
– BKP (Breakpoints)  
– BDM (Background Debug Mode)  
CRG (Clock and Reset Generator)  
– Choice of low current Colpitts oscillator or standard Pierce Oscillator  
– PLL  
– COP watchdog  
– real time interrupt  
– clock monitor  
8-bit and 4-bit ports with interrupt functionality  
15  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
     
MC9S12DT128B Device User Guide — V01.07  
– Digital filtering  
– Programmable rising or falling edge trigger  
Memory  
– 128K Flash EEPROM  
– 2K byte EEPROM  
– 8K byte RAM  
Two 8-channel Analog-to-Digital Converters  
– 10-bit resolution  
– External conversion trigger capability  
Three 1M bit per second, CAN 2.0 A, B software compatible modules  
– Five receive and three transmit buffers  
– Flexible identifier filter programmable as 2 x 32 bit, 4 x 16 bit or 8 x 8 bit  
– Four separate interrupt channels for Rx, Tx, error and wake-up  
– Low-pass filter wake-up function  
– Loop-back for self test operation  
Enhanced Capture Timer  
– 16-bit main counter with 7-bit prescaler  
– 8 programmable input capture or output compare channels  
– Two 8-bit or one 16-bit pulse accumulators  
8 PWM channels  
– Programmable period and duty cycle  
– 8-bit 8-channel or 16-bit 4-channel  
– Separate control for each pulse width and duty cycle  
– Center-aligned or left-aligned outputs  
– Programmable clock select logic with a wide range of frequencies  
– Fast emergency shutdown input  
– Usable as interrupt inputs  
Serial interfaces  
– Two asynchronous Serial Communications Interfaces (SCI)  
– Two Synchronous Serial Peripheral Interface (SPI)  
– Byteflight  
Byte Data Link Controller (BDLC)  
16  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
MC9S12DT128B Device User Guide — V01.07  
SAE J1850 Class B Data Communications Network Interface  
– Compatible and ISO Compatible for Low-Speed (<125 Kbps) Serial Data Communications in  
Automotive Applications  
Inter-IC Bus (IIC)  
– Compatible with I2C Bus standard  
– Multi-master operation  
– Software programmable for one of 256 different serial clock frequencies  
112-Pin LQFP and 80-Pin QFP package options  
– I/O lines with 5V input and drive capability  
– 5V A/D converter inputs  
– Operation at 50MHz equivalent to 25MHz Bus Speed  
– Development support  
– Single-wire background debug™ mode (BDM)  
– On-chip hardware breakpoints  
1.3 Modes of Operation  
User modes  
Normal and Emulation Operating Modes  
– Normal Single-Chip Mode  
– Normal Expanded Wide Mode  
– Normal Expanded Narrow Mode  
– Emulation Expanded Wide Mode  
– Emulation Expanded Narrow Mode  
Special Operating Modes  
– Special Single-Chip Mode with active Background Debug Mode  
– Special Test Mode (Motorola use only)  
– Special Peripheral Mode (Motorola use only)  
Low power modes  
Stop Mode  
Pseudo Stop Mode  
Wait Mode  
17  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
 
MC9S12DT128B Device User Guide — V01.07  
Figure 1-1 shows a block diagram of the MC9S12DT128B device.  
18  
http://www.xinpian.net  
提供单片机解密、IC解密、芯片解密业务 010-62245566  
13810019655  
 
MC9S12DT128B Device User Guide — V01.07  
Figure 1-1 MC9S12DT128B Block Diagram