background image

( 34 / 54 )

(2) Debugging Procedure for CPU Rewrite Mode (Boot Mode)

Here following describe the debugging procedure in boot mode. Figure 4.3 shows the memory map
when debugging.

Figure 4.3 Memory map when debugging in boot mode

(4)

(2)

Inside of MCU

(MAP: "EXT")

Emulation memory

(MAP: "INT")

SFR area

RAM area

Boot ROM area

(5)

User ROM area

00000h

00400h

DE000h

E0000h

FFFFFh

Procedure

Description

Downloading the control program for CPU rewrite mode
• You must execute custom command dbg_reset before debugging the control program for

CPU rewrite mode.

• Download the control program for CPU rewrite mode into emulation memory. Also,

download the value of the reset vector, DE000h. When you do not download the value of
the reset vector, write "DE000h" in the reset vector area using Fill command.

• After downloading the control program, set a breakpoint as indicated below. (See the next

page, Table 4.3 for an example.)
"Stop after jumping to the RAM area, and before setting the CPU rewrite mode select bit to "1"."

Transfer the control program for CPU rewrite mode to the RAM area.
• Running the program transfers the control program for CPU rewrite mode to the RAM area

(emulation memory).

Set the map for user ROM area E0000h to FFFDFh to "EXT".
• Using the breakpoint set in (1), stop program execution after jumping to RAM area, and

before the CPU rewrite mode select bit is set to "1".

• Set the MAP for addresses E0000h to FFFDFh to "EXT" (to enable the evaluation MCU).
• Set a breakpoint as indicated below. (See the next page, Table 4.3 for an example).

"Stop immediately before jumping to user ROM area."

Write to flash memory.
• Flash memory is rewritten to by running the control program. See "4.5 Precautions for CPU

Rewrite Mode" (page 37) for notes.

• Using the breakpoint set in step (3), stop at the end of the control program for CPU rewrite

mode.

• Set the program window to disassemble display mode (DIS) and execute the instruction

that jumps to the user ROM area in step mode.

Check the contents of MCU's internal flash memory after rewriting.

In step (4), by changing the settings as shown below, you can read the contents of the
MCU's internal flash memory using the script command, dump window and RAM monitor
window. For details on how to access, refer to Section 4.4 (page 36) and the precautions
to Section 4.5 (page 37).

(1)

(2)

(3)

(4)

(5)

Unused

(3)

(1)

Item

Setting

Map of addresses E0000h - FFFDFh

EXT

CPU rewrite mode select bit (FMCR1)

1

Mode of flash memory

Read array mode

Summary of Contents for M30220TF-PRB

Page 1: ...ok over all the business of both companies Therefore although the old company name remains in this document it is a valid Renesas Electronics document We appreciate your understanding Renesas Electron...

Page 2: ...t for an application categorized as Specific or for which the product is not intended where you have failed to obtain the prior written consent of Renesas Electronics The quality grade of each Renesas...

Page 3: ...M30220TF PRB User s Manual User s Manual Rev 1 00 2003 09 Pod Probe for M30220 and M30221 Group MCUs...

Page 4: ...chnology Corporation and Renesas Solutions Corporation assume no responsibility for any damage liability or other loss resulting from the information contained herein Renesas Technology semiconductors...

Page 5: ...U rewrite mode For detail information about the emulator main unit emulation pod main unit and emulator debugger refer to each user s manual Emulator main unit PC4701 User s Manual Emulation pod main...

Page 6: ...e 28 4 2 Using Custom Commands dbg_reset and fmcr1set 29 1 Custom Command dbg_reset 29 2 Custom Command fmcr1set 30 4 3 Debugging Procedure 32 1 Debugging Procedure for CPU Rewrite Mode Microcomputer...

Page 7: ...r When Starting Up the Emulator Debugger When the target system is connected 47 3 Errors Occur When Starting Up the Emulator Debugger When the target system is not connected 48 6 2 Operation Differs f...

Page 8: ...ontrols the emulator hardware This program is installed in the EEPROM in the emulator main unit This program is downloadable from the emulator debugger to upgrade the firmware or to support other MCUs...

Page 9: ...r product 1 1 Safety Symbols and Meanings 8 Note on Final Evaluation 9 Note on Differences between Actual MCU and Emulator 9 Note on Clock Supply to the MCU 10 Notes on Interrupts 10 Notes on DMA Tran...

Page 10: ...and Meanings The following pages describe the symbol IMPORTANT In addition to the three above the following are also used as appropriate means WARNING or CAUTION Example CAUTION AGAINST AN ELECTRIC S...

Page 11: ...m s oscillator page 21 of the M30200T RPD E User s Manual 4 XOUT pin The XOUT pin is not assigned to the evaluation MCU used by this product For this reason the XOUT pin of this product is open 5 DBC...

Page 12: ...the NMI pin L level when the NMI pin is H level immediately before the target program stops Notes on Interrupts Even while the target program is not being executed i e even when the target program is...

Page 13: ...ingle step Interrupt Vector Area Do not perform the below debugging operations with the single step interrupt vector area addresses FFFECh FFFEFh 1 Step execution of instructions that access the singl...

Page 14: ...12 54 MEMO...

Page 15: ...chapter describes the package components the system configuration and the preparation for using this product for the first time 2 1 Package Components 14 2 2 Other Tool Products Required for Developme...

Page 16: ...forward programs development on the M30220 and M30221 Group MCUs the products listed below are necessary in addition to the package components listed above Get them separately Table 2 2 Other tool pr...

Page 17: ...ately available to be mounted on the foot pattern for 144 pin 0 5 mm pitch LQFP prepared on the target system 3 Pitch converter board for 144 pin 0 4 mm pitch TQFP FLX 144NSE This is a pitch converter...

Page 18: ...16 54 MEMO...

Page 19: ...or using this product and how to connect this product to the PC4701 and the target system 3 1 Switch Settings 18 3 2 A D Conversion Bypass Capacitor 20 3 3 Connecting the M30200T RPD E 21 3 4 Connecti...

Page 20: ...ystem CNVSS pin to the target system XCIN XCOUT pin to the target system Mounting the A D conversion bypass capacitor 3 1 Switch Settings It is necessary to set the switches of the M30220TF PRB and FL...

Page 21: ...XCOUT JP2 FLX64 PRB The M30220TF PRB does not use this switch XCIN is always selected in any setting PORT NC PORT NC IMPORTANT Note on CNVSS To debug the control program for CPU rewrite mode you need...

Page 22: ...3 2 shows the position of the bypass capacitor Figure 3 2 Foot patterns of A D conversion bypass capacitor IMPORTANT Note on the Operation of A D Converter The characteristics of A D converter differ...

Page 23: ...tion removal iterations The small connectors of the FLX64 PRB J3 and J4 and M30220TF PRB J1 and J2 are guaranteed for only 50 insertion removal iterations 3 3 Connecting the M30200T RPD E The emulatio...

Page 24: ...22 54 3 4 Connecting the Target System There are three ways available to connect this product to target system as shown in Figure 3 5 Figure 3 5 Connecting the target system...

Page 25: ...ly Figure 3 6 Connecting the pitch converter board FLX 144NSD for 144 pin 0 5 mm pitch LQFP 1 Mount the NQPACK144SD included in the FLX 144NSD separately available to the target system 2 Connect the Y...

Page 26: ...ely available to the target system 2 Connect the YQPACK144SE included in the FLX 144NSE to the NQPACK144SE Secure the YQPACK144SE using the YQ GUIDE s 3 Connect the FLX 144NSE to the M30220TF PRB 4 Co...

Page 27: ...to mount the pitch converter board in a wrong direction 1 Mount the NQPACK120SE included in the FLX 120NSE separately available to the target system 2 Connect the YQPACK120SE included in the FLX 120N...

Page 28: ...ge the contents of the MCU file according to the MCU to be debugged Use your editor for changing the MCU file The examples of contents of the MCU file are as follows 1 For 30220 Group 10KB RAM 128KB R...

Page 29: ...edure for CPU Rewrite Mode Boot Mode 34 4 4 How to Access Flash Memory Area 36 1 Using Script Commands 36 2 Using the Dump Window 36 3 Using the RAM Monitor Window 36 4 5 Precautions for CPU Rewrite M...

Page 30: ...memory enabled Run the control program and transfer the rewrite program to the RAM area emulation memory Execute the script command MAP E0000 FFFDF EXT MCU enabled Execute the rewrite program to set...

Page 31: ...specified in the argument as the path to the custom program in M3T PD30 Step 3 Register custom command dbg_reset Execute the following script command in the M3T PD30 script window MACRO dbg_reset RET...

Page 32: ...the custom program Open the M3T PD30 script window and execute the following script command MacroPATH absolute directory to which fmcr1set p was copied Example 1 MacroPATH C MTOOL M3T PD30 RET The Mac...

Page 33: ...ram counter PC Notes The fmcr1set command can set 1 in the CPU rewrite mode select bit FMCR1 This command cannot be used while the target program is running When the PC is where there is no source fil...

Page 34: ...e RAM area Running the program transfers the control program for CPU rewrite mode to the RAM area emulation memory Set the map for user ROM area E0000h to FFFDFh to EXT Using the breakpoint set in 1 s...

Page 35: ...e RAM area After stopping set the program window to disassemble display mode and step execute the jump to the RAM area This allows you to stop in the RAM area Example 2 If there are 10 or more cycles...

Page 36: ...CPU rewrite mode to the RAM area emulation memory Set the map for user ROM area E0000h to FFFDFh to EXT Using the breakpoint set in 1 stop program execution after jumping to RAM area and before the C...

Page 37: ...e RAM area After stopping set the program window to disassemble display mode and step execute the jump to the RAM area This allows you to stop in the RAM area Example 2 If there are 10 or more cycles...

Page 38: ...a If the data was not FFFFh prior to being programmed the data after being programmed may differ from the data that was written The post programming data is the AND value of the pre programming data a...

Page 39: ...dress E0000h FFFDFh Memory Table 4 5 shows the areas of memory addresses E0000h to FFFDFh that are enabled according to the MAP setting and the value of the CPU rewrite mode select bit FMCR1 Table 4 5...

Page 40: ...to EXT This is because undefined values are read as shown in Note on Address E0000h FFFDFh Memory page 37 When the MAP setting is INT resets from the target function normally Note on Setting the CPU R...

Page 41: ...re than 100 program erase operations please replace the M30220TF PRB with a new one Note on Shutting OFF the Power When switching off the power supply to the emulator itself first select read array mo...

Page 42: ...40 54 MEMO...

Page 43: ...product 5 1 Specifications 42 5 2 External Dimensions 43 1 External Dimensions of the Pod Probe 43 2 External Dimensions of the Converter Board FLX 144NSD 43 3 External Dimensions of the Converter Bo...

Page 44: ...o target system is connected or when the supply voltage of the target system is more than 5 0 V the operating voltage is 5 0 V 5 to 35 C no dew 20 to 30 C in CPU rewrite mode 10 to 60 C no dew M30220...

Page 45: ...s of the M30220TF PRB 2 External Dimensions of the Converter Board FLX 144NSD Figure 5 2 shows the external dimensions and a sample foot pattern of the pitch converter board FLX 144NSD for 144 pin 0 5...

Page 46: ...144 pin 0 4 mm pitch TQFP Unit mm Figure 5 3 External dimensions of the FLX 144NSE 4 External Dimensions of the Converter Board FLX 120NSE Figure 5 4 shows the external dimensions and a sample foot p...

Page 47: ...lator Debugger Does Not Start Up Properly 46 1 When the LED Display of PC4701 is Abnormal 46 2 Errors Occur When Starting Up the Emulator Debugger When the target system is connected 47 3 Errors Occur...

Page 48: ...e is connected to the PC4701 See the PC4701 User s Manual 1 Recheck the connection between the M30200T RPD E and this product See 3 3 Connecting the M30200T RPD E page 21 2 Recheck the connection betw...

Page 49: ...M30200T RPD E and this product See 3 3 Connecting the M30200T RPD E page 21 3 Recheck the connection between the PC4701 and the M30200T RPD E See the M30200T RPD E User s Manual Download the proper fi...

Page 50: ...interrupt vector table addresses However because the emulator system uses these areas data different from the expected value is read out 6 A D conversion The characteristics of A D converter differ fr...

Page 51: ...er 7 Maintenance and Warranty This chapter describes how to maintenance repair provisions and how to request for repair 7 1 Maintenance 50 7 2 Warranty 50 7 3 Repair Provisions 50 7 4 How to Request f...

Page 52: ...leasing company or the owner 7 3 Repair Provisions 1 Repair with extra charge The products elapsed more than twelve months after purchase can be repaired with extra charge 2 Replacement with extra cha...

Page 53: ...Repair Request Sheet to Renesas Solutions Corp Renesas Solutions When the faulty product is repaired it will be returned to the customer at the earliest convenience CAUTION Note on Transporting the P...

Page 54: ...52 54 MEMO...

Page 55: ...M30220TF PRB User s Manual Rev 1 00 September 1 2003 REJ10J0280 0100Z COPYRIGHT 2003 RENESAS TECHNOLOGY CORPORATION AND RENESAS SOLUTIONS CORPORATION ALL RIGHTS RESERVED...

Page 56: ...1753 Shimonumabe Nakahara ku Kawasaki shi Kanagawa 211 8668 Japan M30220TF PRB REJ10J0280 0100Z User s Manual...

Reviews: