User’s Manual IE-789860-NS-EM1 Emulation Board Target Devices µPD789860 Subseries µPD789861 Subseries µPD789052 Subseries µPD789062 Subseries Document No. U16499EJ1V0UM00 (1st edition) Date Published July 2003 N CP(K) 2003 Printed in Japan [MEMO] 2 User’s Manual U16499EJ1V0UM EEPROM is a trademark of NEC Electronics Corporation. Windows is either a registered trademark or a trademark of Microsoft Corporation in the United States and/or other countries. PC/AT is a trademark of International Business Machines Corporation. • The information in this document is current as of December, 2002. The information is subject to change without notice. For actual design-in, refer to the latest publications of NEC Electronics data sheets or data books, etc., for the most up-to-date specifications of NEC Electronics products. Not all products and/or types are available in every country. Please check with an NEC Electronics sales representative for availability and additional information. • No part of this document may be copied or reproduced in any form or by any means without the prior written consent of NEC Electronics. NEC Electronics assumes no responsibility for any errors that may appear in this document. • NEC Electronics does not assume any liability for infringement of patents, copyrights or other intellectual property rights of third parties by or arising from the use of NEC Electronics products listed in this document or any other liability arising from the use of such products. No license, express, implied or otherwise, is granted under any patents, copyrights or other intellectual property rights of NEC Electronics or others. • Descriptions of circuits, software and other related information in this document are provided for illustrative purposes in semiconductor product operation and application examples. The incorporation of these circuits, software and information in the design of a customer's equipment shall be done under the full responsibility of the customer. NEC Electronics assumes no responsibility for any losses incurred by customers or third parties arising from the use of these circuits, software and information. • While NEC Electronics endeavors to enhance the quality, reliability and safety of NEC Electronics products, customers agree and acknowledge that the possibility of defects thereof cannot be eliminated entirely. To minimize risks of damage to property or injury (including death) to persons arising from defects in NEC Electronics products, customers must incorporate sufficient safety measures in their design, such as redundancy, fire-containment and anti-failure features. • NEC Electronics products are classified into the following three quality grades: "Standard", "Special" and "Specific". The "Specific" quality grade applies only to NEC Electronics products developed based on a customerdesignated "quality assurance program" for a specific application. The recommended applications of an NEC Electronics product depend on its quality grade, as indicated below. Customers must check the quality grade of each NEC Electronics product before using it in a particular application. "Standard": Computers, office equipment, communications equipment, test and measurement equipment, audio and visual equipment, home electronic appliances, machine tools, personal electronic equipment and industrial robots. "Special": Transportation equipment (automobiles, trains, ships, etc.), traffic control systems, anti-disaster systems, anti-crime systems, safety equipment and medical equipment (not specifically designed for life support). "Specific": Aircraft, aerospace equipment, submersible repeaters, nuclear reactor control systems, life support systems and medical equipment for life support, etc. The quality grade of NEC Electronics products is "Standard" unless otherwise expressly specified in NEC Electronics data sheets or data books, etc. If customers wish to use NEC Electronics products in applications not intended by NEC Electronics, they must contact an NEC Electronics sales representative in advance to determine NEC Electronics' willingness to support a given application. (Note) (1) "NEC Electronics" as used in this statement means NEC Electronics Corporation and also includes its majority-owned subsidiaries. (2) "NEC Electronics products" means any product developed or manufactured by or for NEC Electronics (as defined above). M8E 02. 11-1 User’s Manual U16499EJ1V0UM 3 Regional Information Some information contained in this document may vary from country to country. Before using any NEC Electronics product in your application, pIease contact the NEC Electronics office in your country to obtain a list of authorized representatives and distributors. They will verify: • Device availability • Ordering information • Product release schedule • Availability of related technical literature • Development environment specifications (for example, specifications for third-party tools and components, host computers, power plugs, AC supply voltages, and so forth) • Network requirements In addition, trademarks, registered trademarks, export restrictions, and other legal issues may also vary from country to country. [GLOBAL SUPPORT] http://www.necel.com/en/support/support.html NEC Electronics America, Inc. (U.S.) NEC Electronics (Europe) GmbH NEC Electronics Hong Kong Ltd. Santa Clara, California Tel: 408-588-6000 800-366-9782 Duesseldorf, Germany Tel: 0211-65 03 01 Hong Kong Tel: 2886-9318 • Sucursal en España Madrid, Spain Tel: 091-504 27 87 • Succursale Française Vélizy-Villacoublay, France Tel: 01-30-67 58 00 • Filiale Italiana Milano, Italy Tel: 02-66 75 41 • Branch The Netherlands Eindhoven, The Netherlands Tel: 040-244 58 45 • Tyskland Filial Taeby, Sweden Tel: 08-63 80 820 NEC Electronics Hong Kong Ltd. Seoul Branch Seoul, Korea Tel: 02-558-3737 NEC Electronics Shanghai, Ltd. Shanghai, P.R. China Tel: 021-6841-1138 NEC Electronics Taiwan Ltd. Taipei, Taiwan Tel: 02-2719-2377 NEC Electronics Singapore Pte. Ltd. Novena Square, Singapore Tel: 6253-8311 • United Kingdom Branch Milton Keynes, UK Tel: 01908-691-133 J03.4 4 User’s Manual U16499EJ1V0UM INTRODUCTION Product Overview The IE-789860-NS-EM1 is designed to be used with the IE-78K0S-NS or IE-78K0S-NS-A to debug the following target devices that belong to the 78K/0S Series of 8-bit single-chip microcontrollers. Target Readers • µPD789860 Subseries: µPD789860, 78E9860A • µPD789861 Subseries: µPD789861, 78E9861A • µPD789052 Subseries: µPD789052, 78E9860 • µPD789062 Subseries: µPD789062, 78E9861 This manual is intended for engineers who will use the IE-789860-NS-EM1 with the IE78K0S-NS or IE-78K0S-NS-A to perform system debugging. Engineers who use this manual are expected to be thoroughly familiar with the target device’s functions and use methods and to be knowledgeable about debugging. Organization When using the IE-789860-NS-EM1, refer to not only this manual (supplied with the IE789860-NS-EM1) but also the manual that is supplied with the IE-78K0S-NS or IE78K0S-NS-A. IE-78K0S-NS IE-789860-NS-EM1 User’s Manual User’s Manual • Basic specifications • General • System configuration • Part names • External interface functions • Installation • Differences between target device and target interface circuit • Cautions IE-78K0S-NS-A User’s Manual • Basic specifications • System configuration • External interface functions Purpose This manual’s purpose is to explain various debugging functions that can be performed when using the IE-789860-NS-EM1. User’s Manual U16499EJ1V0UM 5 Terminology The meanings of certain terms used in this manual are listed below. Term Meaning Emulation device This is a general term that refers to the device in the emulator that is used to emulate the target device. It includes the emulation CPU. Emulation CPU This is the CPU block in the emulator that is used to execute user-generated programs. Target device This is the device to be emulated. Target system This includes the target program and the hardware provided by the user. When defined narrowly, it includes only the hardware. IE system This refers to the combination of the in-circuit emulator (IE-78K0S-NS or IE-78K0S-NS-A) and the emulation board (IE-789860-NS-EM1). Conventions Related Documents Data significance: Higher digits on the left and lower digits on the right Note: Footnote for item marked with Note in the text Caution: Information requiring particular attention Remark: Supplementary information The related documents (user’s manuals) indicated in this publication may include preliminary versions. However, preliminary versions are not marked as such. Document Name IE-78K0S-NS In-Circuit Emulator U13549E IE-78K0S-NS-A In-Circuit Emulator U15207E IE-789860-NS-EM1 Emulation Board This manual ID78K Series Integrated Debugger Ver. 2.30 or Later Operation (Windows™ Based) U15185E µPD789860, 789861 Subseries U14826E µPD789052, 789062 Subseries U15861E Caution The related documents listed above are subject to change without notice. Be sure to use the latest version of each document for designing. 6 Document No. User’s Manual U16499EJ1V0UM CONTENTS CHAPTER 1 GENERAL...........................................................................................................................10 1.1 System Configuration................................................................................................................................ 11 1.2 Hardware Configuration ............................................................................................................................ 13 1.3 Basic Specifications .................................................................................................................................. 14 CHAPTER 2 PART NAMES ....................................................................................................................15 2.1 Parts of Main Unit ...................................................................................................................................... 16 2.2 Initial Settings of Switches and Jumpers ................................................................................................ 17 CHAPTER 3 INSTALLATION..................................................................................................................18 3.1 Connection ................................................................................................................................................. 19 3.2 Switch and Jumper Settings on Main Unit .............................................................................................. 20 3.3 Setting Power Supply Voltage of Target Interface.................................................................................. 21 3.4 Clock Settings ............................................................................................................................................ 22 3.5 3.6 3.4.1 Overview of clock settings ............................................................................................................. 22 3.4.2 System clock settings .................................................................................................................... 24 Mask Option Settings ................................................................................................................................ 28 3.5.1 Mask option settings ...................................................................................................................... 28 3.5.2 Mask options of POC circuit .......................................................................................................... 29 3.5.3 Mask options of oscillation stabilization wait time.......................................................................... 29 External Trigger ......................................................................................................................................... 30 CHAPTER 4 DIFFERENCES BETWEEN TARGET DEVICE AND TARGET INTERFACE CIRCUIT....31 CHAPTER 5 CAUTIONS .........................................................................................................................35 APPENDIX A EMULATION PROBE PIN ASSIGNMENT TABLE ..........................................................36 APPENDIX B CAUTIONS ON DESIGNING TARGET SYSTEM .............................................................37 User’s Manual U16499EJ1V0UM 7 LIST OF FIGURES Figure No. Title Page 1-1 System Configuration ....................................................................................................................................... 11 1-2 Basic Hardware Configuration .......................................................................................................................... 13 2-1 IE-789860-NS-EM1 Part Names....................................................................................................................... 16 3-1 Connection of Emulation Probe ........................................................................................................................ 19 3-2 Connecting TP1 and Target System Power Supply Voltage ............................................................................ 21 3-3 External Circuits Used as System Clock Oscillator .......................................................................................... 22 3-4 When Using Clock That Is Already Mounted on Emulation Board.................................................................... 23 3-5 When Using User-Mounted Clock .................................................................................................................... 23 3-6 When Supplying Pulse from Target System ..................................................................................................... 24 3-7 Connections on Parts Board............................................................................................................................. 25 3-8 Crystal Oscillator............................................................................................................................................... 26 3-9 Pin Alignment of Crystal Oscillator and Socket ................................................................................................ 27 3-10 Mask Option Setting ......................................................................................................................................... 28 3-11 External Trigger Input Position ......................................................................................................................... 30 4-1 Equivalent Circuit 1 of Emulation Circuit........................................................................................................... 32 4-2 Equivalent Circuit 2 of Emulation Circuit........................................................................................................... 33 4-3 Equivalent Circuit 3 of Emulation Circuit........................................................................................................... 34 B-1 Distance Between In-Circuit Emulator and Conversion Socket ........................................................................ 37 B-2 Connection Conditions of Target System ......................................................................................................... 38 8 User’s Manual U16499EJ1V0UM LIST OF TABLES Table No. Title Page 1-1 Correspondence Between Emulation Probe and Conversion Socket ...............................................................12 1-2 Basic Specifications ..........................................................................................................................................14 2-1 Initial Settings of Switches and Jumpers ...........................................................................................................17 3-1 Switch and Jumper Settings on IE-78K0S-NS...................................................................................................20 3-2 Switch and Jumper Settings on IE-78K0S-NS-A ...............................................................................................20 3-3 Setting Power Supply of Target Interface..........................................................................................................21 3-4 Main System Clock Settings..............................................................................................................................24 3-5 Mask Option Setting of Port 4............................................................................................................................28 3-6 Differences in Oscillation Stabilization Wait Time .............................................................................................29 5-1 Illegal Access Conditions for EEPROM.............................................................................................................35 A-1 NP-20GS Pin Assignments ...............................................................................................................................36 B-1 Distance Between IE System and Conversion Socket ......................................................................................37 User’s Manual U16499EJ1V0UM 9 CHAPTER 1 GENERAL This chapter describes the IE-789860-NS-EM1’s system configuration and basic specifications. The IE-789860-NS-EM1 is a development tool for efficient debugging of hardware or software when using one of the following target devices that belong to the 78K/0S Series of 8-bit single-chip microcontrollers. • Target devices • µPD789860 Subseries • µPD789861 Subseries • µPD789052 Subseries • µPD789062 Subseries 10 User’s Manual U16499EJ1V0UM CHAPTER 1 GENERAL 1.1 System Configuration Figure 1-1 illustrates the IE-789860-NS-EM1’s system configuration. Figure 1-1. System Configuration Device fileNote 1 (available separately) Debugger ID78K0S-NS (sold separately) Control software Host machine PC-9800 Series, IBM PC/AT™ or compatibles Interface board IE-70000-98-IF-C (sold separately) Interface board IE-70000-PC-IF-C (sold separately) Interface board IE-70000-PCI-IF-A (sold separately) Interface card or Interface cable Interface cable (NS IF Cable) IE-78K0S-NS or IE-78K0S-NS-A (sold separately) In-circuit emulator NS CARD MC CARD Cable Cable IE-70000-CD-IF-A (sold separately) FG Cable IE-789860-NS-EM1 (this product) AC adapter IE-70000-MC-PS-B (sold separately) Emulation probeNote 2 (sold separately) Conversion socket (sold separately) User’s Manual U16499EJ1V0UM 11 CHAPTER 1 GENERAL Notes 1. The device file is as follows, in accordance with the subseries. µS××××DF789861: µPD789860, 789861 Subseries µS××××DF789062: µPD789052, 789062 Subseries The device file can be downloaded from the website of NEC Electronics (http://www.necel.com/micro/). 2. The emulation probe NP-20GS is a product of Naito Densei Machida Mfg. Co., Ltd. For further information, contact Naito Densei Machida Mfg. Co., Ltd. (TEL: +81-45-475-4191). Table 1-1. Correspondence Between Emulation Probe and Conversion Socket Package 20-pin plastic SSOP (MC type) 12 Emulation Probe NP-20GS (probe length: 200 mm) User’s Manual U16499EJ1V0UM Conversion Socket EV-9500GS-20 CHAPTER 1 GENERAL 1.2 Hardware Configuration Figure 1-2 shows the IE-789860-NS-EM1’s position in the basic hardware configuration. Figure 1-2. Basic Hardware Configuration Dedicated bus interface IE system Host machine Interface board (sold separately) IE-78K0S-NS or IE-78K0S-NS-A IE-789860-NS-EM1 78K0S main board (sold separately) Emulation board (this product) Interface card (sold separately) User’s Manual U16499EJ1V0UM Emulation probe (sold separately) 13 CHAPTER 1 GENERAL 1.3 Basic Specifications The basic specifications of the IE-789860-NS-EM1 are listed in Table 1-2. Table 1-2. Basic Specifications Item Description Target device µPD789860, 789861, 789052, 789062 Subseries System clock 1.0 to 5.0 MHz System clock supply External: Input via an emulation probe from the target system Internal: Mounted on emulation board (5 MHz), or mounted on the parts board by the user Target interface voltage VDD = 1.8 to 5.5 V (same as that of target device) Operates on internal power supply (5 V) when target system is not connected 14 User’s Manual U16499EJ1V0UM CHAPTER 2 PART NAMES This chapter introduces the parts of the IE-789860-NS-EM1 main unit. The packing box contains the emulation board (IE-789860-NS-EM1), packing list, user’s manual, and guarantee card. If there are any missing or damaged items, please contact an NEC Electronics sales representative. Fill out and return the guarantee card that comes with the main unit. User’s Manual U16499EJ1V0UM 15 CHAPTER 2 PART NAMES 2.1 Parts of Main Unit Figure 2-1 shows the part names of the IE-789860-NS-EM1. Figure 2-1. IE-789860-NS-EM1 Part Names P1 GND TP1 LVcc (CP12) EXTOUT (CP11) EXTIN P3 User’s Manual U16499EJ1V0UM CN1 USER VDD LED1 IC5 P2 16 CN1 probe connector 20GS SW1 ON OFF X1 IE-789860-NS-EM1 X1 system clock socket CHAPTER 2 PART NAMES 2.2 Initial Settings of Switches and Jumpers Table 2-1 shows the initial settings of the switches and jumpers on the IE-789860-NS-EM1. For the setting of SW1, refer to 3.5 Mask Option Settings. Table 2-1. Initial Settings of Switches and Jumpers SW1 Initial setting 1 2 3 4 OFF OFF OFF OFF User’s Manual U16499EJ1V0UM 17 CHAPTER 3 INSTALLATION This chapter describes methods for connecting the IE-789860-NS-EM1 to the IE-78K0S-NS or IE-78K0S-NS-A, emulation probe, etc. Mode setting methods are also described. Caution Connecting or removing components to or from the target system, or making switch or other setting changes must be carried out after the power supply to both the IE system and the target system has been switched OFF. 18 User’s Manual U16499EJ1V0UM CHAPTER 3 3.1 INSTALLATION Connection (1) Connection with IE-78K0S-NS or IE-78K0S-NS-A main unit See the IE-78K0S-NS User’s Manual (U13549E) for a description of how to connect the IE-789860-NS-EM1 to Note the IE-78K0S-NS . Note When using the IE-78K0S-NS-A, see the IE-78K0S-NS-A User’s Manual (U15207E). (2) Connection with emulation probe See the IE-78K0S-NS User’s Manual (U13549E) for a description of how to connect an emulation probe to the IE-789860-NS-EM1 Note . On this board, connect the emulation probe to CN1. Note When using the IE-78K0S-NS-A, see the IE-78K0S-NS-A User’s Manual (U15207E). Caution Incorrect connection may damage the IE system. Be sure to read the emulation probe’s user’s manual for a detailed description of the connection method. Figure 3-1. Connection of Emulation Probe Emulation probe (sold separately) CN1 20GS IE-789860-NS-EM1 Main board of IE-78K0S-NS (sold separately) or IE-78K0S-NS-A (sold separately) User’s Manual U16499EJ1V0UM 19 CHAPTER 3 3.2 INSTALLATION Switch and Jumper Settings on Main Unit (1) Settings on the IE-78K0S-NS When using the IE-789860-NS-EM1, set the switches and jumpers on the IE-78K0S-NS as shown in Table 3-1. For details of these switch and jumper settings, refer to the IE-78K0S-NS User’s Manual (U13549E). Table 3-1. Switch and Jumper Settings on IE-78K0S-NS Setting Caution SW1 SW3 SW4 JP1 JP4 OFF All switches ON (fixed) All switches ON (fixed) 2 and 3 shorted 1 and 2 shorted Incorrect setting may damage the IE-789860-NS-EM1. (2) Settings on the IE-78K0S-NS-A When using the IE-789860-NS-EM1, set the switches and jumpers on the IE-78K0S-NS-A as shown in Table 32. For details of these switch and jumper settings, refer to the IE-78K0S-NS-A User’s Manual (U15207E). Table 3-2. Switch and Jumper Settings on IE-78K0S-NS-A Setting Caution 20 SW1 JP1 JP3 OFF 1 and 2 shorted Shorted (fixed) Incorrect setting may damage the IE-789860-NS-EM1. User’s Manual U16499EJ1V0UM CHAPTER 3 3.3 INSTALLATION Setting Power Supply Voltage of Target Interface In the IE system, emulation is possible with a voltage of the same level as the power supply voltage of the target system. When the target system is not connected, the IE system automatically operates with the emulator’s internal power supply (5 V). When debugging with a voltage that is the same level as that of the target system, supply the same voltage as that of the target system to the TP1 terminal pin of the IE-789860-NS-EM1 (the same applies when the voltage is 5 V). Set the target voltage to between 1.8 and 5.5 V. For how to select the operating power supply, refer to the ID78K Series Ver.2.30 or Later Operation (Windows Based) User’s Manual (U15185E). • Maximum current consumption of TP1 2.0 V: approximately 100 mA to 5.5 V: approximately 300 mA Table 3-3. Setting Power Supply of Target Interface Integrated Debugger (ID78K0S-NS) Power Supply of Target Interface (LVCC) Operating Power Supply Selection When connecting target system When not connecting target system 1.8 to 5.5 V Target 5V Internal Figure 3-2. Connecting TP1 and Target System Power Supply Voltage IE-789860-NS-EM1 LED1 CN1 20GS LVCC GND TP1 Emulation probe Target system VDD GND Target system power supply voltage Caution Before connecting TP1 on the board and the target system power supply voltage, turn off the power to the IE-78K0S-NS or IE-78K0S-NS-A. Remark The VDD pin on the target system is exclusively used to control LED1 (USER VDD) that monitors whether the power supply of the target system is connected in the IE-789860-NS-EM1. User’s Manual U16499EJ1V0UM 21 CHAPTER 3 3.4 INSTALLATION Clock Settings 3.4.1 Overview of clock settings The system clock to be used during debugging can be selected from (1) to (3) below. (1) Clock that is already mounted on emulation board (2) Clock that is mounted by user (3) Pulse input from target system If the target system includes a clock oscillator, select either (1) Clock that is already mounted on emulation board or (2) Clock that is mounted by user. For the clock oscillator, a resonator is connected to the target device and the target device’s internal oscillator is used. An example of the external circuit is shown in part (a) of Figure 3-3. During emulation, the oscillator that is mounted on the target system is not used. Instead, the clock that is mounted on the emulation board installed in the IE-78K0S-NS or IE-78K0S-NS-A is used. If the target system includes an external clock, select either (1) Clock that is already mounted on emulation board, (2) Clock that is mounted by user, or (3) Pulse input from target system. For the external clock, a clock signal is supplied from outside of the target device and the target device’s internal oscillator is not used. An example of the external circuit is shown in part (b) of Figure 3-3. Caution The IE system will be hung-up if the main system clock is not supplied normally. Moreover, be sure to input a rectangular wave as the pulse from the target system. There is no need to supply a clock to the X2 pin. Also, even if a crystal resonator is connected directly to X1 (for the main system clock), the target device will not operate. When emulating the µPD789861 Subseries, RC oscillation cannot be used. Figure 3-3. External Circuits Used as System Clock Oscillator (a) Clock oscillator (b) External clock Target device Target device VSS External clock X2 X1 X2 Crystal or ceramic resonator 22 X1 User’s Manual U16499EJ1V0UM CHAPTER 3 INSTALLATION (1) Clock that is already mounted on emulation board The crystal oscillator mounted on the IE-789860-NS-EM1 can be used. A crystal oscillator (X1) is already mounted on the emulation board. Its frequency is 5.0 MHz. Figure 3-4. When Using Clock That Is Already Mounted on Emulation Board IE-78K0S-NS or IE-78K0S-NS-A Target system IE-789860-NS-EM1 Emulation probe X1 Mounted oscillator (used) Clock oscillator or external clock (not used) Remark The clock that is supplied by the oscillator of the IE-789860-NS-EM1 (encircled in the figure) is used. (2) Clock that is mounted by user The user can mount any clock supported by the set specifications on the IE-789860-NS-EM1. This feature is effective when debugging at a different frequency than the clock already mounted. Remove the crystal oscillator (X1) that is already mounted on the emulation board, and mount the parts board on which the resonator to be used is mounted or mount the oscillator to be used. Figure 3-5. When Using User-Mounted Clock IE-78K0S-NS or IE-78K0S-NS-A Target system IE-789860-NS-EM1 X1 Emulation probe Parts board + resonator or oscillator (used) Clock oscillator or external clock (not used) Remark The clock that is supplied by the resonator of the IE-789860-NS-EM1 (encircled in the figure) or the oscillator is used. User’s Manual U16499EJ1V0UM 23 CHAPTER 3 INSTALLATION (3) Pulse input from target system An external clock on the target system can be used as system clock via an emulation probe. Figure 3-6. When Supplying Pulse from Target System IE-78K0S-NS or IE-78K0S-NS-A Target system IE-789860-NS-EM1 X1 Emulation probe Mounted oscillator and resonator (not used) External clock (used) Remark The pulse that is supplied by the external clock on the target system (encircled in the figure) is used. 3.4.2 System clock settings Table 3-4 shows the system clock settings of the IE-789860-NS-EM1 when the system clocks in (1) to (3) are used. Table 3-4. Main System Clock Settings Frequency of Main System Clock IE-789860-NS-EM1 X1 Socket (1) When using clock that is already mounted on emulation board 5.0 MHz (2) When using clock mounted by user Other than 5.0 MHz Oscillator configured by user (3) When inputting pulse from target system Caution Oscillator Oscillator (not used) CPU Clock Source Selection (ID78K0S-NS) Internal External When inputting a pulse from the target system, open the configuration dialog box when starting the integrated debugger (ID78K0S-NS) and select “External” in the area (Clock) for selecting the CPU’s clock source (this selects the user’s clock). Remark The factory settings of the IE-789860-NS-EM1 are those listed above under “when using clock that is already mounted on emulation board”. (1) When using clock that is already mounted on emulation board When the IE-789860-NS-EM1 is shipped, a 5.0 MHz crystal oscillator is already mounted in the IE-789860-NSEM1’s X1 socket. When using the factory-set mode settings, there is no need to make any other hardware settings. When starting the integrated debugger (ID78K0S-NS), open the configuration dialog box and select “Internal” in the area (Clock) for selecting the CPU’s clock source (this selects the emulator’s internal clock). 24 User’s Manual U16499EJ1V0UM CHAPTER 3 INSTALLATION (2) When using clock mounted by user Perform the settings described under either (a) or (b), depending on the type of clock to be used. When starting the integrated debugger (ID78K0S-NS), open the configuration dialog box and select “Internal” in the area (Clock) for selecting the CPU’s clock source (this selects the emulator’s internal clock). (a) When using a ceramic resonator or crystal resonator • Items to be prepared • Parts board • Capacitor CA • Ceramic resonator or crystal resonator • Capacitor CB • Resistor Rx • Solder kit <Steps> <1> Solder the target ceramic resonator or crystal resonator, resistor Rx, capacitor CA, and capacitor CB (all with suitable oscillation frequencies) onto the parts board (as shown below). Figure 3-7. Connections on Parts Board Parts board (X1) Pin No. Connection 1 14 2 13 2-13 Capacitor CA 3 12 3-12 Capacitor CB 4 11 4-11 Ceramic resonator or crystal resonator 5 10 5-10 Resistor Rx 6 9 8-9 Shorted 7 8 Circuit diagram 1 MΩ HCU04 HCU04 5 Rx 10 4 3 CB 12 Remark 98 CLOCK OUT 11 13 CA 2 The sections enclosed in broken lines indicate parts that are attached to the parts board. User’s Manual U16499EJ1V0UM 25 CHAPTER 3 INSTALLATION <2> Prepare the IE-789860-NS-EM1. <3> Remove the crystal oscillator that is mounted in the IE-789860-NS-EM1’s X1 socket. <4> Connect the parts board (from <1> above) to the X1 socket from which the crystal oscillator was removed (in <3> above). Check the pin 1 mark to make sure the board is mounted in the correct direction. <5> Make sure that the parts board is wired as shown in Figure 3-7 above. <6> Install the IE-789860-NS-EM1 in the IE-78K0S-NS or IE-78K0S-NS-A. The above steps configure the following circuit and enable supply of the clock from the mounted resonator to the emulation device. (b) When using a crystal oscillator • Items to be prepared • Crystal oscillator (see pinouts shown in Figure 3-8) Figure 3-8. Crystal Oscillator NC GND VCC CLOCK OUT <Steps> <1> Prepare the IE-789860-NS-EM1. <2> Remove the crystal oscillator that is mounted in the IE-789860-NS-EM1’s X1 socket. <3> Connect a crystal oscillator to the X1 socket from which the crystal oscillator was removed (in <2> above). Insert the pins of the crystal oscillator into the socket aligning the pins as shown in the figure below. 26 User’s Manual U16499EJ1V0UM CHAPTER 3 INSTALLATION Figure 3-9. Pin Alignment of Crystal Oscillator and Socket Crystal oscillator NC GND Socket VCC CLOCK OUT Crystal Oscillator Pin Name Socket Pin No. 1 14 NC 1 2 13 GND 7 3 12 CLOCK OUT 8 4 11 5 10 VCC 14 6 9 7 8 <4> Install the IE-789860-NS-EM1 in the IE-78K0S-NS or IE-78K0S-NS-A. (3) When inputting pulse from target system No hardware settings are required for this situation. When starting the integrated debugger (ID78K0S-NS), open the configuration dialog box and select “External” in the area (Clock) for selecting the CPU’s clock source (this selects the user’s clock). User’s Manual U16499EJ1V0UM 27 CHAPTER 3 3.5 INSTALLATION Mask Option Settings 3.5.1 Mask option settings By setting the DIP switch (SW1) in the IE-789860-NS-EM1, a 33 kΩ pull-up resistor can be connected to P40 to P43 by mask option. Use the mask option setting dialog box of the integrated debugger (ID78K0S-NS) to set the mask option. When reading a project file, however, setting is not required. The results of reading a project file are reflected in the mask option setting dialog box. For the usage method, refer to the ID78K Series Ver.2.30 or Later Operation (Windows Based) User’s Manual (U15185E). Table 3-5. Mask Option Setting of Port 4 SW1 Connected to: 1 2 3 4 P40 P41 P42 P43 When the DIP switch is ON, the corresponding pin is pulled up by the target interface power supply voltage (LVCC). When it is OFF, the corresponding pull-up resistor is disconnected. Set the DIP switch to OFF for ports that do not exist. Figure 3-10. Mask Option Setting Target LVCC 33 kΩ SW1 Probe Emulation CPU P40 P40 P41 P41 P42 P42 P43 P43 100 Ω P40 P41 P42 P43 4 3 2 1 ON O F F The initial setting of all these switches is OFF. OFF SW1 28 User’s Manual U16499EJ1V0UM CHAPTER 3 INSTALLATION 3.5.2 Mask options of POC circuit The IE-789860-NS-EM1 includes a “POC switching circuit” that controls the power-on-clear circuit functions by software. Perform the ON/OFF settings using an SFR. When emulating the detection voltage of the low-voltage detection circuit and power-on-clear circuit, the detection TM voltage must be finally checked with EEPROM products because of the effect of power supply fluctuations and noise. 3.5.3 Mask options of oscillation stabilization wait time 7 The oscillation stabilization wait time of the IE-789860-NS-EM1 is fixed to 2 /fX. The differences between target devices are shown in Table 3-6 below. When emulating the oscillation stabilization wait time after the release of STOP mode by RESET or the release of reset via the POC circuit, the oscillation stabilization wait time must be finally checked with EEPROM products because of the effect of power supply fluctuations and noise. Table 3-6. Differences in Oscillation Stabilization Wait Time IE-789860-NSEM1 Oscillation stabilization wait time after release of STOP mode by RESET or release of reset via POC circuit 7 2 /fX µPD789052 µPD78E9860 15 2 /fX µPD789062 µPD78E9861 7 2 /fCC User’s Manual U16499EJ1V0UM µPD789860 µPD789861 215/fX or 217/fX can be selected by mask option 27/fCC 29 CHAPTER 3 3.6 INSTALLATION External Trigger To set an external trigger, connect the IE-789860-NS-EM1’s check pins EXTOUT and EXTIN as shown below. See the IE-78K0S-NS User’s Manual (U13549E) or IE-78K0S-NS-A User’s Manual (U15207E) for pin characteristics. For the use methods, see the ID78K Series Ver.2.30 or Later Operation (Windows Based) User’s Manual (U15185E). (1) EXTOUT The EXTOUT pin on the IE-789860-NS-EM1 outputs a low level for 1.3 µs when a break event occurs. Caution Connect a pull-up resistor on the target system because this is an open drain output. (2) EXTIN An event signal can be input from the EXTIN pin on the IE-789860-NS-EM1. Input a high-level pulse signal for 2 CPU operation clocks or more. Figure 3-11. External Trigger Input Position IE-789860-NS-EM1 X1 IC5 SW1 TP1 LED1 CN1 USER VDD (CP12) EXTOUT (CP11) EXTIN 30 User’s Manual U16499EJ1V0UM External trigger CHAPTER 4 DIFFERENCES BETWEEN TARGET DEVICE AND TARGET INTERFACE CIRCUIT This chapter describes differences between the target device’s signal lines and the signal lines of the target interface circuit of the IE system. The target interface circuit of the IE system realizes emulation via an emulation circuit configured by an emulation CPU, TTL, CMOS-IC, and other components. The electrical characteristics are different from those of the target device because a protector and other circuits are provided. (1) Signals directly input to or output from the emulation CPU (2) Signals input from the target system via a gate (3) Other signals The circuits of the IE-789860-NS-EM1 are used as follows for signals listed in (1) to (3) above. The same applies to handling alternate-function pins, for which no circuit is provided in the IE system. User’s Manual U16499EJ1V0UM 31 CHAPTER 4 DIFFERENCES BETWEEN TARGET DEVICE AND TARGET INTERFACE CIRCUIT (1) Signals directly input to or output from the emulation CPU Refer to Figure 4-1 Equivalent Circuit 1 of Emulation Circuit. The following signals operate the same as in the µPD789052, 789062, 789860, and 789861 Subseries. Note that for the following signals, a 1 MΩ pull-down resistor and a 100 Ω resistor are connected in series. Signals related to port 0 are connected to a 1 MΩ pull-down resistor in the IE-78K0S-NS or IE-78K0S-NS-A. • Signals related to port 0 • Signals related to port 2 A 33 kΩ pull-up resistor is connected to the following signals by setting the switch. • Signals related to port 4 Figure 4-1. Equivalent Circuit 1 of Emulation Circuit • Probe side • IE system side (Target system) (IE-789860-NS-EM1) Port 0 100 Ω Port 0 Port 2 Port 2 1 MΩ LVCC 33 kΩ 100 Ω Port 4 32 SW1 Port 4 User’s Manual U16499EJ1V0UM CHAPTER 4 DIFFERENCES BETWEEN TARGET DEVICE AND TARGET INTERFACE CIRCUIT (2) Signals input from the target system via a gate Since the following signals are input via a gate, their timing shows a delay compared to the µPD789052, 789062, 789860, and 789861 Subseries. Refer to Figure 4-2 Equivalent Circuit 2 of Emulation Circuit. • RESET signal • Signals related to clock input The X2 (CL2) pin is not used in the IE-789860-NS-EM1. Figure 4-2. Equivalent Circuit 2 of Emulation Circuit • Probe side • IE system side LVCC (Target system) (IE-789860-NS-EM1) 4.7 kΩ 100 Ω HC4066 RESET RESET LVCC HSK120 100 Ω X1 (CL1) X1 1 MΩ X2 (CL2) HSK120 OPEN User’s Manual U16499EJ1V0UM 33 CHAPTER 4 DIFFERENCES BETWEEN TARGET DEVICE AND TARGET INTERFACE CIRCUIT (3) Other signals Refer to Figure 4-3 Equivalent Circuit 3 of Emulation Circuit. • VDD pin The power supply of the emulation CPU operates on the internal power supply voltage (5 V) when the target system is not connected, and on the voltage (LVCC) supplied from the power voltage supply pin (TP1) when the target system is connected. In the IE-789860-NS-EM1, the VDD pin of the target system is exclusively used for controlling LED1 (USER VDD), which monitors whether the power of the target system is on. • VSS pin The VSS pin is connected to GND in the IE-789860-NS-EM1. • IC/VPP pin The IC/VPP pin is not used in the IE-789860-NS-EM1. Figure 4-3. Equivalent Circuit 3 of Emulation Circuit • Probe side • IE system side (Target system) (IE-789860-NS-EM1) 100 Ω + − VDD 0.1 µ F G6H-2F (Relay) 22 µ F 100 Ω 1 MΩ VSS TP1 (GND) IC/VPP 34 µ PC393 Power supply generation + − + Power supply detection 1 MΩ Filter TP1 (LVCC) µPC393 OPEN User’s Manual U16499EJ1V0UM CHAPTER 5 CAUTIONS This chapter describes differences between the target device specifications and the IE system specifications. The emulation circuit of the IE system realizes emulation via a configuration of emulation CPU, TTL, CMOS-IC, and other components. Therefore, the target device specifications are different from the IE system specifications. (1) The RC oscillator cannot be emulated in the IE-789860-NS-EM1. For the oscillator, only the functions described in 3.4 Clock Settings can be emulated. (2) When emulating the detection voltage of the low-voltage detection circuit and power-on-clear circuit in the IE789860-NS-EM1, the detection voltage must be finally checked with EEPROM products because of the effect of power supply fluctuations and noise. (3) If a program that illegally accesses EEPROM is executed in the IE-789860-NS-EM1, the error message “Unspecified illegal” is displayed and a break occurs. The illegal access conditions for EEPROM are shown in Table 5-1. Table 5-1. Illegal Access Conditions for EEPROM <1> If a write instruction is executed to EEPROM when EWC = 0 <2> If a write instruction is executed to EEPROM while the clock selected by EEPROM is stopped <3> If a write instruction is executed to EEPROM while EEPROM is being written <4> If read instruction is executed from EEPROM while EEPROM is being written <5> If instruction fetch is executed from EEPROM while EEPROM is being written <6> If EWC = 0 is set while EEPROM is being written <7> If the main clock is stopped while EEPROM is being written <8> If the count clock selection of the write time setting timer is changed and executed while EEPROM is being written <9> If RESET is input while EEPROM is being written (4) The IE-789860-NS-EM1 includes a “POC switching circuit” that controls the power-on-clear (POC) circuit functions by software. Perform the ON/OFF settings using an SFR. (5) The oscillation stabilization wait time after the release of STOP mode by RESET or the release of reset via 7 the POC circuit is fixed to “2 /fX” in the IE-789860-NS-EM1. For the mask options, only the functions described in 3.5 Mask Option Settings can be emulated. User’s Manual U16499EJ1V0UM 35 APPENDIX A EMULATION PROBE PIN ASSIGNMENT TABLE Table A-1. NP-20GS Pin Assignments Emulation Probe CN1 Pin No. Emulation Probe CN1 Pin No. 1 33 11 16 2 32 12 15 3 74 13 14 4 31 14 13 5 75 15 6 6 34 16 5 7 7 17 4 8 8 18 3 9 9 19 17 10 10 20 73 Remarks 1. NP-20GS is a product of Naito Densei Machida Mfg. Co., Ltd. 2. The numbers in the “Emulation Probe” column indicate the pin number on the tip of the target system side with NP-20GS and EV-9500GS-20 combined together. 36 User’s Manual U16499EJ1V0UM APPENDIX B CAUTIONS ON DESIGNING TARGET SYSTEM The following shows the conditions when connecting the emulation probe to the conversion socket. Follow the configuration below and consider the shape of parts to be mounted on the target system when designing a system. Among the products described in this appendix, NP-20GS is a product of Naito Densei Machida Mfg. Co., Ltd. Table B-1. Distance Between IE System and Conversion Socket Emulation Probe NP-20GS Conversion Socket EV-9500GS-20 Distance Between IE System and Conversion Socket 185 mm Figure B-1. Distance Between In-Circuit Emulator and Conversion Socket In-circuit emulator IE-78K0S-NS or IE-78K0S-NS-A Target system Emulation board IE-789860-NS-EM1 CN1 185 mm Emulation probe NP-20GS Conversion socket EV-9500GS-20 User’s Manual U16499EJ1V0UM 37 APPENDIX B CAUTIONS ON DESIGNING TARGET SYSTEM Figure B-2. Connection Conditions of Target System Emulation board IE-789860-NS-EM1 Conversion socket EV-9500GS-20 Emulation probe NP-20GS 100 mm 30 mm Target system 38 User’s Manual U16499EJ1V0UM 15 mm