| |
Datasheet Home \ Datasheet Details
Download
PDF Abstract Text:
SM850
System Simulator Ver. 2.00 or Later Operation (Windows Based)
SM850
System Simulator Ver. 2.00 or Later Operation (Windows Based)
Target Device V850 FamilyTM
Document No. U13759EJ1V0UM00 (1st edition) Date Published August 1999 N CP(K)
V850 Family, V850 / SA1, V850 / SB1, V850 / SB2, V850E / MS1, V852, V853, and V854 are trademarks of NEC Corporation. UNIX is a trademark licensed by X / Open Company Limited in the United States and other countries. Pentium is a trademark of Intel Corporation. MS-DOS, Windows, and Windows NT are either registered trademarks or trademarks of Microsoft Corporation in the United States and / or other countries. PC / AT is a trademark of International Business Machines Corporation.
M7A 98. 8
Regional Information
Some information contained in this document may vary from country to country. Before using any NEC product in your application, pIease contact the NEC 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.
NEC Electronics Inc. (U.S.)
Santa Clara, California Tel: 408-588-6000 800-366-9782 Fax: 408-588-6130 800-729-9288
NEC Electronics (Germany) GmbH
Benelux Office Eindhoven, The Netherlands Tel: 040-2445845 Fax: 040-2444580
NEC Electronics Hong Kong Ltd.
Hong Kong Tel: 2886-9318 Fax: 2886-9022 / 9044
NEC Electronics Hong Kong Ltd. NEC Electronics (France) S.A.
Velizy-Villacoublay, France Tel: 01-30-67 58 00 Fax: 01-30-67 58 99 Seoul Branch Seoul, Korea Tel: 02-528-0303 Fax: 02-528-4411
NEC Electronics (Germany) GmbH
Duesseldorf, Germany Tel: 0211-65 03 02 Fax: 0211-65 03 490
NEC Electronics (France) S.A. NEC Electronics (UK) Ltd.
Milton Keynes, UK Tel: 01908-691-133 Fax: 01908-670-290 Spain Office Madrid, Spain Tel: 91-504-2787 Fax: 91-504-2860
NEC Electronics Singapore Pte. Ltd.
United Square, Singapore 1130 Tel: 65-253-8311 Fax: 65-250-3583
NEC Electronics Taiwan Ltd. NEC Electronics Italiana s.r.l.
Milano, Italy Tel: 02-66 75 41 Fax: 02-66 75 42 99
NEC Electronics (Germany) GmbH
Scandinavia Office Taeby, Sweden Tel: 08-63 80 820 Fax: 08-63 80 388
Taipei, Taiwan Tel: 02-2719-2377 Fax: 02-2719-5951
NEC do Brasil S.A.
Electron Devices Division Rodovia Presidente Dutra, Km 214 07210-902-Guarulhos-SP Brasil Tel: 55-11-6465-6810 Fax: 55-11-6465-6829
J99.1
INTRODUCTION
Readers
This manual is intended for user engineers who design and develop application systems of the V850 Family.
Purpose
This manual is intended for users to understand the functions of the SM850 in the organization below.
Organization
This manual consists of the following chapters: · General · Installation · Starting and exiting · Function of SM850 · Association with project manager · Window reference
How to Use This Manual
Conventions
Data significance: Note: Caution: Remark: Numerical representation:
Related Documents
The documents related to this manual are listed below. The related documents indicated in this publication may include preliminary versions. However, preliminary versions are not marked as such.
Documents related to the V850 Family
Document Name Part Number V852
Data Sheet
µPD703002 µPD70P3002
U11826E U11827E U12261E U13188E U12036E U13189E U12756E U12755E U13829E To be prepared To be prepared To be prepared To be prepared U13995E
U10038E
µPD703003 µPD703003A, 703004A, 703025A µPD70F3003 µPD70F3003A, 70F3025A
U10913E
µPD70F3008 µPD70F3008Y
U11969E
V850 / SA1 V850 / SB1
µPD703015 µPD703033, 703033Y µPD70F3033, 70F3033Y
U12768E U13568E
V850 / SB2
µPD703035, 703035Y µPD70F3035, 70F3035Y
U13850E
V850E / MS1
µPD703100-33, 703100-40, 703101-33, 703102-33 µPD703100-A33, 703100-A40, 703101-A33, 703102-A33 µPD70F3102-33 µPD70F3102-A33
U12688E
U12197E
U14168E
U13844E U13845E
Document Name Document Number U11595E U11596E U12420E U12898E U12887E Operation UNIX Based Operation Windows Based C language Assembly language ID850 (Ver. 1.31) (Integrated debugger) SM850 (Ver. 2.00) (System simulator) RX850 (Real-time OS) Operation Windows Based Operation Windows Based Basics Technical Installation RX850 Pro (Real-time OS) Fundamental Technical Installation RD850 (Task debugger)
Note TM
IE-703002-MC (In-circuit emulator for V852, V853, V854, V850 / SA1) IE-703003-MC-EM1 (Peripheral I / O board for V853) IE-703008-MC-EM1 (Peripheral I / O board for V854) IE-703017-MC-EM1 (Peripheral I / O board for V850 / SA1) IE 703100-MC (In-circuit emulator for V850E / MS1) CA850 (C compiler package)
U12839E U12827E U12840E U10543E U13716E This manual U13430E U13431E U13410E U13773E U13772E U13774E U11158E U13737E U11181E
RD850 (Ver. 3.0) (Task debugger) AZ850 (System performance analyzer)
Note ID850 (Ver. 1.31) supported
CONTENTS
CHAPTER 1 1.1 1.2 1.3 1.4
GENERAL............................................................. 19
Overview................................................................... 19 Features................................................................... 19 System Configuration ........................................................ 20 Operating Environment ...................................................... 21
1.4.1 1.4.2 Hardware environments.........................................................21 Software environments .........................................................21
Note for Debugging at Source Level ............................................ 21 INSTALLATION ........................................................ 23
CHAPTER 2 2.1 2.2
Installing SM850 ............................................................ 23 Uninstalling the SM850 ....................................................... 29 STARTING AND EXITING............................................... 31
CHAPTER 3 3.1 3.2
Starting .................................................................... 31 Exiting..................................................................... 33 FUNCTION OF SM850 .................................................. 35
CHAPTER 4 4.1
External Parts .............................................................. 35
4.1.1 4.1.2 4.1.3 4.1.4 Creating external parts..........................................................37 Displaying I / O manipulation and I / O results with external parts ...........................37 Operations of external parts at CPU reset ...........................................37 Editing on Parts window.........................................................38 Creating / editing input data .......................................................38 Downloading of input data file....................................................40 Processing when input data is not set..............................................41 Output to output data file and data display...........................................42 Setting event and action ........................................................42 Downloading event condition file ..................................................43
Data Input Function.......................................................... 38
Peripheral I / O Event & Action Setting Function................................... 42
Debugging Functions of SM850 ............................................... 44 ASSOCIATION WITH PROJECT MANAGER ............................... 47
CHAPTER 5 5.1 5.2 5.3
Debugger Registration in PM Project........................................... 47
5.1.1 5.2.1 Debugger selection ............................................................47 Reproducing the debug environment ...............................................48
Starting Up SM850 from PM ................................................... 48 Correction and Auto Load of Source File ........................................ 49
CHAPTER 6 6.1 6.2
WINDOW REFERENCE.................................................. 51
Window List................................................................ 51 Explanation of Windows ...................................................... 55
APPENDIX A APPENDIX B
DEBUGGING WITH SM850............................................ 429 TERMINOLOGY ...................................................... 433
B.1 Terminology ............................................................... 433 B.2 Window Type and Configuration .............................................. 441
B.2.1 B.2.2 Windows................................................................... 441 Dialog boxes ................................................................ 442
APPENDIX C APPENDIX D D.1 D.2 D.3 D.4 D.5 D.6 D.7 D.8
ERROR MESSAGE LIST .............................................. 443 KEY FUNCTION LIST ................................................. 473
Special Function Key Function List............................................ 473 Function Key Function List .................................................. 474 Special Function Key Function List ( SHIFT + Key) ............................. 475 Function Key Function List ( SHIFT + Key) .................................... 475 Special Function Key Function List ( CTRL + Key) ............................. 476 Function Key Function List ( CTRL + Key) .................................... 476 Control Key Function List ( CTRL + Key) ..................................... 476 Special Function Key Function List ( CTRL + SHIFT Key) ..................... 477 INDEX .............................................................. 479
APPENDIX E
LIST OF FIGURES (1 / 3)
Figure No. 1-1 3-1 3-2 3-3 3-4 3-5 3-6 4-1 4-2 4-3 4-4 4-5 4-6 4-7 4-8 4-9 4-10 4-11 5-1 6-1 6-2 6-3 6-4 6-5 6-6 6-7 6-8 6-9 6-10 6-11 6-12 6-13 6-14 6-15 6-16 6-17 6-18
Title
LIST OF FIGURES (2 / 3)
Figure No. 6-19 6-20 6-21 6-22 6-23 6-24 6-25 6-26 6-27 6-28 6-29 6-30 6-31 6-32 6-33 6-34 6-35 6-36 6-37 6-38 6-39 6-40 6-41 6-42 6-43 6-44 6-45 6-46 6-47 6-48 6-49 6-50 6-51 6-52 6-53 6-54 6-55 6-56 6-57 6-58 6-59
Title
LIST OF FIGURES (3 / 3)
Figure No. 6-60 6-61 6-62 6-63 6-64 6-65 6-66 6-67 6-68 6-69 6-70 6-71 6-72 6-73 6-74 6-75 6-76 6-77 6-78 6-79 6-80 6-81 6-82 6-83 6-84 6-85 6-86 6-87 6-88 6-89 6-90 6-91 6-92 6-93 6-94 6-95 6-96 6-97 C-1
Title
LIST OF TABLES
Table No. 4-1 4-2 6-1 6-2 6-3 6-4 6-5 6-6 6-7 6-8 B-1 B-2 C-1 C-2 C-3 D-1 D-2 D-3 D-4 D-5 D-6 D-7 D-8
Title
External Parts Supplied with SM850 ....................................................... 36 Operations of External Parts at CPU Reset ................................................. 38 Windows of SM850 Debugger............................................................ 51 SM850 Simulator Section Window List..................................................... 53 List of Other Windows .................................................................. 54 CPU Status Display Contents ............................................................ 61 IE Status Display Contents.............................................................. 61 Display Contents of Break Cause ......................................................... 61 STEP Modes ......................................................................... 62 Key Input Modes ...................................................................... 62 Delimiter Symbols .................................................................... 434 Register Set of V850 Family............................................................ 436 Error Message Type.................................................................. 443 Error Messages of Debugger ........................................................... 444 Simulator Section Error Message List ..................................................... 465 Special Function Key Function List ....................................................... 473 Function Key Function List ............................................................. 474 Special Function Key Function List ( SHIFT + Key) ......................................... 475 Function Key Function List ( SHIFT + Key)............................................... 475 Special Function Key Function List ( CTRL + Key) ......................................... 476 Function Key Function List ( CTRL + Key)................................................ 476 Control Key Function List ( CTRL + Key) ................................................. 476 Special Function Key Function List ( CTRL + SHIFT Key) ................................. 477
CHAPTER 1
GENERAL
1.1 Overview
1.2 Features
The features of the SM850 are as follows. (1) Evaluation without target By simulating the operations of the target device including the internal peripheral unit operation and interrupt servicing as well as the operation of CPU itself, the logic of the user program can be debugged without an incircuit emulator at an early stage. (2) Supports integrated debugging environment While maintaining the same operability as an in-circuit emulator. (3) Various simulation functions (a) External components By using standard "external components" of peripheral I / Os and I / O blocks used as GUI, such as LEDs, key matrixes, and motors, the simulated environment of the target system can be easily organized. The external components can input or output data during simulation. (b) Architecture of user target system The user logic section in the target system allows user-based architecture (programming) by means of a user-open interface. (c) Data input function Data with timing information created with two types of input editors can be input during simulation. The output result can be displayed as timing charts. (d) Peripheral I / O event and action setting functions Interrupts can be generated and data can be set at any time by using events set to peripheral I / O registers and addresses.
CHAPTER 1
GENERAL
(4) Two types of simulation mode Two types of simulation mode, which can be selected according to the purpose of debugging, are available. (a) Instruction operation mode This operation mode is used only for the simulation of instructions executed at high speeds. It is useful for debugging the logic of the user program. (b) Peripheral operation mode This mode is to verify internal and external peripheral operations while accurately simulating pipeline processing. In this mode, external peripherals dependent on the input / output data and devices are treated as components and as such the operation of peripherals can be visually verified and debugged.
1.3 System Configuration
The SM850 can debug user programs developed for the V850 Family by simulating the operation of the target device without an in-circuit emulator. Moreover, standard "parts" to simulate the target system are also provided with the SM850, so that you can develop the software without having to wait for the completion of production of the target system. (1) Example of system configuration Figure 1-1 shows an example of system configuration of the SM850. Figure 1-1. SM850 System Configuration Example
Host machine
Device SM850 file
CHAPTER 1
GENERAL
(2) Configuration of SM850 The SM850 consists of the following 2 parts. · Debugger section · Simulator section When the SM850 is started up, the debugger section and simulator section main windows are automatically opened (as buttons on the taskbar). All windows and dialog boxes are activated from these main windows.
1.4 Operating Environment
To use the SM850, the following hardware and software environments are necessary. 1.4.1 Hardware environments (1) Host machine · PC-9821 series · PC98-NX series · IBM PC / AT or compatibles (2) CPU · Pentium 100 MHz or faster (120 MHz or faster recommended) (3) Memory · RAM: 32 Mbytes or more (64 Mbytes or more recommended) 1.4.2 Software environments (1) OS Windows95, Windows NT (Ver. 4.0), and Windows98 (2) Device file Device file of target device to be used
1.5 Note for Debugging at Source Level
When debugging at source level, add an option (-g option) that creates debugging information after the source files have been compiled. If this is not done, debugging cannot be performed in the source level.
CHAPTER 2
INSTALLATION
This chapter explains how to install / uninstall the SM850 and to customize the environment setting file of it.
2.1 Installing SM850
In order to use the SM850, it is necessary to install both the SM850 and a device file. Install the device file using the dedicated installer "DFINST.exe" (supplied with the SM850). Caution If reinstalling the SM850, be sure to uninstall it first. If the SM850 is not uninstalled and
CHAPTER 2
INSTALLATION
CHAPTER 2
INSTALLATION
. The default destination drive or
Note If the latest version of the peripheral simulation DLL is supplied with the device file, clear the check mark from the V850 Peripheral Simulation DLL check box and install the peripheral simulation DLL (SPxxxx.dll) when installing the device file. On the other hand, if the latest version of the peripheral simulation DLL is supplied with the SM850, click to select the V850 Peripheral Simulation DLL check box, and then clear the check box when installing the device file. Caution If a previously installed SM850 has not been uninstalled, a dialog box querying whether to uninstall it will be displayed.
CHAPTER 2
INSTALLATION
CHAPTER 2
INSTALLATION
Displays the installation status
Change-of-system-disk message
CHAPTER 2
INSTALLATION
Installation of SM850 is now complete.
CHAPTER 2
INSTALLATION
2.2 Uninstalling the SM850
CHAPTER 2
INSTALLATION
CHAPTER 3
STARTING AND EXITING
This chapter explains how to start and exit the SM850.
3.1 Starting
Figure 3-2. Configuration Dialog Box on Starting
CHAPTER 3
STARTING AND EXITING
button will be displayed on the Windows taskbar (See Figure 3-4).
Note When the device to be debugged is one of the following: V850 / SA1, V850 / SB1, V850 / SB2, V852, V853, or V854. If the device to be debugged is the V850E / MS1, the button displayed will be that of the V850E Simulator GUI. Figure 3-3. Main Window
Figure 3-4. V850 Simulator GUI Button
Caution
Problems such as the occurrence of application errors and dialog boxes not displaying data correctly are sometimes experienced when the SM850 is started up, or while it is in use. One cause of such problems may be that an old version of comctl32.dll, which comes with Windows95, is being used. disks. Note that if Microsoft InternetExplorer3.X or 4.X has been installed, this update is unnecessary. If this is the case, it will be necessary to update comctl32.dll using the comctl32.dll 4.72 Installer (40comupd.exe) included in the system
CHAPTER 3
STARTING AND EXITING
Figure 3-5. comctl32.dll 4.72 Installer
3.2 Exiting
CHAPTER 4
FUNCTION OF SM850
This chapter details the functions of SM850 simulation (external parts, data input function, peripheral I / O event & action function) and of debugging.
4.1 External Parts
The SM850 supplies standard "external parts" such as peripheral I / Os and I / O blocks as icons. Using these parts, a dummy target system can be organized. Figure 4-1. Example of SM850 External Parts
Button
Key matrix
Level gauge
14-segment LED
7-segment LED
Buzzer DC motor Reset button Internal interrupt button
Serial GUI window
CHAPTER 4
FUNCTION OF SM850
The SM850 supplies the following external parts: Table 4-1. External Parts Supplied with SM850
External Part Name Button Description A button can be connected to any pin. By pressing the displayed button, an input value can be given to the pin. A key matrix can be connected to any pin, so that data can be input by pressing two or more keys. Can display the output status of a pin connected to the LCD controller / driver incorporated in the device to be debugged in pictures or characters. Can display the output status of a pin connected to the FIP controller / driver incorporated in the device to be debugged in pictures or characters. An LED can be connected to any pin to indicate the output of the pin by lighting or extinguishing. Any value in a specified range can be given to a pin connected to the A / D converter. Any eight pins (seven pins for displaying numerals and one pin for the decimal point) are allocated to a 7-segment LED and one pin is allocated to a digit signal, so that the display of the 7-segment LED changes depending on the value of each pin. The corresponding 7-segment LED lights or extinguishes if the output of the pin allocated to the digit signal is active. A DC motor can be connected to any pin, and revolution or stopping of the DC motor shows the output value of the pin. The total time during which an active value is output is counted from the beginning of simulation and is displayed. A buzzer can be connected to any pin, and the output status can be indicated by the buzzer sound or by a change in the bit map. Hardware reset is executed by clicking the displayed reset button. Any 15 pins (14 pins for displaying numerals and one pin for the decimal point) are allocated to a 14-segment LED and one pin is allocated to a digit signal, so that the display of the 14-segment LED changes depending on the value of each pin. The corresponding 14-segment LED lights or extinguishes if the output of the pin allocated to the digit signal is active. Any internal interrupt can be connected to a button. By pressing the displayed button, the internal interrupt can be generated. Whether a pin is connected to a pull-up / pull-down resistor Can input the PLL input frequency and display the PLL frequency data and the IFC counter, etc. The operation mode and I / O information of the serial interface can be displayed.
Key matrix Internal LCD
Internal FIP
LED Level gauge 7-segment LED
DC motor
Buzzer
Reset button 14-segment LED
Internal interrupt button
Pull-up / pull-down setting PLL Serial GUI
Note To issue a buzzer sound, however, a sound board and a speaker are necessary. Remark Depending on the device to be debugged, some external parts are unable to be selected.
CHAPTER 4
FUNCTION OF SM850
4.1.1 Creating external parts The external parts are created in the Parts Window (p.378). Connection between the external parts and pins are made in the dialog box that is opened by the Parts menu on the Parts Window, or by clicking buttons on the tool bar For the details of setting, refer to the explanation on each dialog box. Figure 4-2. Parts Window
4.1.2 Displaying I / O manipulation and I / O results with external parts External parts whose setting has been completed on each dialog box are displayed on the Parts window and serve as an inlet for signals during simulation. By using these displayed parts, the I / O results can be checked and input values can be given to the simulator. For details of the I / O manipulation of each external part, refer to the description of the setting dialog box for each part. I / O manipulation is executed with the Parts window in the execution mode. 4.1.3 Operations of external parts at CPU reset Table 4-2 shows the operations of the respective external parts when a CPU reset is generated from the debugger.
CHAPTER 4
FUNCTION OF SM850
Table 4-2. Operations of External Parts at CPU Reset
External Parts Button Key LED 7- / 14-segment LED Level gauge Inactive status Not pressed Inactive status Displayed in white Input value of 0. Scroll sum of scroll bar is at leftmost position, and operation point of dial is at lower left. Inactive status with total number of clocks being 0 Inactive status Not pressed Initial status Operation at CPU Reset
DC motor Buzzer Internal interrupt button Serial GUI
4.1.4 Editing on Parts window On the Parts window, parts can be moved, characters, lines, and rectangles can be written, and the bit map of the external parts can be changed. For editing, select Mode Edit on the Parts window. As a result, the Parts window is set in the location mode in which editing can be carried out. In the location mode, the mouse cursor changes to "+", and a window that indicates the pointer position of the mouse with coordinates (x, y) pops up, and editing is enabled. For the details of editing operations, refer to the description of the Parts window (p.378).
4.2 Data Input Function
The SM850 can input data with timing information to input pin created by using two types of input editors, during simulation. The result output from the simulator can be saved, and can be displayed as a timing chart. 4.2.1 Creating / editing input data The data file with timing information is created or edited in the Input 0 / 1 Editor window or Input timing Chart Editor window. (1) Input 0 / 1 Editor window (see p.354) Data to be input to a pin at any timing is set as a numeric value in 1 bit units. A wait value (input timing) or data input can be set by using a loop.
CHAPTER 4
FUNCTION OF SM850
Figure 4-3. Input 0 / 1 Editor Window
(2) Input timing Chart Editor window (see p.360) Input timing and input data are set as a timing chart. Data can be set by setting wait values (input timing) or by using a time axis. Figure 4-4. Input Timing Chart Editor Window
Note 1
Note 2
CHAPTER 4
FUNCTION OF SM850
4.2.2 Downloading of input data file An input data file is downloaded in the Simulation Data Load dialog box (see p.367). Figure 4-5. Simulation Data Load Dialog Box
Note If an input data file is downloaded while an input external part is displayed, input from the input data file takes precedence. If an external part for input is displayed while an input data file is downloaded, input from the external part takes precedence.
CHAPTER 4
FUNCTION OF SM850
The pull-up / pull-down processing can be set in advance by the Pull-Up / Pull-Down dialog box (see p.415). Figure 4-7. Pull-Up / Pull-Down Dialog Box
CHAPTER 4
FUNCTION OF SM850
4.2.4 Output to output data file and data display The output status can be output to a file in the Output Setting dialog box (see p.369). If the timing chart output is checked in the Output Setting dialog box, the Output Timing Chart window (see p.371) is opened, and the output status can be displayed on a timing chart. An identifier (.out) is automatically appended to the output file. Figure 4-8. Output Timing Chart Window
Because the data input to the peripheral I / O registers, as well as the output data from the peripheral I / O registers, can be also saved to the output file, the I / O status can be later checked.
4.3 Peripheral I / O Event & Action Setting Function
The SM850 can generate an interrupt at any timing, or set any data to any address, peripheral I / O register, or pin after a specified event condition has been satisfied, by specifying an event set to any peripheral I / O register or address as a trigger. These settings are reflected during simulation. 4.3.1 Setting event and action An event condition and the operation (action) to be performed after the event condition has been satisfied are set in the IOR Event & Action dialog box (see p.350).
CHAPTER 4
FUNCTION OF SM850
Figure 4-9. IOR Event & Action Window
As an event condition, any address, register name, access status, or access size, or data condition or mask condition can be specified. As an action, an interrupt can be generated at specified timing, or any data can be set to a specified address (address, peripheral I / O register (IOR), or pin). The specified event condition and action are saved to an event condition file (.evn). 4.3.2 Downloading event condition file The specified event condition file is downloaded in the Simulation Data Load dialog box (see p. 367). Figure 4-10. Simulation Data Load Dialog Box
By downloading the event condition file (.evn), an event is registered to the simulator, and the event can be checked during simulation.
CHAPTER 4
FUNCTION OF SM850
4.4 Debugging Functions of SM850
The debugging functions of the SM850 are almost the same as those of the ID850. However, they are slightly different because the SM850 implements debugging through software, without using an in-circuit emulator. (1) Differences in mapping functions The SM850 virtually manages a contiguous memory space same as that of the target device specified on the Configuration dialog box, by allocating an alternate memory on the host machine. In this way, the size of the internal ROM / RAM area can be changed, or any memory area can be mapped as an emulation ROM / RAM area. Figure 4-11 shows the target memory space when the µPD703000 is specified as the CPU in the Configuration dialog box. Figure 4-11. Memory Space Managed by SM850 (µPD703000)
0xFFFFFF Peripheral I / O registers (4 KB) 0xFFF000 0xFFEFFF Internal RAM (4 KB) 0xFFE000 0xFFDFFF Memory space: 16 MB External memoryNote (15 MB to 8 KB) Range that can be mapped · Guard area · Emulation ROM · Emulation RAM Target memory
Size can be changed depending on the target device
Program memory
Data memory
0x100000 0x0FFFFF Internal ROM (1 MB) 0x000000 Size can be changed depending on the target device
CHAPTER 4
FUNCTION OF SM850
(2) Simulation mode specification A simulation operation mode can be specified on the Configuration dialog box (see p.82) in accordance with the stage of debugging. · Instruction operation mode In this mode, simulation is repeatedly executed in 1-instruction units. Peripheral functions do not operate. After simulation has been started, this mode can be changed to the pipeline operation mode. · Peripheral operation mode In this mode, the pipeline operation is accurately implemented while one-instruction execution is simulated in 1-clock units. Peripheral simulation is also carried out. After simulation has been started, this mode can be changed to the instruction operation mode. (3) Differences in event functions This function has the following features. · An event condition of the same name can be set to two or more event conditions. · Up to 80 break event conditions can be set. · Setting of external sense data is invalid. · Pass count can be set. (4) Differences in break function · A software break event condition cannot be set. (5) Differences in timer function This function has the following features. · Eight timer event conditions can be set. · The average / maximum / minimum / estimated simulation time in a zone specified by a timer event condition can be measured. (6) Differences in trace function This function has the following features. · The size of the trace capacity can be specified. · 0 frames to 16M frames · Display of block information · Display type of trace mode A .. All trace or section trace Q .. Qualify trace S .. Step execution trace · Display of branch destination address
CHAPTER 5
ASSOCIATION WITH PROJECT MANAGER
This chapter explains the procedure and notes on using the functions associated with the Project Manager. The SM850 can automatically perform a sequence of tasks such as creating a program, compiling, debugging, and correcting the program, in association with the Project Manager (PM). To debug a load module file created in the PM at the source level, confirm that the item Option Debug is checked for building. Caution When a load module file is created by using an MS-DOS associated with the PM cannot be used.
prompt, the functions of the SM850
5.1 Debugger Registration in PM Project
CHAPTER 5
ASSOCIATION WITH PROJECT MANAGER
5.2 Starting Up SM850 from PM
with the PM (eg: aaa.prj).
CHAPTER 5
ASSOCIATION WITH PROJECT MANAGER
5.3 Correction and Auto Load of Source File
CHAPTER 6
WINDOW REFERENCE
This chapter explains in detail the functions of the windows and dialog boxes of the SM850. For the configuration and details of the types of the windows and dialog boxes, refer to APPENDIX B TERMINOLOGY.
6.1 Window List
Table 6-1 lists the windows of the SM850 debugger. Table 6-1. Windows of SM850 Debugger (1 / 3)
Window Name Main window Outline This window is displayed first when the simulator is started. It controls execution of the user program. In addition, various windows are opened from this window. Sets / display simulator environment. Sets / display each extended option. This is where each option is displayed and set. This is where the type and size of the display font in the Source window is set. Reads debugging environment. Saves debugging environment. This is where the display files of each window and the source text and event setting files are read. This is where the display files of the current window and the event setting files are saved. This is where the object files, binary files, and coverage results are downloaded. This is where the downloaded load module files and file path names are displayed in a list. This is where the memory or coverage contents are saved to a file. This is where the files to be set in the Debugger Option Setting or Source Search dialog boxes are selected. This is where the files to be displayed in the Source window and the display start position are specified. This is where the display start address for the Memory, Assemble, and Coverage windows is specified. This is where the display start position for the Trace View window is specified. This is where the addresses and symbol values of variables and functions are displayed. Displays source text and source file. This is where a character string in a source file is searched. Displays disassemble text and executes on-line assemble. This is where the contents of the Assemble window are searched. Displays / changes memory contents. Page p.56
Configuration dialog box Extended Option dialog box Debugger Option dialog box Font dialog box Project File Load dialog box Project File Save dialog box View File Load dialog box
p.82 p.87 p.92 p.99 p.102 p.105 p.109
View File Save dialog box
p.112
Download dialog box Load Module List dialog box
p.117 p.121
Upload dialog box Browse dialog box
p.123 p.126
Source Move dialog box
p.128
Address Move dialog box
p.131
Trace Move dialog box Symbol To Address dialog box
p.134 p.137
Source Window Source Search dialog box Assemble window Assemble Search dialog box Memory window
p.140 p.154 p.157 p.169 p.172
CHAPTER 6
WINDOW REFERENCE
Table 6-1. Windows of SM850 Debugger (2 / 3)
Window Name Memory Search dialog box Memory Fill dialog box Memory Copy dialog box Memory Compare dialog box Memory Compare Result dialog box Watch window Quick Watch dialog box Add Watch dialog box Register window Outline This is where the contents of the Memory window are searched. This is where the memory contents are initialized by specified data. Copies memory contents. Compares memory contents. Displays result of comparison of memory contents. Page p.176 p.179 p.181 p.183 p.185
This is where variables are displayed and changed. This is where variable values are temporarily displayed and changed. This is where variables to be displayed in the Watch window are registered. This is where the contents of registers (program register, system register) are displayed and changed. Selects register displayed on the Register Window. Displays / changes contents of peripheral I / O register. This is where peripheral I / O registers and I / O ports to be displayed in the IOR window are selected. This is where I / O ports to be displayed in the IOR window are registered. Displays / changes local variable in current function. This is where the stack contents of the current user program are displayed and changed. Displays trace result. This is where trace data is searched. This is where items to be displayed in the Trace View window are selected. Displays coverage result. This is where coverage results are searched. This is where the coverage results are cleared. This is where a 1-Mbyte or greater space is selected for the coverage measurement range. This is where the coverage efficiency measurement range is set.
p.187 p.192 p.196 p.199
Register Select dialog box IOR window IOR Select dialog box
p.202 p.204 p.207
Add I / O Port dialog box Local Variable window Stack window
p.210 p.213 p.215
Trace View window Trace Search dialog box Trace Data Select dialog box Coverage window Coverage Search dialog box Coverage - Clear dialog box Coverage - Address dialog box
p.219 p.227 p.234 p.237 p.242 p.245 p.247
Coverage - Condition Setting dialog box Coverage - Efficiency View dialog box Event Manager
p.249
This is where the coverage results are displayed in terms of efficiency.
p.252
This is where each event is displayed, switched between enabled and disabled, and deleted. Registers / displays event condition. Registers / displays event link condition. Registers / sets / displays break event condition. Registers / sets / displays trace event condition. Registers / sets / displays snap event condition. Registers / sets / displays stub event condition.
p.255
Event dialog box Event Link dialog box Break dialog box Trace dialog box Snap Shot dialog box Stub dialog box
p.264 p.278 p.288 p.295 p.308 p.322
CHAPTER 6
WINDOW REFERENCE
Table 6-1. Windows of SM850 Debugger (3 / 3)
Window Name Timer dialog box Outline Displays result of simulation time measurement and registers / sets / displays timer event condition. This is where the results of the executed measurement are displayed. Initializes SM850 and target CPU and symbol information. Displays version of SM850. Ends SM850. Page p.329
Timer Result dialog box Reset Debugger dialog box About dialog box Exit Debugger dialog box
p.339 p.341 p.343 p.344
The SM850 simulator section window list is shown in Table 6-2 below. Table 6-2. SM850 Simulator Section Window List (1 / 2)
Window Name V850 Simulator GUI window IOR Event & Action dialog box Input 0 / 1 Editor window Input Timing Chart Editor window Pin Setting dialog box Main window of simulator (SM850). Sets / displays event and action for peripheral I / O register and any address. Sets input value to input pin (0 / 1 format). Sets input value to input pin (timing chart format). Sets pin names displayed in the Input 0 / 1 Editor window, Input Timing Chart Editor window, and Output Timing Chart window. This is where the input data files and event condition files are downloaded. Saves file of output result from the output pin and displays timing chart. This is where the pin I / O data and interrupt signal timing charts are displayed. Searches I / O data. Sets / displays external parts. Sets connection information on button and pin displayed in the Parts window. Sets connection information on key matrix and pin displayed in the Parts window. Sets connection information on LED and pin displayed in the Parts window. Sets connection information on 7-segment LED and pin displayed in the Parts window. Sets connection information on level gauge and pin displayed in the Parts window. Sets connection information on DC motor and pin displayed in the Parts window. Sets connection information on buzzer and pin displayed in the Parts window. Sets connection information on 14-segment LED and pin displayed in the Parts window. Sets connection information on internal interruption button and pin displayed in the Parts window. Sets connection information on pull-up / pull-down resister pin displayed in the Parts window. Displays I / O information on serial interface. Registers / deletes bitmap files of the external parts displayed in the Parts window. Specifies file subject to operation. Outline Page p.346 p.350 p.354 p.360 p.365
Simulation Data Load dialog box Output Setting dialog box Output Timing Chart window Search window Parts window Buttons dialog box Key Matrixes dialog box LEDs dialog box 7seg LEDs dialog box Level Gauges dialog box DC Motors dialog box Buzzers dialog box 14seg LEDs dialog box
p.367 p.369 p.371 p.375 p.378 p.389 p.392 p.396 p.399 p.402 p.405 p.408 p.410
Internal Interrupt Button dialog box Pull-Up / Pull-Down dialog box
p.413
p.415
Serial GUI window Bitmap Entry dialog box Open dialog box
p.417 p.419 p.423
CHAPTER 6
WINDOW REFERENCE
Table 6-2. SM850 Simulator Section Window List (2 / 2)
Window Name Save As dialog box Saves file subject to operation Outline Page p.425
Table 6-3. List of Other Windows
Window Name Error / Warning dialog box Displays error / warning message Outline Page p.427
CHAPTER 6
WINDOW REFERENCE
6.2 Explanation of Windows
This section explains each window using the format shown below.
Window Name
Window type
The window name and window type (mode type when dialog box) are indicated in the above frame.
General Briefly explains the window.
Opening method How to open the windows is explained.
Window Shows the screen image of the configuration of the window.
Function Explains each function of the window.
Function button Explains the operations of the function buttons in the window.
Menu bar Enumerates the menus pulled down from the menu bar, and explains the function of each menu.
Caution Explains points of caution to be noted.
CHAPTER 6
WINDOW REFERENCE
Main Window
Main window
General This window is automatically opened after the SM850 is started and initialization is complete. It remains displayed until the SM850 is terminated. Various windows are opened and manipulated from this window. Execution of the user program is also controlled in this window. Execution of the user program can be controlled in three modes: source mode, instruction mode, and auto mode. · Source mode Debugging is performed at the source level. · Instruction mode Debugging is performed at the instruction level. · Auto mode Switches automatically between the source mode and instruction mode. When starting the SM850, the auto mode is assumed.
Window
Figure 6-1. Main Window
CHAPTER 6
WINDOW REFERENCE
Function The Main window consists of the following areas. · Tool bar · Window display area · Status display area Each function is explained below. (1) Tool bar The tool bar consists of buttons that can execute frequently used commands with a single click. Each button is graphically displayed and easy to understand. This button group can be switched between "Graphics-only buttons" and "Graphics + Text buttons" by the Debugger Option Setting dialog box. The function of each button can be also executed using the menu bar in this window. This tool bar is not shown when it is specified not to be displayed by selecting Option Tool Bar from the menu bar of this window. Figure 6-2. Tool Bar
Graphics-only tool bar
Graphics + Text tool bar
An explanation of each button is given below. This button stops execution of the user program. The same function as Run Stop on the menu bar. After the emulation CPU is reset, this runs the user program simulation. Its function is the same as Run Restart on the toolbar. This runs the user program simulation without resetting the emulation CPU. The same function as Run Go on the menu bar. Executes the program real-time until execution returns to the calling function. The same function as Run Return Out on the menu bar. This button is used for step execution. By clicking this button successively, the program is executed by as many steps as the number of times this button is clicked. Step execution is performed in line units in the source mode, and in instruction units in the instruction mode. The same function as Run Step In on the menu bar.
CHAPTER 6
WINDOW REFERENCE
This button executes the Next step (Simulates the program, regarding the function / call statement as one step.). By clicking this button successively, Next step execution is performed as many times as the number of times this button is clicked. Step execution is performed in line units in the source mode, and in instruction units in the instruction mode. The same function as Run Next Over on the menu bar. This button resets the emulation CPU. The same function as Run CPU Reset on the menu bar. Opens the Display File Load dialog box. Its function is the same as File Open on the menu bar. Opens the Download dialog box. Its function is the same as File Download on the menu bar. Opens the Project File Load dialog box. Its function is the same as File Project Open on the menu bar. This button opens the Source Window and displays the contents of the source text. The same function as Browse Source Text on the menu bar. This button opens the Assemble Window and the user program is disassembled and displayed. The same function as Browse Assemble on the menu bar. This button opens the Memory Window and the memory contents are displayed. The same function as Browse Memory on the menu bar. Displays the watch contents. Opens the Watch window. Its function is the same as Browse Watch on the menu bar. This button opens the Register Window and displays the contents of the registers. The same function as Browse Register on the menu bar. This button opens the IOR Window and displays the contents of the peripheral I / O register. The same function as Browse I / O Register on the menu bar. Displays the local variable contents. Opens the local variable window. Its function is the same as Browse Local Variable on the menu bar. This button opens the Stack Window and displays the contents of the stack. The same function as Browse Stack Trace on the menu bar.
CHAPTER 6
WINDOW REFERENCE
This button opens the Trace View window and displays the result of trace. The same function as Browse Trace on the menu bar. Displays the coverage measurement results. Opens the Coverage window. Its function is the same as Browse Coverage on the menu bar. Opens the event manager. Its function is the same as Event Event Manager on the menu bar. Performs event entry and settings. Opens the Event dialog box. Its function is the same as Event Event.. on the menu bar. This button opens the Break dialog box and registers, sets, or displays break events. The same function as Event Break.. on the menu bar. This button opens the Trace dialog box and registers, sets, or displays trace events. The same function as Event Trace.. on the menu bar. This button opens the Timer dialog box, registers, sets, or displays timer events, and displays the result of timer measurement. The same function as Event Timer.. on the menu bar. (a) Tool hint function If the mouse cursor is pointed at any of the buttons on the tool bar, a tool hint pops up after a few seconds. Figure 6-3. Example of a Tool Hint
(b) Moving the tool bar By dragging tool bar with the mouse, it can be moved to any desired position within or outside the Main window.
CHAPTER 6
WINDOW REFERENCE
(2) Window display area This area displays various debug windows. The displayed window can be changed in size or registered as an icon in this area. The list of the windows displayed in this area is as follows. · Source window · Assemble window · Watch window · Memory window · Register window · IOR window (3) Status display area Figure 6-4. Status Bar · Local Variable window · Stack window · Trace View window · Coverage window · Event Manager
The types of CPU statuses are shown below.
CHAPTER 6
WINDOW REFERENCE
Table 6-4. CPU Status Display Contents
Status Indication HALT RESET Currently in the halt mode Reset state Meaning
The types of IE statuses are shown below. Table 6-5. IE Status Display Contents
Status Indication RUN STEP TRC TIM COV BREAK Meaning Currently simulating a user program Currently simulating a step Currently operating a trace Currently operating a timer Currently operating Coverage Break
The causes of a break are as follows. Table 6-6. Display Contents of Break Cause
Displayed Cause Manual Break Temporary Break Event Break Trace Full Break Non Map Break Write Protect IOR Illegal Forcibly break Temporary break Break by event Break by trace full Access in non-map area Write access to write-protected area Illegal access to peripheral I / O register Meaning
CHAPTER 6
WINDOW REFERENCE
The types of STEP modes are shown below. Table 6-7. STEP Modes
STEP Mode SRC Meaning STEP simulation is in the source mode. This is displayed when Options Source Mode in the menu bar is selected. STEP simulation is in the instruction mode. This is displayed when Options Instruction Mode in the menu bar is selected. STEP simulation is in the auto mode. This is displayed when Options Auto Mode in the menu bar is selected.
The types of key input modes are shown below. Table 6-8. Key Input Modes
Key Input Mode INS OVR Meaning Displayed when key input is in the insert mode. Displayed when key input is in the overwrite mode.
CHAPTER 6
WINDOW REFERENCE
(a) Menu explanation display function While selecting a menu item on the menu bar with the mouse, a simple explanation of the reverse highlighted item in the menu is displayed on the left end of the status bar. Also, when the mouse cursor is pointed at any of the buttons on the toolbar, a menu explanation corresponding to that button is displayed. Figure 6-5. Example of Menu Explanation Display
CHAPTER 6
WINDOW REFERENCE
Menu bar
(1) File Figure 6-6. File Menu Bar
Open..
This loads the display file or a source file or text file. Opens the Display File Load dialog box. Operation differs depending on the file extension selected in the dialog box. When a display file: When an event setting file (.evn): Files are displayed in the Source window. The Event Manager is opened and the event is set. Other than above (.S, .C, .txt, .svw): Files are displayed in the Source window.
Save As..
Saves the displayed contents of the current window in a display file under another name. Opens the display file save dialog box.
Close Download.. Load Module..
Closes the current window. Downloads the user program. Opens the Download dialog box. Displays a list of the names of files that have been downloaded. Opens the Load Module List dialog box.
Upload..
Uploads the user program. Opens the Upload dialog box.
CHAPTER 6
WINDOW REFERENCE
Project
Operates a project file. Reads the contents of the project file. Opens the Project File Load dialog box.
Open..
Overwrites the current status to the project file. The file to be overwritten is selected by selecting File Project Open Project.. from the menu bar, or Save As..
Save As..
Saves the current status in the project file. Opens the Project File Save dialog box.
Debugger Reset..
Resets the target CPU, symbols and debugger. Opens the Reset Debugger dialog box.
Exit Open File
Terminates the debugger. Opens the Exit Debugger dialog box. Displays a list of the names of files that can be downloaded. If a file name is selected, that file is downloaded.
(2) Edit Figure 6-7. Edit Menu Bar
Cut Copy Paste Write in Restore Memory Fill..
Cuts the selected character string and places it in the clipboard buffer. Copies the selected character string to the clipboard buffer. Pastes the contents of the clipboard buffer at the text cursor position. Writes corrections to the target. Cancels the correction. Manipulates the memory contents. Initializes the memory contents. Opens the Memory Fill dialog box.
CHAPTER 6
WINDOW REFERENCE
Copy..
Copies values from memory to memory. Opens the Memory Copy dialog box.
Compare..
Compares values between memories. Opens the Memory Compare dialog box.
Edit Source
When the Project Manager is operating, opens the source file displayed in an active Source Window by using the editor specified by the Project Manager.
CHAPTER 6
WINDOW REFERENCE
(3) View The items displayed in the display menu differ according to whether the window is active or not. explanation of each dependent part is given in (b) to (k). Figure 6-8. View Menu Bar An
CHAPTER 6
WINDOW REFERENCE
(a) Common part
Search..
Searches character strings and numeric values. Opens the Find dialog box according to the current window. Performs the same operation as the Search button.
Move..
This moves the display position. It opens the Source Move dialog box, Address Move dialog box or Frame Move dialog box corresponding to the current window.
Quick Watch..
Displays the contents of the specified data temporarily. Opens the Quick Watch dialog box.
Add Watch..
Adds the specified data to the Watch window. Opens the Add Watch dialog box.
View Watch
Adds the selected data to the Watch window. In the case of a symbol, it adds it in accordance with the settings in the Debugger Option Setting dialog box.
Delete Watch
Deletes the selected watch point from the Watch window. This menu is active only when variables are specified in the Watch window.
Symbol..
Displays the address of the specified variable or function and the value of the specified symbol. Opens the Symbol To Address dialog box.
(b) Source window dependent part
Switches between assemble display mixed display and no display. No check mark (" ") : There is no mixed display (default). Check mark ( ""): There is a mixed display.
(c) Assemble window dependent part
Displays event information for the cursor position address. If an event is set, it opens the Event dialog box.
(d) Memory window dependent part
Bin Oct Dec Hex
Displays the current window in binary. Displays the current window in octal. Displays the current window in decimal. Displays the current window in hexadecimal (default).
CHAPTER 6
WINDOW REFERENCE
Nibble Byte Half Word Word Ascii
Displayed in 4-bit units. Displays data in 8-bit units (default). Displays data in 16-bit units. Displays data in 32-bit units. Turns ON / OFF display of ASCII characters. No check mark (" "): Not displayed. Check mark ( ""): Displayed (default).
(e) Watch window dependent part
Bin Oct Dec Hex String Proper
The selected item is displayed as a binary number The selected item is displayed as an octal number. The selected item is displayed as a decimal number. The selected item is displayed as a hexadecimal number. The selected item is displayed as a character string. The selected item is displayed as the standard value for each variable. In the case of symbols, they are displayed in accordance with the settings in the Debugger Option Setting dialog box (default).
Byte Half Word Word Adaptive
The selected item is displayed in 8-bit units. The selected item is displayed in 16-bit units. The selected item is displayed in 32-bit units. The selected item is displayed as standard values for each variable. In the case of C language symbols, only this item is valid. In the case of assembler symbols, they are displayed in accordance with the settings in the Debugger Option Setting dialog box.
Up Down Compulsion Read
The selected data is moved 1 line up. The selected data is moved 1 line down. The data in the peripheral I / O registers, where reading is prohibited because the values will change if they are read, the I / O ports added in the Add I / O Port dialog box, and the I / O protected areas is subjected to compulsory reading.
CHAPTER 6
WINDOW REFERENCE
(f) Register window dependent part
Bin Oct Dec Hex Pick Up
Displayed as a binary number. Displayed as an octal number. Displayed as a decimal number. Displayed as a hexadecimal number. Displays only the register selected in the Register Select dialog box. No check mark (" "): All are displayed (default). Check mark ( ""): The selected register only is displayed.
Select
Opens the Register Select dialog box.
(g) IOR window dependent part
Bin Oct Dec Hex Sort by Name Sort by Address Unsorted Attribute
Displayed as a binary number. Displayed as an octal number. Displayed as a decimal number. Displayed as a hexadecimal number (default). Displayed in alphabetical order. Displayed in address order (default). Not sorted. Selects whether to display or not to display the Attribute field. No check mark (" "): Not displayed. Check mark ( ""): Displayed (default).
Pick Up
Only the peripheral I / O register selected in the IOR Select dialog box is displayed. No check mark (" "): All are displayed (default). Check mark ( ""): The selected register only is displayed.
Select Compulsion Read
Opens the IOR Select dialog box. The data in the peripheral I / O registers, where reading is prohibited because the values will change if they are read, the I / O ports added in the Add I / O Port dialog box, and the I / O protected areas is subjected to compulsory reading.
CHAPTER 6
WINDOW REFERENCE
(h) Local Variable window dependent part, Stack Trace window dependent part
Bin Oct Dec Hex String Proper
Displayed as a binary number. Displayed as an octal number. Displayed as a decimal number. Displayed as a hexadecimal number. Displayed as a character string. Displayed as the standard value for each variable (default).
(i) Trace window dependent part
Select
Selects the content of the display. Opens the Trace Select dialog box
|