Part Number Hot Search : 
24LC21AT BAT165WS SFAF3L SNC375 0183M F1505XS LC75371M AP2172
Product Description
Full Text Search
 

To Download R0E00008AKCE00EP57 Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
 REJ10J1930-0100
E8a Emulator
Additional Document for User's Manual R0E00008AKCE00EP57
Renesas Microcomputer Development Environment System R8C Family / R8C/3x Series Notes on Connecting the R8C/35A, R8C/36A and R8C/38A
Rev.1.00 Jun. 01, 2009
Notes regarding these materials
1. 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 this document nor grants any license to any intellectual property rights or any other rights of Renesas or any third party with respect to the information in this document. 2. Renesas shall have no liability for damages or infringement of any intellectual property or other rights arising out of the use of any information in this document, including, but not limited to, product data, diagrams, charts, programs, algorithms, and application circuit examples. 3. You should not use the products or the technology described in this document for the purpose of military applications such as the development of weapons of mass destruction or for the purpose of any other military use. When exporting the products or technology described herein, you should follow the applicable export control laws and regulations, and procedures required by such laws and regulations. 4. All information included in this document such as product data, diagrams, charts, programs, algorithms, and application circuit examples, 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 products listed in this document, please confirm the latest product information with a Renesas sales office. Also, please pay regular and careful attention to additional and different information to be disclosed by Renesas such as that disclosed through our website. (http://www.renesas.com ) 5. Renesas has used reasonable care in compiling the information included in this document, but Renesas assumes no liability whatsoever for any damages incurred as a result of errors or omissions in the information included in this document. 6. When using or otherwise relying on the information in this document, you should evaluate the information in light of the total system before deciding about the applicability of such information to the intended application. Renesas makes no representations, warranties or guaranties regarding the suitability of its products for any particular application and specifically disclaims any liability arising out of the application and use of the information in this document or Renesas products. 7. With the exception of products specified by Renesas as suitable for automobile applications, Renesas products are not designed, manufactured or tested for applications or otherwise in systems the failure or malfunction of which may cause a direct threat to human life or create a risk of human injury or which require especially high quality and reliability such as safety systems, or equipment or systems for transportation and traffic, healthcare, combustion control, aerospace and aeronautics, nuclear power, or undersea communication transmission. If you are considering the use of our products for such purposes, please contact a Renesas sales office beforehand. Renesas shall have no liability for damages arising out of the uses set forth above. 8. Notwithstanding the preceding paragraph, you should not use Renesas products for the purposes listed below: (1) artificial life support devices or systems (2) surgical implantations (3) healthcare intervention (e.g., excision, administration of medication, etc.) (4) any other purposes that pose a direct threat to human life Renesas shall have no liability for damages arising out of the uses set forth in the above and purchasers who elect to use Renesas products in any of the foregoing applications shall indemnify and hold harmless Renesas Technology Corp., its affiliated companies and their officers, directors, and employees against any and all damages arising out of such applications. 9. You should use the products described herein within the range specified by Renesas, especially with respect to the maximum rating, operating supply voltage range, movement power voltage range, heat radiation characteristics, installation and other product characteristics. Renesas shall have no liability for malfunctions or damages arising out of the use of Renesas products beyond such specified ranges. 10. Although Renesas endeavors to improve the quality and reliability of its products, IC products have specific characteristics such as the occurrence of failure at a certain rate and malfunctions under certain use conditions. Please be sure to implement safety measures to guard against the possibility of physical injury, and injury or damage caused by fire in the event of the failure of a Renesas product, such as safety design for hardware and software including but not limited to redundancy, fire control and malfunction prevention, appropriate treatment for aging degradation or any other applicable measures. Among others, since the evaluation of microcomputer software alone is very difficult, please evaluate the safety of the final products or system manufactured by you. 11. In case Renesas products listed in this document are detached from the products to which the Renesas products are attached or affixed, the risk of accident such as swallowing by infants and small children is very high. You should implement safety measures so that Renesas products may not be easily detached from your products. Renesas shall have no liability for damages arising out of such detachment. 12. This document may not be reproduced or duplicated, in any form, in whole or in part, without prior written approval from Renesas. 13. Please contact a Renesas sales office if you have any questions regarding the information contained in this document, Renesas semiconductor products, or if you have any other inquiries.
E8a Emulator
Contents
Contents
Page 1. Inside the E8a Emulator User's Manual ...................................................................................................................4 2. E8a Emulator Specifications.....................................................................................................................................5 2.1 Emulator specifications .......................................................................................................................................5 2.2 Applicable tool chain and third-party products ....................................................................................................7 3. Connecting the E8a Emulator to the User System ...................................................................................................9 3.1 Connector for connecting the E8a emulator and the user system......................................................................9 4. Examples of Pin Handling for Connecting the E8a.................................................................................................11 4.1 Examples of pin handling for connecting the E8a.............................................................................................11 4.2 Interface circuit in the E8a emulator .................................................................................................................13 5. Emulator Debugger Setting ....................................................................................................................................14 5.1 [Emulator Setting] dialog box ............................................................................................................................14 5.2 [Emulator mode] tab..........................................................................................................................................15 5.3 [Firmware Location] tab.....................................................................................................................................17 5.4 [Communication Baud Rate] tab .......................................................................................................................18 6. E8a Emulator Functions (Supplement on the User's Manual) ...............................................................................19 6.1 E8a emulator functions .....................................................................................................................................19 6.2 Eventcondition tab of the Eventpoints window..................................................................................................20 6.3 Event Setting dialog box ...................................................................................................................................21 6.4 Display contents of the Trace window ..............................................................................................................23 6.5 Notes on the event settings of the access break and trace function ................................................................24 7. Notes on Using the E8a Emulator ..........................................................................................................................25 7.1 MCU resources used by the E8a emulator .......................................................................................................25 7.2 Flash memory ...................................................................................................................................................28 7.2.1 Notes on debugging in CPU rewrite mode .................................................................................................28 7.2.2 Note on rewriting flash memory..................................................................................................................28 7.2.3 Note on flash memory during user program execution ..............................................................................28 7.2.4 MCUs used for debugging..........................................................................................................................28 7.2.5 Flash memory ID code ...............................................................................................................................29 7.3 Debugging during a watchdog timer operation .................................................................................................30 7.4 Power supply.....................................................................................................................................................30 7.5 Operation during a user program halt ...............................................................................................................31 7.6 Debug functions ................................................................................................................................................31
REJ10J1930-0100 Page 3 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
1. Inside the E8a Emulator User's Manual
1. Inside the E8a Emulator User's Manual
The E8a manual consists of two documents: the E8a User's Manual and the E8a Additional Document for User's Manual (this document). Be sure to read BOTH documents before using the E8a emulator. In this user's manual, the symbol # is used to show active LOW. (e.g. RESET#) (1) E8a Emulator User's Manual The E8a Emulator User's Manual describes the hardware specifications and how to use the emulator debugger. E8a emulator hardware specifications Connecting the E8a emulator to the host computer or user system Operating the E8a emulator debugger Tutorial: From starting up the E8a emulator debugger to debugging
(2) E8a Additional Document for User's Manual The E8a Additional Document for User's Manual describes content dependent on the MCUs and precautionary notes. MCU resources used by the E8a emulator Example of the E8a emulator connection or interface circuit necessary for designing the hardware Notes on using the E8a emulator Setting the E8a emulator debugger during startup
REJ10J1930-0100 Page 4 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
2. E8a Emulator Specifications
2. E8a Emulator Specifications
2.1 Emulator specifications
Table 2.1 shows the E8a emulator specifications for the R8C/35A, R8C/36A and R8C/38A Groups. Table 2.2 shows the operating environment of the E8a emulator. Table 2.1
Target MCUs Available operating modes Power voltages
E8a Emulator Specifications for the R8C/35A, R8C/36A and R8C/38A Groups
R8C Family R8C/3x Series R8C/35A, R8C/36A and R8C/38A Groups Single-chip mode 3.0 - 5.5 V (f(XIN)=20MHz) 2.7 - 5.5 V (f(XIN)=10MHz) 1.8 - 5.5 V (f(XIN)=5MHz) [*1]
Debug functions Break functions - Address match break, 8 points - Data access break, 2 points - Event A: Comparison with the address/data mask, and access condition (R, W, R/W) can be set. - Event B: Comparison with the address mask, and access condition (R, W, R/W) can be set. - PC break points (maximum 255 points) - Forced break Trace functions 4 branch instructions (branch source/destination PC) or Up to 8 data cycles can be specified. Flash memory programming function User interface MCU resources to be used Available 1-line clock asynchronous serial interface (communication via MODE pin) - ROM size: 2 KB - Stack 8 bytes - Address match interrupt Emulator power supply Interface with host machine Unnecessary (USB bus powered, power supplied from the PC) USB (USB 1.1, full speed) * Also connectable to host computers that support USB 2.0 * Operation with all combinations of host machine, USB device and USB hub is not guaranteed for the USB interface. Power supply function Applicable emulator debugger Can supply 3.3 V or 5.0 V to the user system (maximum 300 mA) R8C E8a Emulator Debugger V.1.03.00 or later
Note
[*1] Set the power voltage to 2.7 V or above for rewriting the flash memory. For details, refer to "7.6 (4) Note on debugging at less than 2.7V" on page 32.
REJ10J1930-0100 Page 5 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
2. E8a Emulator Specifications
Table 2.2
Operating Environment Active : 10C to 35C Inactive : -10C to 50C Active : 35% RH to 80% RH, no condensation Inactive : 35% RH to 80% RH, no condensation Active : maximum 2.45 m/s2 Inactive : maximum 4.9 m/s2 Transportation : maximum 14.7 m/s2 No corrosive gases
Temperatures Humidity Vibrations
Ambient gases
REJ10J1930-0100 Page 6 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
2. E8a Emulator Specifications
2.2 Applicable tool chain and third-party products
You can debug a module created by the inhouse tool chain and third-party products listed in Table 2.3 below. Table 2.3
Tool chain Third-party products
Applicable Tool Chain and Third-party Products
M3T-NC30WA V.5.20 Release 01 or later TASKING M16C C/C++/EC++ Compiler V.2.3r1 or later IAR EWM16C V.2.12 or later
Notes on debugging the load modules created in ELF/DWARF2 format
If the load module was created in ELF/DWARF2 format using TASKING M16C C/C++/EC++ compiler V3.0r1, the precautionary note described below must be observed when displaying member variables of the base class in the watch window. Precautionary Note: If any class object with a base class is defined, the following problems may occur: Case 1: Member variables of the base class cannot be referenced directly from the class object (*1). =>Use indirect references from the class object to refer to member variables of the base class (*2) (*3). Case 2: If the PC value resides in any member function of a derived class, member variables of the base class cannot be referenced directly (*4). => Use indirect references from "this" pointer to refer to member variables of the base class (*5) (*6).
REJ10J1930-0100 Page 7 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
2. E8a Emulator Specifications
///////////////////////////////////////////////////////// *.h class BaseClass { public: int m_iBase; public: BaseClass() { m_iBase = 0; } void BaseFunc(void); }; class DerivedClass : public BaseClass { public: int m_iDerive; public: DerivedClass() { m_iDerive = 0; } void DerivedFunc(void); }; *.cpp main() { class DerivedClass ClassObj; ClassObj.DerivedFunc(); return; } void BaseClass::BaseFunc(void) { m_iBase = 0x1234; } void DerivedClass::DerivedFunc(void) { BaseFunc(); m_iDerive = 0x1234; } /////////////////////////////////////////////////////////
Figure 2.1 Example code
///////////////////////////////////////////////////////// Case 1: If the PC value resides in the main() function (1)"ClassObj.m_iBase" : Cannot be referenced (*1) (2)"ClassObj.__b_BaseClass.m_iBase" : Can be referenced (*2) (3)"ClassObj" -"__b_BaseClass" -"m_iBase" : Can be referenced (*3) -"m_iDerive" -: Expansion symbol Case 2: If the PC value resides in the DerivedClass::DerivedFunc() function (1)"m_iBase" : Cannot be referenced (*4) (2)"this->__b_BaseClass.m_iBase" : Can be referenced (*5) (3)"__b_BaseClass.m_iBase" : Can be referenced (*5) (4)"this" -"*" -"__b_BaseClass" -"m_iBase" : Can be referenced (*6) -"m_iDerive" (5)"__b_BaseClass" -"m_iBase" : Can be referenced (*6) /////////////////////////////////////////////////////////
Figure 2.2
Watch window registration example
REJ10J1930-0100 Page 8 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
3. Connecting the E8a Emulator to the User System
3. Connecting the E8a Emulator to the User System
3.1 Connector for connecting the E8a emulator and the user system
Before connecting the E8a emulator to the user system, a connector must be installed in the user system so a user system interface cable can be connected. Table 3.1 shows the recommended connector for the E8a emulator and Figure 3.2 shows E8a connecting connector pin assignments. When designing the user system, refer to Figure 3.2 "E8a Connecting Connector Pin Assignments" and Section 3 "Connecting the E8a Emulator to the User System". Before designing the user system, be sure to read the E8a Emulator User's Manual and related device hardware manuals. Table 3.1 Recommended Connector Type Number 2514-6002 Manufacturer 3M Limited Specification 14-pin straight type
14-pin connector
User system interface cable
Connector
Pin 2
User system
Pin 1
Figure 3.1
Connecting the User System Interface Cable with an E8a Connecting Connector
Notes
Do not place any components within 3 mm area of the connector. When using the E8a emulator as a programmer, connect it to the user system in the same way. Connect E8a connecting connector pins 2, 4, 6, 10, 12 and 14 firmly to the GND on the user system board. These pins are used as an electric GND and monitor the connection of the user system connector.
REJ10J1930-0100 Page 9 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
3. Connecting the E8a Emulator to the User System
Pin NO
Pin 1 mark Connector
R8C/35A, R8C/36A and R8C/38A
Pin2 Pin1
Pin 14 Pin 13
Pin 1 mark
1 2 3 4 5 6 7 8 9 10 11 12 13 14
MCU Signals N.C. Vss N.C. Vss N.C. Vss MODE Vcc N.C. Vss N.C. Vss RESET# Vss
Figure 3.2
E8a Connecting Connector Pin Assignments
Notes
Pin 14 is used for checking the connection between the E8a and the user system, and is not directly connected to the Vss inside the E8a. Make sure pins 2, 4, 6, 10, 12 and 14 are all connected to the Vss. Note the pin assignments for the user system connector.
REJ10J1930-0100 Page 10 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
4. Examples of Pin Handling for Connecting the E8a
4. Examples of Pin Handling for Connecting the E8a
4.1 Examples of pin handling for connecting the E8a
Figure 4.1 shows an example of pin handling when connecting the E8a. When using the E8a as a programmer, the connection specification between the E8a and the MCUs is the same as shown in Figure 4.1.
Pulled up at 4.7k 10%
MCU
Pulled up at 4.7k or more
Figure 4.1
Example of an E8a Connection
REJ10J1930-0100 Page 11 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
4. Examples of Pin Handling for Connecting the E8a
(1) MODE pin The E8a emulator uses the MODE pin for MCU control and forced break control. Pull up the E8a emulator and MCU pins and connect the E8a emulator.
Vcc
E8a connecting connector
MODE
Pulled up at 4.7k 10%
7
MODE
MCU
Figure 4.2
E8a Emulator and MODE Pin Connection
(2) RESET# pin The RESET# pin is used by the E8a emulator. Therefore, use an open-collector output buffer or a CR reset circuit as the reset circuit for the user system. The recommended pull-up value is 4.7 k or more. The MCU can be reset by outputting "L" from the E8a emulator. However, if the reset IC output is "H", the user system reset circuit cannot be set to "L". As such, the E8a emulator will not operate normally.
Vcc
E8a connecting connector
RESET#
User logic
*
RESET# MCU
13
Pulled up at 4.7k or more
* : Open-collector buffer
Figure 4.3
Example of a Reset Circuit
(3) Other pins - Connect Vss and Vcc to the Vss and Vcc of the MCU, respectively. - The amount of voltage input to Vcc must be within the specified range of the MCU. - Pin 14 is used for checking the connection between the E8a and the user system, and pins 4, 6 and 10 are connected to the internal circuit. These pins are not directly connected to the Vss inside the E8a. - Make sure pins 2, 4, 6, 10, 12 and 14 are all connected to the Vss. - Do not connect anything to the N.C. pin.
REJ10J1930-0100 Page 12 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
4. Examples of Pin Handling for Connecting the E8a
4.2 Interface circuit in the E8a emulator
Figure 4.4 shows the interface circuit in the E8a emulator. Use this figure as a reference when determining the pull-up resistance value.
User system connector
Power supply circuit (use only with power supply mode)
Vcc
8
Emulator control circuit
74LVC125
[*1]
22
MODE
7
3.3V 74LVC2T45
[*1]
22
RESET#
13
3.3V
2SC2462 10k
[*1] Power for 74LVC125 and 74LVC2T45 are supplied from Vcc in the user system connector or power supply circuit (in power supply mode).
Figure 4.4
Interface Circuit inside the E8a Emulator (For Reference)
REJ10J1930-0100 Page 13 of 35
Rev.1.00 Jun. 01, 2009
E8a emulator
5. Emulator Debugger Setting
5. Emulator Debugger Setting
5.1 [Emulator Setting] dialog box
The [Emulator Setting] dialog box is provided for setting items that need to be set when the debugger is launched. The contents set from this dialog box (excluding [Power Supply] group box items) also become valid the next time the debugger is launched. When launching the debugger for the first time after creating a new project work space, the [Emulator Setting] dialog box is displayed with the Wizard.
Figure 5.1
[Emulator Setting] Dialog Box
If you check "Do not show this dialog box again." at the bottom of the [Emulator Setting] dialog box, the [Emulator Setting] dialog box will not be displayed the next time the debugger is launched. You can open the [Emulator Setting] dialog box using one of the following methods: - After the debugger is launched, select Menu -> [Setup] -> [Emulator] -> [Emulator Setting...]. - Hold down the Ctrl key while launching the debugger. When "Do not show this dialog box again." is checked, the E8a does not supply power to the user system.
REJ10J1930-0100 Page 14 of 35
Rev.1.00 Jun. 01, 2009
E8a emulator
5. Emulator Debugger Setting
5.2 [Emulator mode] tab
Device selection, mode specification and power supply setting are made from the [Emulator mode] tab of the [Emulator Setting] dialog box. [MCU Group]
Select the name of the MCU group to be used from the [MCU Group] drop-down list.
[Device]
Select the type of MCU to be used from the [Device] drop-down list.
[Mode]
Select the mode to be used. For details, see "5.2 (1) Selecting the Mode" (p.16).
[Power supply]
Select the power supply to the user system. - When supplying power to the user system from the E8a, click the [Power Target from Emulator. (MAX 300mA)] checkbox.
Figure 5.2 [Emulator mode] Tab of [Emulator Setting] Dialog Box
REJ10J1930-0100 Page 15 of 35
Rev.1.00 Jun. 01, 2009
E8a emulator
5. Emulator Debugger Setting
(1) Selecting the Mode Table 5.1 Selecting the Mode
Mode Erase Flash and Connect [*2] Debugging only [*1] Keep Flash and Connect [*2] Usage Description When starting the debugger, the E8a emulator erases the Flash memory data for the MCUs and simultaneously writes the E8a emulator program. When launching the debugger, the E8a emulator retains the Flash memory data for the MCUs. Note that the area for the E8a emulator program and the vector area used by the E8a emulator will change. The E8a emulator starts as a simple programmer. When downloaded, the E8a writes only the user program (E8a emulator program is not written). Therefore, the program cannot be debugged in this mode. Program Flash [*2] Simple programmer When [Execute the user program after ending the debugger.] is selected, with the E8a emulator connected to the user system, the user program is executed at the same time the debugger is terminated. This check box setting is available only when the [Program Flash] mode is selected. Select this setting when debugging the program which rewrites the CPU. In this mode, the following debug operation which rewrites the Flash memory cannot be executed. Debugging of CPU rewrite mode Debugging only [*1] - Setting the PC break points - Changing the memory contents in the Flash memory area In this mode, when starting the debugger, the E8a emulator erases the Flash memory data for the MCUs and simultaneously writes the E8a emulator program.
Notes
[*1] [*2] These modes are available only for debugging. Programs written in these modes cannot be executed from the CPU. If you want to execute a program from the CPU, use Program Flash mode. When starting up in these modes, lock bits in all the blocks of the flash memory will be unlocked. Note that the lock bits of the downloaded blocks will be unlocked after downloading the user program.
REJ10J1930-0100 Page 16 of 35
Rev.1.00 Jun. 01, 2009
E8a emulator
5. Emulator Debugger Setting
5.3 [Firmware Location] tab
You can specify the address of the firmware location in the [Firmware Location] tab. [Firmware Location]
Select the area in which the firmware is located. Specify the address that will not be used by the user system in the ROM area or RAM area. - Program Specify the ROM area in which the firmware is located. Specify 2k bytes that will not be used by the user system. [*1]
Figure 5.3 [Firmware Location] tab of [Emulator Setting] Dialog Box
Note
[*1] When using the MCU whose ROM size is other than 128 KB, the options in this [Firmware Location] tab are displayed in gray because this setting is unnecessary.
REJ10J1930-0100 Page 17 of 35
Rev.1.00 Jun. 01, 2009
E8a emulator
5. Emulator Debugger Setting
5.4 [Communication Baud Rate] tab
Select communication baud rate between the E8a and MCU in the [Communication Baud Rate] tab. 500000 bps (default setting) should be selected during normal use.
Figure 5.4 [Communication Baud Rate] Tab
REJ10J1930-0100 Page 18 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
6. E8a Emulator Functions (Supplement on the User's Manual)
6. E8a Emulator Functions (Supplement on the User's Manual)
6.1 E8a emulator functions
With the R8C/35A, R8C/36A and R8C/38A Groups, the following functions in the device can be used. (1) Break Function - Address match break This function breaks the program immediately before a specified address instruction is executed. It can be realized using the address match interrupt of the MCU. Up to 8 points of the address match break can be used. Set the address match breakpoint in the Break condition sheet of the Eventpoints window. You can also set it by double-clicking the Event column in the Editor window. For details, refer to the E8a User's Manual. - Data access break This function breaks the program when a specified event is encountered. You can combine two points of the data access event. - Trace full break This function breaks the program when the trace buffer is filled (2) Trace Function - Branch trace This function displays addresses, mnemonics and source lines of the branch source and destination. - Data trace This function displays data accesses when a data access event is encountered. For the data access event and trace condition, set them in the Eventcondition tab of the Eventpoints window.
REJ10J1930-0100 Page 19 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
6. E8a Emulator Functions (Supplement on the User's Manual)
6.2 Eventcondition tab of the Eventpoints window
Set the contents of the data access event, break condition and trace condition. Double-clicking each item in this window will open the Event Setting dialog box to change the conditions. The items displayed in the sheet are shown in Table 6.1.
Figure 6.1 Table 6.1
Item Type
Eventpoints Window (Eventcondition tab) Display Contents of the Eventcondition Tab
Description Displays the event types. - Event A - Event B - Break Condition - Trace Condition Shows the event is enable or disable. - Enable - Disable Displays the set condition. For the Event A and Event B, the access types are displayed. - R/W: READ or WRITE - READ - WRITE For the Break Condition and Trace Condition, Break/Trace is always displayed.
State
Condition Action
REJ10J1930-0100 Page 20 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
6. E8a Emulator Functions (Supplement on the User's Manual)
6.3 Event Setting dialog box
The conditions in the Event condition sheet can be set.
Figure 6.2
Event Setting Dialog box
(1) Event A Set the contents of the Event A. You can set the conditions of the address comparison with mask specification and data comparison with mask specification for the Event A. Table 6.2 Contents of the Event A
Description Specify an address to detect the data access. Specify the bit number to set the address mask. The specified lower bits of the specified address are masked. If you compare data, specify the data and data mask. When selecting BYTE for the Access Size, you can specify to FF. When selecting WORD for the Access Size, you can specify to FFFF. If you do not compare data, leave the Data item empty or enter 0 in the Mask. If you do not use the data mask, leave the Mask item empty. Select one from BYTE, WORD or Not specify for the Access Size. If a data access which does not match the specified access size occurs, the event is not encountered. When specifying WORD for the Access Size, specify the even address for the Address item. Select an access type. - R/W: READ or WRITE - READ - WRITE
Option Address (with mask specification)
Data (with mask specification)
Access Size
Access Type
REJ10J1930-0100 Page 21 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
6. E8a Emulator Functions (Supplement on the User's Manual)
(2) Event B Set the contents of the Event B. You can set the conditions of the address comparison with mask specification for the Event B. Table 6.3 Contents of the Event B
Description Same as the Event A. Same as the Event A. Same as the Event A.
Option Address (with mask specification) Access Size Access Type
(3) Break Condition Set the break condition. Table 6.4
Break
Break Condition
Description Select a break condition. - None: None specified. (No break by event) - Event A: Breaks the program when the Event A is encountered. - Event A or B: Breaks the program when either the Event A or Event B is encountered. - Event A and B: Breaks the program when both the Event A and Event B are encountered. - Event B->A: Breaks the program when an event is encountered in the order of the Event B and Event A. Check it to break the program when the trace buffer is filled. It can be set with the break condition by event.
Option
Break at Trace Full
(4) Trace Condition Set the trace condition. Table 6.5
Option Type
Trace Condition
Description Select a trace type. - Branch Trace - Data Trace Select a start condition for the trace measurement. - Go: Starts a measurement when starting executing the target program. - Event A: Starts a measurement when the Event A is encountered. - Event A or B: Starts a measurement when either the Event A or Event B is encountered. - Event A and B: Starts a measurement when both the Event A and Event B are encountered. - Event B->A: Starts a measurement when an event is encountered in the order of the Event B and Event A. Select a stop condition for the trace measurement. - Break: Stops a measurement when stopping executing the target program. - Trace FULL: Stops a measurement when the trace data is filled. - Event A: Stops a measurement when the Event A is encountered. - Event A or B: Stops a measurement when either the Event A or Event B is encountered. - Event A and B: Stops a measurement when both the Event A and Event B are encountered. - Event B->A: Stops a measurement when an event is encountered in the order of the Event B and Event A. Select an event to record when tracing data. - Event A: Records only data access which encounters the condition of the Event A. - Event A or B: Records only data access which encounters the condition of either the Event A or Event B.
Start
Stop
Pick up
REJ10J1930-0100 Page 22 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
6. E8a Emulator Functions (Supplement on the User's Manual)
6.4 Display contents of the Trace window
To display the trace results, open the Trace window. For each function of the popup menu, refer to the E8a User's Manual. The items displayed in the sheet are shown in Table 6.6.
Figure 6.3 Table 6.6
Item PTR IP Type Address Data Instruction
Trace Window Trace Display
Description Displays the pointer numbers in the trace buffer. Displays them in ascending order with the trace end position as 0. Displays the instruction pointer. Displays the type of trace information. When the branch trace is set, BRANCH/DESTINATION is displayed. When the data trace is set, READ/WRITE is displayed. When the branch trace is set, an address of the branch source and destination is displayed. When the data trace is set, an address or address range set for the encountered event is displayed. When the data trace is set, the accessed value is displayed. When the branch trace is set, nothing is displayed. When the branch trace is set, the mnemonic of the address is displayed. When the data trace is set, nothing is displayed. "*** EML ***" may be displayed in the Instruction column. This shows that the target program accessed the area of emulator use to control breaks, etc. It is not an error. If there is a source line information correspondent to the Instruction, the correspondent source line is displayed. When the data trace is set, nothing is displayed. If there is a label correspondent to an address in the Instruction, the correspondent label is displayed. When the data trace is set, nothing is displayed.
Source Label
REJ10J1930-0100 Page 23 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
6. E8a Emulator Functions (Supplement on the User's Manual)
6.5 Notes on the event settings of the access break and trace function
When setting the Event A or Event B for the access break and trace function, set the address, access size and access type referring to Table 6.7 below. Table 6.7 Availability of the Event Setting
Availability of event setting Available Example of Event Setting dialog box Address: 400h Access size: BYTE Access type: READ or R/W Address: 400h Access size: BYTE Access type: WRITE or R/W Address: 400h Access size: WORD Access type: READ or R/W Address: 400h Access size: WORD Access type: WRITE or R/W Address: 401h Access size: BYTE Access type: READ or R/W Address: 401h Access size: BYTE Access type: WRITE or R/W Address: 401h Access size: BYTE [*1] Access type: READ or R/W Address: 401h Access size: BYTE [*1] Access type: WRITE or R/W
Event setting condition Byte read to even address
Byte write to even address
Available
Word read to even address
Available
Word write to even address
Available
Byte read to odd address
Available
Byte write to odd address
Available
Word read to odd address
Available
Word write to odd address
Available
Note [*1]: For the access size, specify "BYTE". In this condition, the lower one byte data can be compared.
Notes
Note on the trace start condition When setting an event (other than "Go") for the trace start condition, a data when the event is encountered is not recorded to the trace data. The data of the event which is encountered the next time is recorded. Notes on the trace stop condition When the trace start and trace stop conditions occur simultaneously, the trace stop condition becomes invalid. When setting other than "Break" for the trace stop condition, the display contents of the Trace window will not be updated until the user program stops even after a trace stop condition is encountered. Note on setting the Event A When setting an event for the Event A, you cannot specify a mask for an address and data simultaneously. If you mask them simultaneously, an event will not be encountered. Note on setting an event Do not specify the following addresses as the address of the event. Otherwise, an unauthorized break may occur. - Address in the interrupt vector table - Address set in the interrupt vector table (interrupt routine start address) - Branch address of the branch instruction Both fixed vector table and variable vector table are included with the interrupt vector table above.
REJ10J1930-0100 Page 24 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
7. Notes on Using the E8a Emulator
7.1 MCU resources used by the E8a emulator
(1) Program area for the E8a emulator Table 7.1 lists the program areas allotted for the E8a emulator. Do not change this area allocation, otherwise the E8a emulator will not control the MCU. If settings were changed, disconnect the debugger and then reconnect it. Table 7.1
Group
Program Area for the E8a Emulator
Part No. R5F21357A R5F21358A 48 KB 64 KB 96 KB 128 KB 16 KB 24 KB 32 KB 48 KB 64 KB 96 KB 128 KB 32 KB 48 KB 64 KB 96 KB 128 KB 1 KB (4 blocks) ROM Size Program ROM Data Flash 4.0 KB 6.0 KB 8.0 KB 10 KB 1.5 KB 2.0 KB 2.5 KB 4.0 KB 6.0 KB 8.0 KB 10 KB 2.5 KB 4.0 KB 6.0 KB 8.0 KB 10 KB FFE4h - FFE7h, FFE8h - FFEBh, FFECh - FFEFh, FFF4h - FFF7h, FFF8h - FFFBh, FFFCh - FFFEh RAM Size Program Area for E8a Emulator Vector Area ROM Area 2 KB of the ROM area [*1] 2 KB of the ROM area [*1] 2 KB of the ROM area [*1]
R8C/35A
R5F2135AA R5F2135CA R5F21364A R5F21365A R5F21366A R5F21367A R5F21368A R5F2136AA R5F2136CA R5F21386A R5F21387A
R8C/36A
R8C/38A
R5F21388A R5F2138AA R5F2138CA
Note
[*1] When starting the debugger, the [Emulator Setting] dialog box is displayed. Specify the area which will not be used by the user system. For details, see 5.3 [Firmware Location] tab.
REJ10J1930-0100 Page 25 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
(2) Pins used by the E8a emulator The E8a emulator controls the MCUs by using the following pins depending on the usage. - For debugging/programming: RESET# pin and MODE pin (3) Registers initialized by the E8a emulator When the system is launched, the E8a emulator initializes the general registers and some of the flag registers as shown in Table 7.2. Table 7.2
Status E8a Emulator Activation PC R0 to R3 (bank 0, 1) A0, A1 (bank 0, 1) FB (bank 0, 1) INTB USP ISP SB FLG
E8a Emulator Register Initial Values
Register 0000h 0000h 0000h 0000h 0000h 05FFh 0000h 0000h Initial Value Reset vector value in the vector address table
(4) SFRs used by the E8a emulator program The SFRs listed in Table 7.3 are used by the E8a emulator program as well as the user program. - Do not change the value in the memory window, etc., by other than the user program. - Note that although the SFRs can be changed during user program execution, the changed value cannot be read at the break. The SFRs listed in Table 7.4 are used by the E8a emulator program, not the user program. - Do not change the registers, otherwise the E8a cannot control the MCU. - The SFRs listed in Tables Table 7.3 and Table 7.4 are not initialized by selecting [Debug] -> [Reset CPU] or by using the RESET command. If register contents are referred to, a value that has been set in the E8a emulator program will be read out. Table 7.3 SFRs Used by the E8a Emulator Program (1)
Register Protect register High-speed on-chip oscillator control register 0 Symbol PRCR FRA0 Bit Bit 0 Bit 0
Address 000Ah 0023h
Table 7.4
SFRs Used by the E8a Emulator Program (2)
Register Address match interrupt register 0 Address match interrupt enable register 0 Address match interrupt register 1 Address match interrupt enable register 1 Symbol RMAD0 AIER0 RMAD1 AIER1 Bit All bits All bits All bits All bits Notes on Using the E8a Emulator [*1] [*1] [*1] [*1]
Address 01C0h - 01C2h 01C3h 01C4h - 01C6h 01C7h
Note [*1]: Do not change this register value.
REJ10J1930-0100 Page 26 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
(5) Stack area used by the E8a emulator The E8a emulator uses up to 8 bytes of the stack pointer (ISP) during a user program break. Therefore, set aside 8 bytes for the stack area. (6) Reset The reset vector is used by the E8a emulator program. If the MCU is reset (hardware reset) while executing the user program, control is transferred to the E8a emulator program and the user program is forced to stop. Do not use the software reset, power-on reset, voltage monitor 0 reset, and watchdog timer reset, otherwise the E8a emulator will run out of control. If the automatic memory update is enabled in the memory or watch window, do not perform a hardware reset to the MCU. Otherwise the E8a emulator will run out of control. (7) Interrupts used by the E8a emulator program (unusable) The BRK instruction interrupt, address match interrupt, single-step interrupt and address break are used by the E8a emulator program. Therefore, make sure the user program does not use any of these interrupts. The E8a emulator changes these interrupt vector values to the values to be used by the emulator. No problems occur if the interrupt vector values are written in the user program. (8) Reserved area The addresses not specified in the Hardware Manual of MCUs are reserved area. Do not change the contents. Otherwise, the E8a emulator cannot control the MCU. (9) Count source protection mode Count source protection mode cannot be debugged with the E8a emulator.
REJ10J1930-0100 Page 27 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
7.2 Flash memory
7.2.1 Notes on debugging in CPU rewrite mode (1) CPU rewrite can be executed only for the data area. If it is executed for the program area, the E8a emulator cannot control the MCU. (2) When rewriting the data area, do not halt the user program, while setting up the CPU rewrite mode and releasing it. If halted, the E8a emulator may not control the MCU. In addition, disable the automatic update in the watch window or fix the display in the memory window before running the program so memory accesses do not occur during an execution. (3) To check the data after executing the CPU rewrite mode, halt the program after releasing the CPU rewrite mode and refer to the memory window, etc. If CPU rewrite can be executed for the data area, and erase process can be suspended, do not use software breaks. (4) When rewriting the Flash memory in the program area, select Menu -> [Setup] -> [Emulator] -> [System...] to open the [Configuration] dialog box in the High-performance Embedded Workshop. In this dialog box, change the [Flash memory synchronization] setting to [Flash memory to PC] and set the debugger cache to OFF. In this setting, the Flash memory is read whenever a break occurs, which takes some time. Use it with the [Disable] setting except when debugging in CPU rewrite mode. 7.2.2 Note on rewriting flash memory (1) Do not reset nor execute debugging operations to the MCU when rewriting the flash memory. Flash memory rewrite ends when the "Flash memory write end" is displayed in the output window of the Highperformance Embedded Workshop. If the MCU is reset or debugged when rewriting the flash memory, the user program or the E8a emulator program may be disrupted. Flash memory rewrite occurs: - When downloading the user program - After setting PC breaks in the flash memory and executing the user program - After canceling PC breaks in the flash memory and executing the user program - After rewriting the value of the flash memory in the memory window and executing the user program 7.2.3 Note on flash memory during user program execution Do not rewrite the flash area from the memory window, etc., except from the user program during user program execution. 7.2.4 MCUs used for debugging When debugging, the Flash memory is frequently rewritten by the E8a emulator. Therefore, do not use an MCU that has been used for debugging in products. Also, as the E8a emulator program is written to the MCU while debugging, do not save the contents of the MCU Flash memory which were used for debugging nor use them as the ROM data for products.
REJ10J1930-0100 Page 28 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
7.2.5 Flash memory ID code This MCU function prevents the Flash memory from being read out by anyone other than the user. The ID code in Table 7.5 written to the flash memory of the MCU must match the ID code displayed in the Figure 7.1 [ID Code verification] Dialog Box at debugger startup, otherwise the debugger cannot be launched. Note that when the ID code is FFh, FFh, FFh, FFh, FFh, FFh, FFh, the ID code is regarded as undefined. In this case, the ID code is automatically authenticated and the [ID Code verification] dialog box is not displayed. The values written into the ID code area differs depending on the mode. - `Program Flash' mode: Contents of the user program - Modes other than `Program Flash' mode: FFh, FFh, FFh, FFh, FFh, FFh, FFh (regardless of the contents of the downloaded user program) Table 7.5
Address FFDFh FFE3h FFEBh FFEFh FFF3h FFF7h FFFBh
ID Code Storage Area
Description First byte of ID code Second byte of ID code Third byte of ID code Fourth byte of ID code Fifth byte of ID code Sixth byte of ID code Seventh byte of ID code
Figure 7.1 [ID Code verification] Dialog Box
Notes
Notes on `Program Flash' mode: When the ID code is specified by the -ID option of the lmc30, download the MOT file or HEX file. When the X30 file is downloaded, the ID code is not valid. When downloading the X30 file, specify the ID code using an assembler directive command such as ".BYTE". The file to which the ID code specified by the assembler directive command ".ID" is output varies depending on the version of the assembler. For details, refer to the Assembler User's Manual.
REJ10J1930-0100 Page 29 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
7.3 Debugging during a watchdog timer operation
When running the E8a emulator program, the program refreshes the watchdog timer. If memory access is executed through memory reference or modification, the watchdog timer will be refreshed by the E8a emulator program. Note that this timing will differ from the actual operational timing. The E8a emulator sets each of bit 0 and bit 7 of the option function select register (OFS: 0FFFFh) to 1b. Although these addresses can be rewritten and the changed values can be referred to in the memory window, etc., the changed values for these bits (bit 0 and bit 7) are invalid. - b0: Watchdog timer start select bit - b7: Count source protection mode after reset select bit 1: Watchdog timer is stopped after reset. 1: Count source protect mode disabled after reset
Also, the E8a emulator sets the lower 4 bits of the option function select register 2 (OFS2: 0FFDBh) to 1111b. - b1, b0: Watchdog timer underflow period set bit - b3, b2: Watchdog timer refresh acknowledgement period set bit 11: 3FFFh 11: 100%
7.4 Power supply
(1) Consumption current When the E8a emulator does not supply power to the user system, it consumes the power voltage of the user system from several mA to more than 10 mA. This is because the user power supply drives 74LVC125, 74LVC1T45 and 74LVC2T45 to make the communication signal level match the user system power supply voltage. (2) E8a emulator power supply When writing a program with the E8a emulator for mass production processes, the program requires reliability, so do not use the E8a emulator power supply function. Supply power separately to the user system according to the allowable voltage for MCU writing. Voltage supplied from the E8a emulator depends on the quality of the USB power supply of the PC, and as such, precision is not guaranteed.
REJ10J1930-0100 Page 30 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
7.5 Operation during a user program halt
(1) Operation clock during a user program halt When the user program halts, the emulator changes the CPU clock to the internal high-speed on-chip oscillator clock divided by 2 (approx. 20MHz, etc.) to operate. However, the peripheral features operate with the clock specified by the user program. Also, when the user program halts, the following registers may not be overwritten in some cases. DTMF control register: 016Ch DTMF count register 0: 016Eh DTMF count register 1: 016Fh Timer RC counter: 0126h, 0127h Timer RD counter: 0156h, 0157h Timer RG counter: 0176h, 0177h (2) Peripheral I/Os during a user program halt During a user program halt, interrupts are not accepted although peripheral I/Os continue to run. For example, a timer interrupt is not accepted although the timer continues to count when a user program is stopped by a break after the timer started.
7.6 Debug functions
(1) PC break point When downloading a user program after modifying it, the set address of PC break may not be corrected normally depending on the modification. Therefore, break points other than the set PC breaks may shift. After downloading a user program, check the setting of PC breaks in the event point window and reset it. (2) "Go to cursor" function The "Go to cursor" function is actualized using an address match break. Therefore, when you execute the "Go to cursor" command, all the address match breaks and hardware breaks you set become invalid, while all the PC breaks remain valid.
REJ10J1930-0100 Page 31 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
(3) Debugging in stop mode or wait mode When debugging in stop mode or wait mode, do not operate windows until the program stops at the breakpoint by setting the breakpoint at the line of the program which will be executed after the stop mode or wait mode is cancelled. In addition, disable the automatic update in the watch window or fix the display in the memory window before running the program so memory accesses do not occur during an execution. When the program is forcibly stopped or when the memory is referred to or modified in stop mode or wait mode, these mode will be cancelled. (4) Note on debugging at less than 2.7V As flash rewrite occurs when the operations below are executed, if the operating voltage of the MCU is less than 2.7V, do not perform these operations: - Downloading the user program - Setting and canceling PC breaks (Setting/canceling event breaks are available) - Rewriting the value of the Flash memory in the memory window (5) Note on the CPU clock Do not use the CPU clock at less than 15.6 kHz (low-speed OCO divided by 8). (6) Low-current-consumption read mode When debugging in low-current-consumption read mode or the state that the flash memory is stopped, do not operate windows until the program stops at the breakpoint by setting the breakpoint at the line of the program which will be executed after each mode or state is cancelled.
REJ10J1930-0100 Page 32 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator
7. Notes on Using the E8a Emulator
(7) Exceptional step execution a) Software interrupt instruction Step execution cannot be performed in the internal processing of instructions (undefined, overflow, BRK and INT) which generate a software interrupt continuously in the program (see Figure 7.2).
NOP NOP INT#3 NOP JMP MAIN INT_3: NOP NOP NOP REIT Program should be stopped at this address. Passes through if the STEP execution is carried out.
Figure 7.2
Example of Software Interrupt Instruction
b) INT instruction To debug the user program with the INT instruction, set a PC break for the internal processing of the INT instruction and execute the program with the GO command (see Figure 7.3).
NOP INT #3 NOP JMP MAIN INT_3: NOP Break NOP REIT
Execute using GO command.
Figure 7.3
Example of INT Instruction
(8) DTC during a user program halt When the user program halts, or when the memory is referred to or modified while the user program is runnnig, data transfer using DTC is prohibited. (9) Note on using automatic memory update When the automatic memory update is enabled in the memory or watch window, do not execute Step Out or Multiple-step. Otherwise, it will take longer to update memory data and the operation will be delayed.
REJ10J1930-0100 Page 33 of 35
Rev.1.00 Jun. 01, 2009
E8a Emulator Additional Document for User's Manual Notes on Connecting the R8C/35A, R8C/36A and R8C/38A Publication Date: Published by: Jun. 01, 2009 Rev.1.00
Sales Strategic Planning Div. Renesas Technology Corp. Microcomputer Tool Development Department Renesas Solutions Corp.
Edited by:
(c) 2009. Renesas Technology Corp. and Renesas Solutions Corp., All rights reserved. Printed in Japan.
E8a Emulator Additional Document for User's Manual


▲Up To Search▲   

 
Price & Availability of R0E00008AKCE00EP57

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X