background image

Debugger db62 (3)

Development Tools

Cascade
Cascades the opened windows. 
Tile 
Tiles the opened windows. 

This menu shows the currently opened window names. 
Selecting one activates the window.

Contents...
Displays the contents of help topics. 
About Db62...
Displays an About dialog box for the debugger. 

[Window] menu  

[Help] menu  

Menus

Trace Area...
Sets or clears program address ranges for tracing.
Trace Condition...
Sets a trace condition (Start, Middle, End).
Trace Search...
Searches trace information from the trace memory.
Trace File...
Saves the specified range of the trace information displayed in the [Trace] 
window to a file.

Command
Activates the [Command] window. 

Program (Unassemble, Source Display, Mix Mode)
Opens or activates the [Source] window and displays the 
program from the current PC address in the display mode 
selected from the sub menu items.

Data Dump
Opens or activates the [Data] window and displays the data memory 
contents from the memory start address.
Register
Opens or activates the [Register] window and displays the current values 
of the registers. 
Trace 
Opens or activates the [Trace] window and displays the trace data sampled 
in the ICE trace memory. 
Toolbar 
Shows or hides the toolbar. 
Status Bar 
Shows or hides the status bar. 

Log...
Starts or stops logging.
Record...
Starts or stops recording of commands executed.
Mode Setting...
Sets the on-the-fly display, break and execution counter modes.
Rom Type...
Specifies the program ROM type which is installed in the ICE ROM socket.
Self Diagnosis
Displays the results of the diagnostic test in the ICE.

[Trace] menu  

[View] menu  

[Option] menu  

Summary of Contents for S5U1C62000A

Page 1: ...MF1121 03a CMOS 4 BIT SINGLE CHIP MICROCOMPUTER S1C60 62 Family Assembler Package S5U1C62000A Manual ...

Page 2: ...and there is no representation or warranty that anything made in accordance with this material will be free from any patent or copyright infringement of a third party This material or portions thereof may contain technology or the subject relating to strategic products under the control of the Foreign Exchange and Foreign Trade Law of Japan and may require an export license from the Ministry of In...

Page 3: ... fixed Specification Package D die form F QFP Model number Model name C microcomputer digital products Product classification S1 semiconductor Development tools S5U1 C 60R08 D1 1 Packing specifications 00 standard packing Version 1 Version 1 Tool type Hx ICE Ex EVA board Px Peripheral board Wx Flash ROM writer for the microcomputer Xx ROM writer peripheral board Cx C compiler package Ax Assembler ...

Page 4: ......

Page 5: ... 3 For coding See the necessary parts in Chapter 5 Chapter 5 describes the grammar for the assembler language as well as the assembler functions Also refer to the following manuals when coding S1C62xxx Technical Manual Covers device specifications and the operation and control method of the peripheral circuits S1C6200 6200A Core CPU Manual Has the instructions and details the functions and operati...

Page 6: ...he cursor pointer placed in the intended location is expressed as to click The clicking operation of the right mouse button is expressed as to right click To double click Operations of pressing the left mouse button twice in a row with the cursor pointer placed in the intended location are all expressed as to double click To drag The operation of clicking on a file icon with the left mouse button ...

Page 7: ...ding an Executable Object 12 3 2 6 Debugging 13 CHAPTER 4 WORK BENCH 14 4 1 Features 14 4 2 Starting Up and Terminating the Work Bench 14 4 3 Work Bench Windows 15 4 3 1 Window Configuration 15 4 3 2 Window Manipulation 16 4 4 Toolbar and Buttons 20 4 4 1 Standard Toolbar 20 4 4 2 Build Toolbar 21 4 4 3 Window Toolbar 21 4 4 4 Toolbar Manipulation 22 4 4 5 Insert into project Button on a Edit Wind...

Page 8: ...50 5 5 Grammar of Assembly Source 51 5 5 1 Statements 51 5 5 2 Instructions Mnemonics and Pseudo instructions 53 5 5 3 Labels 54 5 5 4 Comments 56 5 5 5 Blank Lines 56 5 5 6 Register Names 56 5 5 7 Numerical Notations 57 5 5 8 Symbols 58 5 5 9 Operators 58 5 5 10 Location Counter Symbol 60 5 6 Section Management 61 5 6 1 Definition of Sections 61 5 6 2 Absolute and Relocatable Sections 61 5 6 3 Sa...

Page 9: ...t Files 89 6 2 1 Input Files 89 6 2 2 Output Files 90 6 3 Starting Method 91 6 4 Messages 94 6 5 Linker Command File 95 6 6 Link Map File 96 6 7 Symbol File 97 6 8 Absolute List File 98 6 9 Cross Reference File 99 6 10 Linking 100 6 11 Automatic Insertion Removal Correction of pset Instruction 102 6 12 Error Warning Messages 103 6 12 1 Errors 103 6 12 2 Warning 103 6 13 Precautions 104 CHAPTER 7 H...

Page 10: ...ws 124 9 4 1 Basic Structure of Window 124 9 4 2 Command Window 126 9 4 3 Source Window 127 9 4 4 Data Window 129 9 4 5 Register Window 129 9 4 6 Trace Window 130 9 5 Tool Bar 131 9 5 1 Tool Bar Structure 131 9 5 2 Key Break Button 131 9 5 3 Load File and Load Option Buttons 131 9 5 4 Source Mix and Unassemble Buttons 131 9 5 5 Go Go to Cursor Go from Reset Step Next and Reset Buttons 131 9 5 6 Br...

Page 11: ...1 de data memory enter 163 df data memory fill 165 dm data memory move 166 9 9 5 Register Operation 167 rd register display 167 rs register set 168 9 9 6 Program Execution 169 g go 169 gr go after reset CPU 171 s step 172 n next 173 9 9 7 CPU Reset 174 rst reset CPU 174 9 9 8 Break 175 bp break point set 175 bpc break point clear 177 bd data break 178 bdc data break clear 180 br register break 181...

Page 12: ... 209 9 9 14 Coverage 210 cv coverage 210 cvc coverage clear 211 9 9 15 Command File 212 com execute command file 212 rec record commands to a file 213 9 9 16 log 214 log log 214 9 9 17 Map Information 215 ma map information 215 9 9 18 Mode Setting 216 otf on the fly display 216 tim time or step mode 217 9 9 19 Self Diagnosis 218 chk self diagnostic test 218 9 9 20 Quit 219 q quit 219 9 10 Error Wa...

Page 13: ...he relocatable assembler lets you develop a program which is made up of multiple sources This makes it possible to keep a common part independently and to use it as a part or a basis for the next program Source debugging A debugger can display an assembler source to show its execution status and allow debugging operations on it This makes debugging much easier to perform Common to all S1C62 chips ...

Page 14: ...x converter hx62 exe Converts an absolute object in IEEE 695 format output from the linker into ROM image data in Intel HEX format or Motorola S format This conversion is needed when making the ROM or when creat ing mask data using the development tools provided with each model Disassembler ds62 exe Disassembles an absolute object file in IEEE 695 format or a hex file in Intel HEX format and resto...

Page 15: ...e the optional In Circuit Emulator ICE the personal computer also requires a serial port with a D sub 9 pin Display A display unit capable of displaying 800 600 dots or more is necessary Hard disk and CD ROM drive Since the installation is done from a CD ROM to a hard disk a CD ROM drive and a hard disk drive are required Mouse A mouse is necessary to operate the tools System software The S1C62 Fa...

Page 16: ...activated 2 Insert the CD ROM into the CD ROM drive and display its contents 3 Start up the Setup exe by double clicking the icon Welcome 4 Click Next to continue installation Choose Destination Location A dialog box appears for specifying the installation directory 5 Click Next if the default directory C EPSON S1C62 is not changed to another directory To install the tools to another directory Ope...

Page 17: ...the installer Program Menu Installer registers the WorkBench62 icon to the program menu To discontinue installation The dialog boxes that appear during installation have a Cancel button To discontinue installation click Cancel when a dialog box appears To uninstall the tools Use Add Remove Programs in the control panel to uninstall the tools ...

Page 18: ...DLL OLE library for work bench SPAWNEX EXE Child task library for work bench doc English Manual folder English MANUAL_E PDF S5U1C62000A Manual DEV_MANUAL_E PDF S1C60 62 Family Development Tool Manual Japanese Manual folder Japanese MANUAL_J PDF S5U1C62000A Manual DEV_MANUAL_J PDF S1C60 62 Family Development Tool Manual dev62 bin WINFOG EXE Function option generator WINSOG EXE Segment option genera...

Page 19: ...file fileS DOC file SEG Segment option source file Melody Assembler mla62XX fileA HEX file par Melody HEX file fileA DOC file mel Melody data file Mask Data Checker mdc62XX file PAn Mask data file Function Option Generator fog62XX fileF HEX fileF DOC Function option document file Function option HEX file Segment option document file Melody document file file S Assembly source file s or file LSA fi...

Page 20: ...EVELOPMENT PROCEDURE 3 2 Development Using Work Bench This section shows a basic development procedure using the work bench wb62 Refer to Chapter 4 Work Bench for operation details 3 2 1 Starting Up the Work Bench Start up the work bench by choosing WorkBench62 from the program menu ...

Page 21: ...d select a directory then click OK The ICE parameter file box lists the parameter files that exist in the dev62 directory The work bench creates a folder directory with the specified project name as a work space and puts the project file epj into the folder The specified project name will also be used for the absolute object and other files 3 2 3 Editing Source Files The work bench has an editor f...

Page 22: ...Y ASSEMBLER PACKAGE CHAPTER 3 SOFTWARE DEVELOPMENT PROCEDURE 3 Enter source codes in the Edit window Edit window A new edit window appears 4 Save the source in a file by selecting Save from the File menu or clicking the Save button Save button ...

Page 23: ...s are listed in the project window Double clicking a listed source file name opens the edit window 3 2 4 Configuration of Tool Options The work bench supports all the start up options of each tool and they can be selected in a dialog box A make process for generating an executable object will be configured based on the settings In addition to option selection command files for the linker and debug...

Page 24: ...box Messages delivered from each executed tool are displayed in the Output window The work bench has a tag jump function that jumps to the source line in which an error has occurred by double clicking a source syntax error message that appears in the Output window It opens the corresponding source window if it is closed Output window Linked with the corresponding source line In the build task a ge...

Page 25: ... Build menu or click the Debug button Debug button The debugger starts up with the specified ICE parameter file and then loads the executable object file Note Make sure that the ICE is ready to debug before invoking the debugger Refer to the ICE hardware manual for settings and startup method of the ICE For the debugging functions and operations refer to Chapter 9 Debugger ...

Page 26: ...ll necessary files and information as a project General make process to invoke necessary tools and to update the least necessary files Supports all options of the assembler linker HEX converter disassembler and debugger Windows GUI interface for simple operation 4 2 Starting Up and Terminating the Work Bench To start up the work bench Choose WorkBench62 from the Program menu to start up the work b...

Page 27: ...lso be displayed in this win dow Two or more windows can be opened in the edit window area When an E0C62 assembly source file is opened the source is displayed with in colors according to the contents S1C62 instructions Black Preprocess pseudo instructions Dark brown Assemble pseudo instructions Blue Labels Light brown Comments Green Project window This window shows the currently opened work space...

Page 28: ...t also indicates the cursor position in the Edit window Key lock status Num lock Caps lock Scroll lock 4 3 2 Window Manipulation Resizing the windows Each window area can be resized by dragging the win dow boundary The size information is saved when the work bench is terminated So the same window layout will appearat the next time the work bench starts up Double click Floating and docking the Proj...

Page 29: ...When a project file is saved the Edit window information files opened size and location is also saved So the next time the project opens editing can begin in the saved condition Arrangement of the Edit windows The Edit windows being opened can be arranged similar to standard Windows applications 1 Cascade windows Select Cascade from the Window menu or click the Cascade Windows button Cascade Windo...

Page 30: ... 2 Tile windows To tile windows vertically select Tile Vertically from the Window menu or click the Tile Vertically button Tile Vertically button To tile windows horizontally select Tile Horizontally from the Window menu or click the Tile Horizontally button Tile Horizontally button ...

Page 31: ...range Icons from the Window menu 5 Moving and resizing an Edit window The Edit window allows changing of its location and its size in the same way as the standard Windows applications if it is not maximized Switching active Edit window Click the window to be activated if it can be viewed Otherwise select the window name source file name from the currently opened window list in the Window menu Scro...

Page 32: ... Edit window is opened Save All button Saves the documents of all Edit windows and the project information to the respective files Cut button Cuts the selected text in the Edit window to the clipboard Copy button Copies the selected text in the Edit window to the clipboard Paste button Pastes the text copied on the clipboard to the current cursor position in the Edit window or replaces the selecte...

Page 33: ...t in the dev62 directory are listed Output Format pull down list box Selects an executable object file format Three types of formats are available IEEE 695 absolute object format Intel HEX format and Motorola S format The build process will generate an executable object in the format selected here HEX Convert button Invokes the HEX converter to convert an absolute object into an Intel HEX object o...

Page 34: ...olbar location Toolbars can be moved to another location in the toolbar area by dragging them If a toolbar is moved out of the toolbar area it will be changed to a window 4 4 5 Insert into project Button on a Edit Window Insert into project button When a source file s ms or dat is opened the Insert into project button appears on the Edit win dow It can be used to insert the source file into the cu...

Page 35: ...t window to the file The file will be overwritten This menu item appears when an Edit window becomes active Save As Saves the document in the active Edit window with another file name A dialog box will appear allowing specification of a save location and a file name This menu item appears when an Edit window becomes active Save All Saves the documents of all Edit windows and the project informatio...

Page 36: ...g box will appear allowing specification of the word to be found and a search condition Replace Ctrl H Replaces the specified words in the active Edit window with one another A dialog box will appear allowing specification of the words Go To Ctrl G Jumps to the specified line or label in the active Edit window A dialog box will appear allowing specification of a line number or a label name 4 5 3 V...

Page 37: ...they are updated or not Stop Build Ctrl Break Stops the build process being executed This button become active only while a build process is being executed Debug F5 Invokes the debugger with the specified ICE parameter file Settings Alt F7 Displays a dialog box for selecting tool options ICE parameter file Displays a dialog box for selecting an ICE parameter file Output Format Displays a dialog bo...

Page 38: ... opened Edit window horizontally Tile Vertically Tiles the opened Edit window vertically Arrange Icons Arranges the minimized Edit window icons at the bottom of the Edit win dow area Close All Closes all the Edit windows opened 4 5 8 Help Menu About WB62 Displays a dialog box showing the version of the work bench The currently opened document file names are listed in this menu Selecting one activa...

Page 39: ... Select E0C Project File and click OK The Project dialog box appears 3 Enter a project name select an ICE parameter file and select a directory then click OK The ICE parameter file box lists the parameter files that exist in the dev62 directory The work bench creates a folder directory with the specified project name as a work space and puts the project file epj into the folder If a folder which h...

Page 40: ...Into project button then click Open 3 Insert into project button on the Edit window Insert into project button When the source file has been opened click the Insert into project button on the Edit window Do not forget to save the source to the file before inserting into the project 4 Dragging source files on the Project window Drag source files from Windows Explorer to the Project window These fil...

Page 41: ...open a project select Open WorkSpace from the File menu A dialog box appears allowing selection of a project file The work bench allows only one project to be opened at a time So if a project has been opened it will be closed when another project is opened At this time a dialog box appears to select whether the current project file is to be saved or not if it has not already been saved after a mod...

Page 42: ...he work bench generates this file so that the executable file according to the format selection is loaded when the debugger starts up file mak make file for build task This file is generated when a build task is started and is used for the build process in the work bench Example WorkBench62 Generated Friday May 01 1998 ASM as62 exe LINK lk62 exe HEX hx62 exe ASM_FLG g LINK_FLG g HEX_FLG e b ALL te...

Page 43: ...ng a New Source or Header File To create a new source file 1 Select New from the File menu or click the New button New button The New dialog box appears 2 Select E0C Assembly Source File and click OK An Edit window appears Enter source codes in this window The New dialog box allows selection of the E0C Header File Select it when creating a header file for constant definitions Edit window Enter sou...

Page 44: ...ading and Saving Files To load a source file 1 Select Open from the File menu or click the Open button Open button The Open dialog box appears 2 Choose a source file to be opened after selecting the file type s ms dat and click OK An Edit window opens and shows the contents of the source file ...

Page 45: ...ll menu item or the Save All button Save All button 4 7 3 Edit Function The source editor has general text editing functions similar to standard Windows applications Editing text Basic text editing function is the same as general Windows applications Cut copy and paste are supported in the Edit menu and with the toolbar buttons These commands are available only in the Edit window Undo can be selec...

Page 46: ...searching the specified word If the specified word is found the Edit window refreshes the display and highlights the word found Cancel button Clicking this button closes the dialog box Once a word to be found is specified in the Find dialog box the Find Next and Find Previous buttons on the toolbar can be used for a forward or backward search Find Next button Find Previous button Replace To replac...

Page 47: ...Go To from the Edit menu The Go To dialog box appears Going to a source line 1 Select Line in the Go to what list box 2 Type a line number in the Enter Line Number box and then click the Go To button Going to a label position 1 Select Label in the Go to what list box The Enter Line Number box changes to the Select Label list box 2 Select a label from the Select Label box and then click the Go To b...

Page 48: ... on the keyboard It contains the editing menu items descried above so you can select an edit command using this menu 4 7 4 Tag Jump Function When assembler syntax errors occur during assembling their error messages are displayed in the Out put window In this case you can go to the source line in which an error has occurred by double clicking the error message in the Output window However this func...

Page 49: ...on 4 9 4 8 2 Building an Executable Object To generate an executable object 1 Open the project file 2 Select an output format absolute Intel HEX or Motorola S using the Output Format list box 3 Select Build from the Build menu or click the Build button Build button The work bench generates a make file according to the source files in the project and the tool options set by the user This file is us...

Page 50: ...on Debug button The debugger starts up with the specified ICE parameter file and then loads the executable object by the command file generated from the work bench This command file contains the command to load the specified type of an executable object to the debugger The contents of the command file can be edited in the Settings dialog box explained in Section 4 9 When the building process is pe...

Page 51: ...e HEX converter options ICE Parameter file list box Select an ICE parameter file from the pull down list Output Format list box Select an output format from between Intel HEX and Motorola S Output error log file check box Select this option to generate the error log file of the HEX converter Do not fill room with 0xFF check box Select this option when not filling the unused program area with 0xFF ...

Page 52: ...haracter case option using the radio buttons When Default is selected the disassembled source will be made with all labels in upper case characters and instructions in lower case characters When Upper case is selected the source will be made with upper case characters only When Lower case is selected the source will be made with lower case characters only Start address box Specify the address used...

Page 53: ... setting information in the project and then closes the dialog box To continue to select other tool options click the Apply button This does not close the dialog box Clicking the Cancel button closes the dialog box 4 9 1 Assembler Options In this dialog the following four assembler options can be selected Error file Output of an error file No Not output Yes Output Debug info Addition of debugging ...

Page 54: ...define a name for conditional assembly double clicking the Defines part Source Error file Debug info List file Defines Default No Yes No Double click here then type a define name An text box appears Type a name in the box If two or more names are to be entered separate each name with a comma Refer to Chapter 5 Assembler for details of the assembler options 4 9 2 Linker Options In this dialog secti...

Page 55: ...if PSET insertions are not necessary Output Error log file check box Select this option to generate the error log file of the linker Disable Removal of branch optimization check box Select this option if PSET deletions are not necessary Add source debug information check box Select this option to add the debugging information If this option is not specified the sources cannot be displayed in debug...

Page 56: ...ect at start up Refer to Chapter 9 Debugger for details of the debugger options 4 9 4 HEX Converter Options Output Format list box An output format of the executable object to be generated by the build task can be selected When Absolute Object is selected the build task will be terminated after linking has completed The HEX converter will not be invoked When Intel Hex or Motorola S is selected the...

Page 57: ... Ctrl G Moves to the specified location Ctrl F7 Assembles the file F7 Builds the project Ctrl Break Stops the build F5 Debugs the project Alt F7 Edits the project build and debug settings Ctrl Tab Next MDI Window Short cut key Opens the popup menu Shift F10 Opens the popup menu 4 11 Error Messages The work bench error messages are given below Error message Description filename is changed by anothe...

Page 58: ...ted in the work bench is limited to 16M byte size 2 The label search and coloring function of the work bench does not support labels that have not ended with a colon 3 The work bench can create a make linker command and debugger command files note however that these files or settings created with another editor cannot be input into the work bench ...

Page 59: ...ge expands the additional function part described in the source file to mnemonics that can be assembled and delivers them to a temporary file preprocessed file The assembling stage as semble the preprocessed file to convert the source codes into the machine codes 5 2 Input Output Files Assembler as62 file s or file dat Assembly source file file o file ms file lst Object file Relocatable list file ...

Page 60: ...nd source codes are stored in plain text Preprocessed file File format Text file File name file name ms The file name is the same as that of the input file unless other wise specified with o option Output destination Current directory Description File in which instructions for preprocessing e g conditional assembly and macro instructions are expanded into an assembling format Also the source codes...

Page 61: ...ormation Explanation Creates an output file containing symbolic source debugging information Always specify this function when you perform symbolic source debugging Default If this option is not specified no debugging information will be added to the relocatable object file o file name Function Specification of output path file name Explanation Specifies an output path file name without extension ...

Page 62: ...process definition e Output error log file ERR g Add source debug information in object l Output relocatable list file LST o file name Specify output file name O or no extension File name Source file name DAT S or MS When error warning occurs If an error is produced an error message will appear before the end message shows up Example TEST S 5 Error Illegal syntax Assembly 1 erros s 0 warning s In ...

Page 63: ... is re garded as a relocatable section in a s source while in a dat source it is regarded as an absolute section and org 0 is placed at the beginning of the source by preprocessing This section explains the rules and grammar involved with the creation of assembly source files 5 5 1 Statements Each individual instruction or definition of an assembly source is called a statement The basic composi ti...

Page 64: ... 0x3 0xa 0xb 0xc 0xd Error The maximum describable number of characters in one line is 259 ASCII characters If this number is exceeded an error will result The usable characters are limited to ASCII characters alphanumeric symbols except for use in comments Also the usable symbols have certain limitations details below The reserved words such as mnemonics and pseudo instructions are all not case s...

Page 65: ...lz cp dec di ei fan halt inc jpba jp lbpx ld ldpx ldpy nop5 nop7 not or pop pset push rcf rdf ret retd rets rlc rrc rst rzf sbc scf scpx scpy sdf set slp sub szf xor For details on instructions refer to the S1C6200 6200A Core CPU Manual Note The assembler is commonly used for all the S1C62 Family models so all the instructions can be accepted Be aware that no error will occur in the assembler even...

Page 66: ...n identifier designed to refer to an arbitrary address in the program It is possible to refer to a branch destination of a program or a data memory address using a symbol defined as a label Definition of a label Usable labels are defined as 13 bit values by any of the following methods 1 Symbol Example LABEL1 LABEL1 is a label that indicates the address of a described location Preceding spaces and...

Page 67: ...fined in other source file call SYMBOL Label externally referenced to LABEL Local label Treated as a different label from LABEL of file1 The assembler regards those labels as those of undefined addresses in the assembling and includes that information in the object file it delivers Those addresses are finally determined by the processing of the linker When a label is defined by the comm pseudo ins...

Page 68: ...taining only a return line feed code It need not be made into a comment line using a semicolon 5 5 6 Register Names The CPU register names may be written in either uppercase or lowercase letters Table 5 5 6 1 Notations of register names Register memory location flag Notation A A register a or A B B register b or B XP Four high order bits of IX register xp or XP YP Four high order bits of IY regist...

Page 69: ...nge of immediate data varies with each instruction The specifiable ranges of different immediate data are given below Table 5 5 7 1 Types of immediate data and their specifiable ranges Symbol Type Decimal Hexadecimal Binary p 5 bit immediate data label 0 31 0x0 0x1f 0b0 0b11111 s 8 bit immediate data label 0 255 0x0 0xff 0b0 0b11111111 l 8 bit immediate data 0 255 0x0 0xff 0b0 0b11111111 i 4 bit i...

Page 70: ...begin with a numeral Uppercase and lowercase characters are discrimi nated 5 5 9 Operators An expression that consists of operators numbers and or defined symbols including labels can be used for specifying a number or defining a Define name only for number definition The preprocess in the assembler handles expressions in signed 16 bit data and expands them as hexadeci mal numbers Types of operato...

Page 71: ... the left 1 plus sign minus sign High priority 2 h l 3 4 5 addition subtraction 6 7 8 9 10 11 Low priority Examples define BLK_START 0x0 define BLK_SIZE 16 define BLK_END BLK_START BLK_SIZE 1 define INIT_DATA 0xaa LOOP ld a BLK_START h 4 0xf ld xh a ld b BLK_START l 0xf ld xl b ldpx mx INIT_DATA 0x80 0 2 INIT_DATA 4 0xf ldpx mx INIT_DATA 0x80 0 2 INIT_DATA 0xf cp a BLK_END 4 0xf JP NZ LOOP cp b BL...

Page 72: ...M2 0xfffe 1 2 1 1 0xffff Mask as 0xfffe 1 0x7fff Do not insert a space or a tab between an operator and a term 5 5 10 Location Counter Symbol The address of each instruction code is set in the 13 bit location counter when a statement is assembled It can be referred using a symbol as well as labels indicates the current location thus it can be used for relative branch operation The operators can be...

Page 73: ...s instruction to another section defining instruction will be regarded as 4 bit data and will be so processed as to be mapped in the data memory RAM Therefore nothing else can be described in this area other than the symbols for referring to the address of the data memory the area securing pseudo instructions comm and lcomm The comm pseudo instruction and the lcomm pseudo instruction are designed ...

Page 74: ...in one source Absolute sections are sections whose absolute addresses are specified with the org pseudo instructions BSS2 and CODE4 are absolute sections Absolute sections will be located at the place specified Other sections are relocatable in the sense that the absolute location addresses are not fixed at the assem bly stage and will be fixed later at the linking stage Precautions When there app...

Page 75: ...instruction Function Old instruction include Includes another source define Defines a constant string EQU macro endm Defines a macro MACRO ENDM ifdef else endif Defines an assemble condition ifndef else endif Defines an assemble condition align Sets alignment of a section org Sets an absolute address ORG page Sets a page number PAGE bank Sets a bank number BANK code Declares a CODE section mapping...

Page 76: ...as well be specified as the file name One or more spaces are necessary between the instruction and the File name Character case is ignored for both include itself and File name Sample descriptions include sample def include c E0C62 header common h Expansion rule The specified file is inserted in the location where include was described Precautions Only files created in text file format can be inse...

Page 77: ...g The usable characters are limited to a z A Z 0 9 and _ They must not contain any space or comma Values mnemonics labels register names and expressions using operators can also be specified Uppercase and lowercase characters are discriminated One or more spaces or tabs are necessary between the Define name and the substitute character string The substitute character string can be omitted In that ...

Page 78: ... MemX2 my Expanded to ldpx mx my When the same Define name is defined duplicatedly an error will result No other characters than delimiters space tab line feed and comma can be added before and after a Define name in the source However an operator can be added to a Define name string without delimiters Examples define L LABEL ld a L h 4 0b00001111 Replaced with ld a LABEL 7 4 ld b L l 0b00001111 R...

Page 79: ... or more spaces or tabs are necessary between the macro name and the first parameter symbol When describing multiple parameters a comma is necessary between one parameter and another The same symbols as for a macro name are available The number of parameters are limited according to the free memory space Statement string The following statements can be described Basic instruction mnemonic and oper...

Page 80: ...nly permits backward reference of a macro invocation Therefore the macro definition must precede the use of it Once a defined macro name is defined it cannot be canceled If the same macro name is defined duplicatedly a warning message will appear Until it is redefined it is expanded with the original content and once it is redefined it is expanded with the new content Definition should be done wit...

Page 81: ...e Statement string 2 is described Statement string 2 will be subjected to the assembling else Statement string 2 can be omitted Name Conforms to the restrictions on Define name See define Statement string All statements excluding conditional assembly instructions can be described Sample description ifdef TYPE1 ld x 0x12 else ld x 0x13 endif ifndef SMALL define SP1 0x31 endif Name definition Name d...

Page 82: ...g to the expansion rule of the other preprocessing pseudo instructions If no preprocessing pseudo instruction is contained the statement will be output in a file as is Precaution A name specified in the condition is evaluated with discrimination between uppercase and lowercase The condition is deemed to be satisfied only when there is the same Define name defined ...

Page 83: ...le locations of a source file for purpose of definition describing the code pseudo instruction in the respective start positions Sections are relocatable by default unless those locations are specified with the org page or bank pseudo instructions or more loosely with the align pseudo instruction bss pseudo instruction Instruction format bss Function Declares the start of a BSS section Statements ...

Page 84: ...description code org 0x0100 Function Specifies an absolute address location of a CODE or BSS section in an assembly source file The section with the org pseudo instruction is taken as an absolute section Precautions If an overlap occurs as the result of specifying absolute locations with the org pseudo instruction an error will result Examples bss org 0x00 comm RAM0 4 RAM secured area 0x00 0x03 or...

Page 85: ...100 This starts an absolute CODE section If the org pseudo instruction is defined immediately before a section definer code or bss it does not start a new section and makes no effect to the following sections Example code The latest relocatable section definition org 0x100 This does not start a new absolute section and makes no effect bss The another kind BSS of section which is not affected by th...

Page 86: ...page or bank appears Example code The latest relocatable section definition page 5 Starts new absolute CODE section from page 5 bss This section is relocatable not affected by the page pseudo instruction code This section is also relocatable not affected by the page pseudo instruction If the page pseudo instruction is defined immediately after a section definer code or bss the section definer does...

Page 87: ... location definer org align page or bank appears Example code The latest relocatable section definition bank 1 Starts new absolute CODE section from bank 1 bss This section is relocatable not affected by the bank pseudo instruction code This section is also relocatable not affected by the bank pseudo instruction If the bank pseudo instruction is defined immediately after a section definer code or ...

Page 88: ...tion until the next section definer code or bss or the next location definer org align page or bank appears Example code The latest relocatable section definition align 32 Starts new loosely absolute CODE section from the next 32 word boundary address bss This section is relocatable not affected by the align pseudo instruction code This section is also relocatable not affected by the align pseudo ...

Page 89: ...ction and the symbol Value Value specification Only decimal binary and hexadecimal numbers can be described The values that can grammatically be specified are from 0 to 65 535 0xffff One or more spaces tabs or a comma are necessary between the instruction and the value Sample description set DATA1 0x20 set DATA2 0xf2 Function Defines a symbol for a constant value Precaution When the defined symbol...

Page 90: ... binary and hexadecimal numbers can be described The data that can be specified are from 0 to 4096 0xfff One or more spaces or tabs are necessary between the instruction and the first data A comma is necessary between one data and another Sample description code codeword 0xa 0xa40 0xff3 Function Defines the 12 bit data to be written to the program ROM Precaution The codeword pseudo instruction can...

Page 91: ...ol and size Sample description comm RAM0 4 lcomm BUF 1 Function Sets an area of the specified size in the BSS section RAM and other data memory and creates a symbol indicating its top address with the specified name By using this symbol you can describe an instruction to access the RAM Difference between comm and lcomm The comm pseudo instruction and the lcomm pseudo instruction are exactly the sa...

Page 92: ...ther module One or more spaces or tabs are necessary between the instruction and the symbol Sample description global GENERAL_SUB1 Function Makes global declaration of a symbol The declaration made in a file with a symbol defined converts that symbol to a global symbol which can be referred to from other modules Prior to making refer ence declaration has to be made by this instruction on the side ...

Page 93: ...o Instructions stabs stabn Instruction formats 1 stabs File name FileName 2 stabn 0 FileEnd 3 stabn Line number LineInfo Function The assembler outputs object files in IEEE 695 format including source debugging information conforming to these instructions This debugging information is necessary to perform debugging by Debugger db62 with the assembly source displayed Format 1 delivers information o...

Page 94: ...olon placed at top of the line Example Before expansion macro LDM REG ADDR LD X ADDR LD REG MX endm LDM A 1 load memory to A reg After expansion no debugging information macro LDM REG ADDR LD X ADDR LD REG MX endm LD X 1 LDM A 1 load memory to A reg LD A MX 5 7 14 Priority of Pseudo Instructions Some remarks concerning the priority among the preprocessing pseudo instructions will be given below 1 ...

Page 95: ...tal number 0x the base is converted H Hexadecimal number 0x Arithmetic operators Old Meaning New Addition positive Subtraction negative Multiplication Division MOD Residue SHL Shift left SHR Shift right HIGH High order 8 bits h LOW Low order 8 bits l Logical operators Old Meaning New AND Logical and OR Logical or XOR Logical exclusive or NOT Logical negation Relation operators Old Meaning New EQ E...

Page 96: ... 15 0101 fe0 ld sph a 16 0102 e00 ld a SP_INIT_ADDR 0xf 17 0103 ff0 ld spl a 18 0104 400 call INIT_RAM_BLK1 initialize RAM block 1 19 LOOP 20 0105 400 call INC_RAM_BLK1 increment RAM block 1 21 0106 000 jp LOOP infinity loop 22 23 RAM block 24 bss 25 org 0x000 26 0000 00 comm RAM_BLK1 4 Content of line No The source line number from top of the file will be delivered Content of address In the case ...

Page 97: ...ent RAM block 1 jp LOOP infinity loop RAM block bss org 0x000 comm RAM_BLK1 4 Preprocessed file stabs C E0C62 test main s FileName main s test program main routine INITIAL SP ADDRESS DEFINITION define SP_INIT_ADDR 0x80 SP init addr 0x80 BOOT LOOP global INIT_RAM_BLK1 subroutine global INC_RAM_BLK1 subroutine org 0x100 stabn 13 LineInfo BOOT stabn 14 LineInfo ld a 0x80 4 set SP stabn 15 LineInfo ld...

Page 98: ...INIT_ADDR 4 set SP 15 0101 fe0 ld sph a 16 0102 e00 ld a SP_INIT_ADDR 0xf 17 0103 ff0 ld spl a 18 0104 400 call INIT_RAM_BLK1 initialize RAM block 1 19 LOOP 20 0105 400 call INC_RAM_BLK1 increment RAM block 1 21 0106 000 jp LOOP infinity loop 22 23 RAM block 24 bss 25 org 0x000 26 0000 00 comm RAM_BLK1 4 Error file Assembler 62 Ver x xx Error log file MAIN ERR Sun May 03 11 33 39 1998 Assembler 62...

Page 99: ...0 Illegal syntax The statement has a syntax error Macro parameter range macro parameter range The number of macro parameters has exceeded the limit exceeded CODE section address overlaps with CODE The address is duplicated section address Multiple statements on the same line Two or more statements were described in one line Nesting level limit nesting level limit exceeded Nesting of include has ex...

Page 100: ...sage Description Second definition of define symbol symbol The symbol is multiply defined by define Section activation expected use code bss There is no section definition Expression out of range The result of the expression is out of the effective range 5 12 Precautions 1 Nesting of the include pseudo instruction is limited to a maximum 10 levels If this limit is sur passed an error will result 2...

Page 101: ...e xrf file cm ICE parameter file file par file abs Absolute object file Cross reference file file als Absolute list file file map Link map file Symbol file Error file file err to Debugger from Assembler Fig 6 2 1 Flow chart 6 2 1 Input Files Relocatable object file File format Binary file in IEEE 695 format File name File name o A path can also be specified Description Object file of individual mo...

Page 102: ...n is specified Symbol file File format Text file File name File name sym Output destination Current directory Description Symbols defined in all the modules and their address information are delivered to this file This file is delivered when the s start up option is specified Cross reference file File format Text file File name File name xrf Output destination Current directory Description Labels ...

Page 103: ...is used as the output file name The ICE parameter file cannot be omitted A long file name supported in Windows and a path name can be specified When including spaces in the file name enclose the file name with double quotation marks Options The linker comes provided with the following options d Function Disable full PSET optimization Explanation Disables automatic insertion deletion correction of ...

Page 104: ... abs If no extension is specified abs will be supplemented at the end of the specified output path file name Default The 1st input file name is used for the output files m Function Output of link map file Explanation Outputs a link map file Default If this option is not specified no link map file will be output s Function Output of symbol file Explanation Outputs a symbol file Default If this opti...

Page 105: ...d file remain unaffected One or more spaces or tabs are necessary between rcode and file name The address should be described in hexadecimal format 0x Default If this option is not specified the CODE section of each module is mapped continuously from the address that was set by the code option Sample description rcode test1 o 0x0110 rbss file name address Function Set up of the file specific BSS s...

Page 106: ...sable all branch optimizations di Disable insertion of branch extension dr Disable removal of branch extension e Output error log file ERR g Add source debug information l Output absolute list file ALS m Output map file MAP o file name Specify output file name s Output symbol file SYM x Output cross reference file XRF code address Specify CODE start address bss address Specify BSS start address rc...

Page 107: ...a hyphen Each individual option needs to be delineated with more than one space tab or line feed For better visibility it is recommended to describe each option in a separate line Notes A numeric value to specify an address should be described in the hexadecimal format 0x Decimal and binary notations will not be accepted When an option that is only permitted in single setting is specified in a dup...

Page 108: ...8ff 0x0100 12 0x09 0x0900 0x09ff 0x0100 13 0x0a 0x0a00 0x0aff 0x0100 14 0x0b 0x0b00 0x0bff 0x0100 15 0x0c 0x0c00 0x0cff 0x0100 16 0x0d 0x0d00 0x0dff 0x0100 17 0x0e 0x0e00 0x0eff 0x0100 18 0x0f 0x0f00 0x0fff 0x0100 Total 0x19 occupied 0xfe7 blank BSS section map of TEST ABS Index Start End Size Type File SecNbr 1 0x000 0x003 0x004 Abs MAIN S 3 2 0x004 0xfff Total 0x4 occupied 0xffc blank Contents o...

Page 109: ...Linker 62 ver x xx Symbol file TEST SYM Sun May 03 14 16 16 1998 CODE section labels of TEST ABS Address Type File Symbol 0x0100 Local MAIN O BOOT 0x0206 Global SUB O INC_RAM_BLK1 0x0200 Global SUB O INIT_RAM_BLK1 0x0106 Local MAIN O LOOP BSS section labels of TEST ABS Address Type File Symbol 0x000 Global MAIN O RAM_BLK1 Contents of symbol file Symbol Indicates all the defined labels in in alphab...

Page 110: ...0 CL_AB 28 0107 e10 ld b 0 29 LOOP 30 0108 e42 pset 0x2 31 0109 406 call INC_RAM_BLK1 increment RAM block 1 32 010a 008 jp LOOP infinity loop Contents of absolute list file The format of each line of the absolute list file is as follows Line No Absolute address Code Source statement Line No Indicates the line number from the top of the file Address Indicates the absolute address after the instruct...

Page 111: ...l 0x0200 SUB O CODE 0x0202 SUB O CODE 0x0206 SUB O CODE 0x0208 SUB O CODE Label BOOT at 0x0100 MAIN O CODE Local Label LOOP at 0x0106 MAIN O CODE Local 0x0108 MAIN O CODE Label INIT_RAM_BLK1 at 0x0200 SUB O CODE Global 0x0105 MAIN O CODE Label INC_RAM_BLK1 at 0x0206 SUB O CODE Global 0x0107 MAIN O CODE Contents of cross reference file The format of each label information is as follows Label inform...

Page 112: ... option is specified the linker tries to arrange as much as possible a relocatable section in the same page as the section that has many branching relationships in order to decrease unnecessary pset instructions Restrictions on linking Note that all sections may not be mapped depending on each section size or address specifications even if the relocatable object size is within the available memory...

Page 113: ...e the start addresses of the relocatable CODE and BSS sections in test1 o have not been specified they are mapped from the relocatable section start addresses specified by the code and bss options First the linker will try to map CODE1 from address 0x0100 to address 0x010f If CODE2 is smaller than 0x100 words and CODE 1 is smaller than 0x10 words CODE1 can be mapped from address 0x0100 In this exa...

Page 114: ...he jp instruction or corrects the bank page number in the pset code if the pset code has a wrong operand Examples Original source After corrected disassembled code ld a b ld a b jp OTHER_PAGE pset XX Necessary pset XX instruction is inserted jp OTHER_PAGE pset YY jp SAME_PAGE jp SAME_PAGE pset YY is removed if unnecessary Even when pset YY is necessary YY is checked and corrected if wrong For call...

Page 115: ...n is duplicated with section type section address address No address specified with option option Address is not specified with the option No code to locate There is no valid code for mapping No ICE parameter file specified ICE parameter file is not specified No name and address specified with option option Name and address are not specified with the option No object file specified Object files to...

Page 116: ...inked depend on the free memory space 2 The dr option disabling pset deletion is provided to keep compatibility with the older assembler asm62XX It must be specified to create the same object as one that is created with the asm62XX 3 To load the absolute object file created by the linker to the debugger the same ICE parameter file must be specified when the debugger is invoked ...

Page 117: ...tion Absolute object file created by the linker ICE parameter file This file must always be specified File format Text file File name File name par A path can also be specified Description File to specify the memory mapping information of each S1C62 Family model This file is supplied in the development tools for each model and is commonly used with the linker debugger and disassembler 7 2 2 Output...

Page 118: ...he model is delivered to the output file Unused addresses are filled with 0xff e Function Output of error files Explanation Also delivers in a file the contents to be output by the hex converter through the Standard Output stdout such as error messages Default If this option is not specified no error file will be output m Function Conversion into Motorola S format Explanation Generates the hex fil...

Page 119: ...he following message concerning the usage Usage hx62 options file names Options b Do not fill room with 0xff e Output error log file HX62 ERR m Use Motorola S format O file name Output file name L H HEX L HSA or no extension File name Absolute object file ABS ICE parameter file PAR When error warning occurs If an error occurs an error message will appear before the end message shows up Example Err...

Page 120: ... mask data checker do not support Motorola S format files 7 5 2 Intel HEX Format The hex converter converts an absolute object file in the IEEE 695 format into the Intel HEX format files by default The high order data file is generated with a name file name h hex and the low order data file is generated with a name file name l hex The following shows a sample data in Intel HEX format 10000000FFFFF...

Page 121: ...placed data 36 bytes max The object codes are placed here This is not included in the end record sum 1 byte This is a checksum 1 s complement from length to the last data The end records are always S804000000FB Note When using hex files for creating the mask data do not specify Motorola S format because the the mask data checker does not support this format 7 5 4 Conversion Range By default the he...

Page 122: ... write file kind file FILE NAME Data cannot be written to the file Different processor types The ICE parameter file contains an illegal parameter setting Illegal file name FILE NAME The specified input file name is incorrect Illegal option option An illegal option is specified Illegal absolute object format The input file is not an object file in IEEE 695 format Out of memory Cannot secure memory ...

Page 123: ...e b and m options Otherwise an error will occur in the mask data checker Refer to the development Tool manual of each model for details of the mask data checker 2 The ICE and Evaluation Board support 4 types of ROMs 2764 27128 27256 and 27512 When making the program ROMs from the hex files generated by the hex data converter write data with an offset address as shown below Table 7 7 1 ROM offset a...

Page 124: ...x file File format Text file in Intel HEX format File name File name h hex and File name l hex Description HEX file created by the HEX converter Two hex files are needed one h hex contains the four high order bits of the object codes with 0b0000 extended and the other l hex contains the eight low order bits ICE parameter file This file must always be specified File format Text file File name File ...

Page 125: ... in lower case characters cu Function Use of upper case characters Explanation Creates all instructions and labels using lower case characters Default If neither this option nor the cl option is specified the source will be made with all labels in upper case characters and instructions in lower case characters e Function Output of error files Explanation Also delivers in a file the contents to be ...

Page 126: ...wing message concerning the usage Usage ds62 options file names Options cl Use lower case characters cu Use upper case characters e Output error log file DS62 ERR o file name Output file name MS or no extension s address Offset address default 0x0 File names Absolute object file ABS or L H HEX ICE parameter file PAR When error warning occurs If an error occurs an error message will appear before t...

Page 127: ...OT 14 0100 e08 ld a SP_INIT_ADDR 4 set SP 15 0101 fe0 ld sph a 16 0102 e00 ld a SP_INIT_ADDR 0xf 17 0103 ff0 ld spl a 18 0104 e42 pset 0x2 19 0105 400 call INIT_RAM_BLK1 initialize RAM block 1 20 LOOP 21 0106 e42 pset 0x2 22 0107 406 call INC_RAM_BLK1 increment RAM block 1 23 0108 006 jp LOOP infinity loop 24 sub s 25 test program subroutines 26 27 global RAM_BLK1 28 29 org 0x200 30 31 RAM block 1...

Page 128: ...0x0 ld xp a ld x 0x0 lbpx mx 0x0 lbpx mx 0x0 ret LABEL2 ld a 0x0 ld xp a ld x 0x0 ld a 0x0 scf acpx mx a acpx mx a acpx mx a adc mx a ret Output source file test ms when cl is specified Disassembler 62 Ver x xx Assembly source file TEST MS Mon May 04 11 50 20 1998 org 0x100 ld a 0x8 ld sph a ld a 0x0 ld spl a pset 0x2 call label1 label3 pset 0x2 call label2 jp label3 org 0x200 label1 ld a 0x0 ld x...

Page 129: ...ssembler 62 Ver x xx Assembly source file TEST MS Mon May 04 11 51 08 1998 ORG 0X100 LD A 0X8 LD SPH A LD A 0X0 LD SPL A PSET 0X2 CALL LABEL1 LABEL3 PSET 0X2 CALL LABEL2 JP LABEL3 ORG 0X200 LABEL1 LD A 0X0 LD XP A LD X 0X0 LBPX MX 0X0 LBPX MX 0X0 RET LABEL2 LD A 0X0 LD XP A LD X 0X0 LD A 0X0 SCF ACPX MX A ACPX MX A ACPX MX A ADC MX A RET ...

Page 130: ...e FILE NAME Data cannot be written to the file Illegal file name FILE NAME The specified input file name is incorrect Illegal HEX data format The input file is not an Intel HEX format file Illegal offset address offset address The specified address is invalid Illegal option option An illegal option is specified No ICE parameter file specified ICE parameter file is not specified Out of memory Canno...

Page 131: ...mmand execution function using a command file 9 2 Input Output Files Debugger db62 file abs file par file cmd IEEE 695 object file Parameter file file log Log file file cmd Record file file trc Trace file from Linker ICE filel hex fileh hex Program HEX files filea hex files hex filef hex Option HEX files Command file file s Source file s Fig 9 2 1 Flow chart 9 2 1 Input Files Parameter file File f...

Page 132: ...h microcomputer model and is read by the lo command These files are generated by a development tool available for each microcomputer model Command file File format Text file File name file name cmd An extension other than cmd can also be used Description This file contains a description of debug commands to be executed successively By writing a series of frequently used commands in this file the t...

Page 133: ...be used for this purpose varies among different personal computers Unless this option is specified the com1 port is used to communicate with the ICE b baud rate Function Specifies a communication transmission rate Explanation This option specifies the baud rate on the personal computer For baud rate select one from 1200 4800 9600 or 19200 Unless specified otherwise the baud rate is set to 19200 bp...

Page 134: ... Connecting COMx with xxxxx baud rate When terminated normally Connecting COMx with xxxxx baud rate done When an error is encountered Connecting COMx with xxxxx baud rate Error The Error indicates that communication between the personal computer and ICE is not functioning properly In this case verify the following A standard RS 232C cable is used The COM port is correct The baud rates on both side...

Page 135: ...opened are as follows Window Display contents Command window Initialization information and waits for command input Data window Data memory contents starting from data memory address 0 Register window Current register values Source window Unassemble display starting from program memory address 0x0100 Trace window Blank 9 3 5 Method of Termination To terminate the debugger select Exit from the File...

Page 136: ...r 9 4 1 Basic Structure of Window The diagram below shows the window structure of the debugger Depending on the computer used the windows may differ from the above display depending on the screen resolution the number of dots in system font etc Adjust the size of each window to suit needs Source window Trace window Register window Command window Data window ...

Page 137: ...Windows applications Each window can be moved to the desired display position by dragging the window s title bar with the mouse However windows can only be resized and moved within the range of the application window 3 Scrolling a window All windows can be scrolled The Register window can be scrolled only when its size is reduced Use one of the following three methods to scroll a window 1 Click on...

Page 138: ...ected from menus or tool bar When a command is executed by selecting the menu item or tool bar button the executed command line is displayed in the Command window 3 Displaying command execution results The Command window displays command execution results However some command execution results are displayed in the Source Data Register or Trace windows The contents of these execution results are di...

Page 139: ...e button Unassemble button All program code in the 8K address space can be referenced by scrolling the window When a break occurs the display content is updated so that the address line to be executed next is displayed with the entire line highlighted for identification Use the scroll bar or arrow keys to scroll the window Or enter a command to display the program code beginning with a specified p...

Page 140: ...reakpoint is to be set not available for a source only line Break button Go to Cursor button Then click on the Break button A PC breakpoint will be set at that address If the same is done at the address line where a PC breakpoint has been set the breakpoint will be cleared If the Go to Cursor button is clicked the program will execute beginning with the current PC position and program execution br...

Page 141: ...a f Data in the address will be modified with the entered number and the cursor will move to the next address This allows successive modification of a series of addresses 9 4 5 Register Window 1 Displaying register contents and fetched code The Register window displays the contents of the program counter PC A register B register X register Y register stack pointer SP and flags I D Z and C The curr...

Page 142: ...isassembled contents Register contents PC A B X Y and flags Memory access status R W address data This window also displays the trace data search results by the ts command Updating of display The contents of the Trace window are cleared when the target program is executed During this period the Trace window does not accept scrolling and resizing operations To display the latest contents of this wi...

Page 143: ...e mode The Source window opens if it is closed This button performs the same function when the sc command is executed Unassemble button This button switches the display of the Source window to the unassemble mode The Source window opens if it is closed This button performs the same function when the u command is executed Mix button This button switches the display of the Source window to the mix m...

Page 144: ...s call or calz it is assumed that a program section until control returns to the next address constitutes one step and all steps of their subroutines are executed This button performs the same function when the n command is executed Reset button This button resets the CPU It performs the same function when the rst command is executed 9 5 6 Break Button Use this button to set and clear a breakpoint...

Page 145: ...nd is executed Before this menu item can be selected the Source window must be open and the address line where the program is to break must be clicked Selecting a break address by clicking on the address line is valid for only the lines that have actual code and is invalid for the source only lines Go from Reset This menu item resets the CPU and then executes the target program from the program st...

Page 146: ...address ranges for tracing executed cycles using a dialog box It performs the same function as executing the ta or tac command Trace Condition This menu item sets a trace condition Start Middle End using a dialog box It performs the same function as executing the tc command Trace Search This menu item searches trace information from the trace memory under the condition specified using a dialog box...

Page 147: ...unction as executing the rec command Mode Setting This menu item sets the on the fly display break and execution counter modes using a dialog box It performs the same functions as executing the otf be bsyn and tim command Rom Type This menu item specifies the program ROM type which is installed in the ICE ROM socket It performs the same function as executing the rom command Self Diagnosis This men...

Page 148: ... input When you press the Enter key after entering a command the system executes that command If the command entered is accompanied by guidance the command is executed when the necessary data is input according to the displayed guidance Input example g Only a command is input com test cmd A command and parameter are input Command input accompanied by guidance For commands that cannot be executed u...

Page 149: ...meric data format of parameter For numeric values to be accepted as a parameter they must be input in hexadecimal numbers for almost all commands However some parameters accept decimal or binary numbers The following characters are valid for specifying numeric data Hexadecimal 0 9 a f A F Decimal 0 9 Binary 0 1 is used to mask bits when specifying a data pattern Specification with a symbol For add...

Page 150: ...ep n Step over Run Next com Load and execute command file Run Command File rst Reset CPU Run Reset CPU bp bpc Set clear PC breakpoint Break Breakpoint Set bd bdc Set clear data break Break Data Break br brc Set clear register break Break Register Break bm bmc Set clear multiple break Break Multiple Break bac Clear all break conditions Break Break All Clear ta tac Set clear trace area Trace Trace A...

Page 151: ... executing a command file There are two methods to read a command file into the debugger and to execute it as described below 1 Execution by the start up option By specifying a command file in the debugger start up command one command file can be executed when the debugger starts up If the above example of a command file is specified for example the necessary files are read into the debugger immed...

Page 152: ...in the Command window during log mode differ from those appearing in normal mode 1 When executing a command when each window is open When the window that displays the command execution result is opened Normal mode The contents of the relevant display window are updated The execution results are not displayed in the Command window Log mode The same contents as those displayed in the relevant window...

Page 153: ...X convertor lo File Load Option Program 8 low order bits l hex HEX convertor Function option f hex Function option generator Segment option s hex Segment option generator Melody data a hex Melody assembler Ext Extension Com Command Loading ROM data The debugger can load a program from the program ROMs installed in the ICE The following three commands are provided for handling ROM data Table 9 8 1 ...

Page 154: ... from among the three modes Unassemble mode Source mode Mix mode Table 9 8 2 1 Commands tool bar buttons to switch display mode Display mode Command Menu Button Unassemble u View Program Unassemble Source sc View Program Source Display Mix m View Program Mix Mode 1 Unassemble mode In this mode the debugger displays the program codes after unassembling into mnemonics 2 Source mode In this mode the ...

Page 155: ...ring a command having address in its parameter from the Command window or a dialog box 1 Referencing global symbols Follow the method below to specify a symbol that is declared to be a global symbol label by the global or comm pseudo instruction symbol Example of specification m BOOT de RAM_BLK1 2 Referencing local symbols Follow the method below to specify a local symbol label that is used in onl...

Page 156: ... specified area An entire specified area is rewritten with specified code 4 Copying specified area The content of a specified area is copied to another area Operating on data memory area The following operations can be performed on the data memory areas RAM display memory I O memory Table 9 8 3 2 Commands menu item to operate on data memory Function Command Menu Dumping data memory dd View Data Du...

Page 157: ... View Register Modifying register values rs 1 Displaying registers Register contents can be displayed in the Register or Command window Registers PC A B X Y SP and IDZC flags While the program is being executed the PC address is updated in real time every 0 5 seconds by the on the fly function 2 Modifying register values The contents of the above registers can be set to any desired value The regis...

Page 158: ...owing causes Break conditions set by a break set up command are met The Key Break button is clicked or the Esc key is pressed The Break or Reset switch on the ICE is pushed Key Break button When the program does not stop use this button to forcibly stop it 3 On the fly function The ICE and debugger provide the on the fly function to display the PC address every 0 5 seconds during successive execut...

Page 159: ...ey only In the following cases single stepping is terminated before a specified number of steps is executed The Key Break button is clicked or the Esc key is pressed The Break or Reset switch on the ICE is pushed Single stepping is not suspended by breaks set by the user such as a PC break or data break Key Break button When the program does not stop use this button to forcibly stop it 2 Display d...

Page 160: ... desired after moving the cursor to that position and then click on the Break button A mark will be placed at the beginning of the line indicating that a breakpoint has been set there and the address is registered in the breakpoint list Clicking on the line that begins with a and then the Break button cancels the breakpoint you have set in which case the address is deleted from the breakpoint list...

Page 161: ...ultiple Break Forced break by the Key Break button or the Esc key The Key Break button or the Esc key can be used to forcibly terminate the program under execu tion when the program has fallen into an endless loop or cannot exit a standby HALT or SLEEP state Key Break button Forced break by the Break or Reset switch on the ICE The Break or Reset switch can also be used to forcibly terminate the pr...

Page 162: ...the trace information that is taken into the trace memory in every cycle This list is corresponded to display in the Trace window Loc Trace cycle number decimal The last information taken into the trace memory becomes 0000 CODE Fetched code hexadecimal and unassembled content mnemonic PC PC address hexadecimal A B X Y Values of A B X Y registers hexadecimal IDZC Values of I D Z and C flags binary ...

Page 163: ...ormation of 4 096 cycles before and after the break point are sampled into the trace memory Execution started Break point Trace sampling range 4 096 cycles 4 096 cycles Fig 9 8 6 2 Trace range when middle is selected End default The trace is halted after sampling trace information at the first hit break point In this case the trace information at the break point is the latest information stored in...

Page 164: ... searching When the trace information that matches the specified condition is found the system displays the found data in the Trace window or in the Command window if the Trace window is closed Table 9 8 6 3 Command menu item to search trace information Function Command Menu Search trace information ts Trace Trace Search Saving trace information After the trace information is displayed in the Trac...

Page 165: ...sses at which a program is executed and it can be displayed in the Command window Because the executed address range is displayed as shown below it is possible to know which areas have not been executed Coverage Information 0 0100 0108 1 0200 020f Table 9 8 7 1 Coverage commands Function Command Display coverage information cv Clear coverage information cvc ...

Page 166: ...itions 187 bac break all clear Clear all break conditions 188 be break enable Set break enable mode 189 bsyn break disable Set break disable synchronous mode 190 Program display u unassemble Unassemble display 191 sc source code Source display 192 m mix Mix display 193 Symbol information sy symbol list List symbols 194 Load files lf load file Load IEEE 695 format absolute object file 195 lo load o...

Page 167: ...cution of the command Note Shows notes on using GUI utility Indicates a menu item or tool bar button if they are available for the command Notes In the command format description the parameters enclosed by indicate they are necessary parameters that must be input by the user while the ones enclosed by indicate they are optional parameters The input commands are case insensitive you can use either ...

Page 168: ...2 e00 LD A 0x0 q Command is terminated Source file name should be entered when a symbol label is used as the operand Specify the source file name in which the symbol was defined 0100 e0f LD A 0xf JP LOOP Symbol is used Source file name enter to ignore main s Source file name is input Notes The start address you specified must be within the range of the program memory area available with each micro...

Page 169: ... of the Source window are updated immediately When it is done in guidance mode the unassemble contents of the Source window are updated immediately in unassemble display mode but will be updated when the q is input to terminate the command in mix display mode Although the contents of the unassemble display are modified by rewriting code those of source display remain unchanged GUI utility None ...

Page 170: ...xceeded Error Program address out of range Code must be input using a hexadecimal number in the range of 12bits 0 to 0xfff An error results if the input one is not a hexadecimal number Error invalid value An error results if the input code exceeds the limit or it is invalidated by the DEL command in the PAR file Error illegal code In guidance mode the following keyboard inputs have special meaning...

Page 171: ...to address 0x2ff with 0xffb Format 2 pf Start address 200 Start address is input End address 2ff End address is input Fill code fff Code is input Command execution can be canceled by entering only the Enter key and nothing else Notes The addresses specified here must be within the range of the program memory area available with each microcomputer model An error results if the input one is not a he...

Page 172: ... Source area start address is input End address 2ff Source area end address is input Destination address 280 Destination area start address is input Command execution can be canceled by entering only the Enter key and nothing else Notes The addresses you specified must be within the range of the program memory area available with each microcomputer model An error results if the input one is not a ...

Page 173: ...yed beginning with the top of that line For example even though you may have specified address 0x118 for address1 data is displayed beginning with address 0x110 However if an address near the uppermost part of data memory e g maximum address is 0xfff such as 0xff5 is specified as address1 the last line displayed in the window in this case is 0xff0 the specified address is not at the top of the win...

Page 174: ... if the Data window is opened and are also output to the log file Notes Both the start and end addresses specified here must be within the range of the data memory area available with each microcomputer model An error results if the input one is not a hexadecimal number or not a valid symbol Error invalid value An error results if the limit is exceeded Error Data address out of range An error resu...

Page 175: ... memory area available with each microcomputer model An error results if the input one is not a hexadecimal number or a valid symbol Error invalid value An error results if the limit is exceeded Error Data address out of range The contents of the read only area cannot be rewritten A warning message will be displayed if you specify such an address Warning read only address can t write In guidance m...

Page 176: ...sh inputting and start execution Return to previous address Input is skipped keep current value If the maximum address of data memory is reached and gets a valid input other than the command is terminated GUI utility Data window The Data window allows direct modification of data Click the Data window and select the dis played data to be modified then enter a hexadecimal number ...

Page 177: ...execution can be canceled by entering only the Enter key and nothing else Notes Both the start and end addresses specified here must be within the range of the data memory area available with each microcomputer model An error results if the input one is not a hexadecimal number or a valid symbol Error invalid value An error results if the limit is exceeded Error Data address out of range An error ...

Page 178: ...nation area start address is input Command execution can be canceled by entering only the Enter key and nothing else Notes All the addresses specified here must be within the range of the data memory area available with each microcomputer model An error results if the input one is not a hexadecimal number or a valid symbol Error invalid value An error results if the limit is exceeded Error Data ad...

Page 179: ... Register window is opened When the Register window is opened all the above contents are displayed in the Register window according to the program execution When you use the rd command the displayed contents of the Register window is updated 3 When Register window is closed Data is displayed in the Command window in the following manner rd PC 0206 A 0 B f SP 7d X 003 Y 0ff IDZC 0010 Current Code e...

Page 180: ...f 0 X 3 000 Y ff 100 FI 0 FD 0 1 FZ 1 0 FC 0 SP 7d 7f After you execute the command the Register window is updated to show the contents you have input If you input q to stop entering in the middle the contents input up to that time are updated Notes An error results if you input a value exceeding the register s bit width Error invalid value An error results if you input a register name other than ...

Page 181: ...losed the PC content is displayed in the Command window The on the fly function can be turned off by the otf command In this case the Register window is updated after a break The execution time or execution steps set by the tim command are displayed in the Command window after a break The Source window is updated after a break in such a way that the break address is displayed within the window If ...

Page 182: ... without temporary break is executed Go button Run Go to Cursor menu item Go to Cursor button When this menu item or button is selected after placing the cursor to the temporary break address line in the Source window the g command with a temporary break is executed The program execution will be suspended after executing the address at the cursor position Go to Cursor button ...

Page 183: ...t input mode Operation This command resets the CPU before executing the program This causes the PC to be set at address 0x100 from which the command starts executing the program Once the program starts executing the command operates in the same way as the g command GUI utility Run Go from Reset menu item Go from Reset button When this menu item or button is selected the gr command is executed Go f...

Page 184: ... or the Esc key is pressed The break or reset switch on the ICE is pushed After each step is completed the register contents in the Register window are updated If the Register window is closed the register contents are displayed in the Command window same as executing the rd command Notes The step count must be specified within the range of 0 to 65 535 An error results if the limit is ex ceeded Er...

Page 185: ... without step count PC when n is executed call _test1 ld a 0 PC after n is completed ld b 0 Example when 2 call instructions are executed by the n command without step count PC when n is executed call _test1 call _test2 ld a 0 ld b 0 PC after n is completed _test2 ld a 1 Notes The step count must be specified within the range of 0 to 65 535 An error results if the limit is ex ceeded Error Number o...

Page 186: ...fined Y Undefined I 0 D Undefined S1C6200 or 0 S1C6200A Z Undefined C Undefined SP Undefined If the Source window is opened the window is redisplayed beginning with address 0x0100 If the Register window is opened the window is redisplayed with the above contents The debug status such as memory contents and break conditions is not reset GUI utility Run Reset CPU menu item Reset button When this men...

Page 187: ...eak area Set new PC break Terminated by Enter key bp Clear 0 0100 1 0200 0300 1 set 2 clear 3 clear all 2 2 clear is selected Clear PC break 150 250 Break area 0x150 0x200 0x250 is cleared Clear PC break Terminated by Enter key bp Clear all 0 0100 1 0251 0300 1 set 2 clear 3 clear all 3 3 clear all is selected bp PC break None 1 set 2 clear 3 clear all Terminated by Enter key Notes All PC breaks a...

Page 188: ... appears for setting PC breakpoints To set a breakpoint select a Set button and enter an address in the text box corresponding to the selected button When setting more than four breakpoints click the Next button to continue settings The Previous and Next buttons are used to view previous and subsequent four breakpoints To clear a breakpoint select the Clear button of the address to be cleared The ...

Page 189: ...t 2 clear 3 clear all Notes The format of parameters is same as the bp command You can also use the guidance input mode of bp command to do the same operation You can use this command for multiple times to clear breakpoints If the specified addresses or areas have not been set as PC breakpoints no clear operation is done GUI utility Break Breakpoint Set menu item When this menu item is selected a ...

Page 190: ... address The specified address hexadecimal or symbol IEEE 695 format only data Data pattern hexadecimal or binary with B suffix can be input for the bits to be masked option Memory read write option r w or Condition 0 address last data memory address 0 data 0xf Examples Format 1 bd 0020 5 W Sets a data break condition so that the program breaks when 5 is written to address 0x20 The direct input mo...

Page 191: ...exceeded Error Data address out of range The data value can be input as a binary number with or without mask bits or a hexadecimal number in the range of 4 bits 0 to 0xf An error results if the limit is exceeded Error invalid data pattern To input a binary value a suffix B must be used When specifying a binary number without mask bits all four bits should be input otherwise the value is treated as...

Page 192: ...GGER bdc data break clear Function This command clears the data break condition that has been set Format bdc direct input mode GUI utility Break Data Break menu item When this menu item is selected a dialog box appears for clearing the set data break condition See the bd command ...

Page 193: ...e B Old value value FI Old value value FD Old value value FZ Old value value FC Old value value X Old value value Y Old value value register Register name A B F X or Y value Data pattern for the register hexadecimal or binary with B suffix can be used for the bits to be masked Examples Format 1 br F 1B Sets a register break condition so that the program breaks when the C flag is set Format 2 br Re...

Page 194: ... use the direct input mode to set register break condition at a time or change one or several items for register break setting The register value can be input as a binary number with or without mask bits or a hexadecimal number in the range of the bit width of each register refer to the notes for bd command An error results if the limit is exceeded Error invalid data pattern GUI utility Break Regi...

Page 195: ... register break clear Function This command clears the register break conditions that have been set Format brc direct input mode GUI utility Break Register Break menu item When this menu item is selected a dialog box appears for clearing the register break conditions See the br command ...

Page 196: ...ld value value Y Old value value item PC ADDR DATA OPT A B F X Y ADDR DATA and OPT are for data RAM access please refer to bd command value Value set for each item hexadecimal or binary with B suffix can be used for the bits to be masked Examples Format 1 bm PC 150 ADDR 20 DATA 0 OPT W Sets a PC and a data memory conditions In this case a break will occur when the program writes 0 to data memory a...

Page 197: ...ion at a time or change one or several items for multiple break setting In guidance mode the following keyboard inputs have special meaning q Command is terminated finish inputting and start execution Return to previous address Input is skipped keep current value When the command is terminated in the middle of guidance by q the contents that have been input up to that time will be modified However...

Page 198: ...ER bmc multiple break clear Function This command clears the multiple break condition that has been set Format bmc direct input mode GUI utility Break Multi Break menu item When this menu item is selected a dialog box appears for clearing multi break conditions See the bm command ...

Page 199: ...GER bl break point list Function This command lists the current setting of all break conditions Format bl direct input mode Example bl Data Break Condition ADDR 100 DATA 1 1 B R W Register Break Condition A A B X 060 Y IDZC 1 0 B PC Break List 0 0100 1 0200 0300 GUI utility None ...

Page 200: ...E CHAPTER 9 DEBUGGER bac break all clear Function This command clears all break conditions set by the bp bd br and or bm commands Format bac direct input mode GUI utility Break Break All Clear menu item When this menu item is selected the bac command is executed ...

Page 201: ...break is generated when the PC break data break register break or multi break condition is met with the Evaluation Board CPU state Format be direct input mode Example be Set to break enable mode GUI utility Option Mode Setting menu item When this menu item is selected a dialog box appears for setting break enable mode Select the Break Enable button ...

Page 202: ...multi break condition is met with the Evaluation Board CPU state a pulse is output to the ICE SYNC pin However a break is not generated Format bsyn direct input mode Example bsyn Set to break disable synchronous mode GUI utility Option Mode Setting menu item When this menu item is selected a dialog box appears for setting break disable mode Select the Break Disable button in the dialog box See the...

Page 203: ...bol IEEE 695 format only Condition 0 address last program memory address Display When the Source window is opened the display is refreshed When the Source window is closed the window automatically opens in the unassemble mode If address is not specified the program is displayed from the current PC address by default if address is specified it is displayed from the specified address GUI utility Vie...

Page 204: ...y When the Source window is opened the display is refreshed When the Source window is closed the window automatically opens in the source mode If address is not specified the program is displayed from the current PC address by default if address is specified it is displayed from the specified address Note Source codes can be displayed only when an absolute object file that contains source debug in...

Page 205: ...ition 0 address last program memory address Display When the Source window is opened the display is refreshed When the Source window is closed the window automatically opens in the mix mode If address is not specified the program is displayed from the current PC address by default if address is specified it is displayed from the specified address Note Source codes can be displayed only when an abs...

Page 206: ...ocal symbols Shown to right to each symbol is the address that is defined in it Format 2 sy R INC_RAM_BLK1 206 INIT_RAM_BLK1 200 RAM_BLK1 0 In format 2 the debugger displays global symbols that contain the character string specified by keyword Format 3 sy B BOOT C E0C62 TEST MAIN S 100 In format 3 the debugger displays local symbols that contain the character string specified by keyword When local...

Page 207: ...r different chip type can t load this file Only an IEEE 695 format object file generated by the linker can be loaded by the lf command If you want to use source display and symbols when debugging a program the object file must be in IEEE 695 format that contains debug information loaded into the computer If the Source window is opened when loading a file its contents are updated The program conten...

Page 208: ... path can also be specified Examples Format 1 lo testl hex Loads the program files testl hex and testh hex Loading file OK Format 2 lo File name tests hex Loads a segment option file Loading file OK Notes The debugger determines the file type based on the specified file name Therefore the debugger cannot load a file not following to the name specification listed above and an error will result Erro...

Page 209: ... from the ROM at the ICE ROM socket Format rp direct input mode Notes An error results if high and or low ROM chips are not installed and so the program is not loaded to the emulation memory Error no low ROM Error no high ROM Error no high and low ROM An error results when an undefined code is detected and the execution is terminated Error undefined code detected GUI utility None ...

Page 210: ...rror no high and low ROM If there is any non agreeing data it ROM address ROM contents emulation memory contents is displayed in the Command window vp Rom verifying NG Rom verify Errors FFF FFC 0300 0FF 0FC This command just verifies the contents of the ICE emulation memory and the ROM so no error results if an undefined code exists either in the emulation memory or the ROM It is checked when load...

Page 211: ...ype type Value indicating the ROM type 64 128 256 512 Examples Format 1 rom 64 2764 type ROM is specified Format 2 rom ROM 64 256 27256 type ROM is specified Notes The initial value is set as 64 An error results if you input a value other than the valid ones listed above Error Incorrect ROM type 64 128 256 512 GUI utility Option ROM Type menu item When this menu item is selected a dialog box appea...

Page 212: ...ract the trace information up to the break point Format 1 tc condition direct input mode 2 tc guidance mode Current type setting Set condition 1 start 2 middle 3 end 1 2 3 condition Position for trace extraction with respect to the break point s m e Examples Format 1 tc s Start is specified Format 2 tc Trace condition End 1 start 2 middle 3 end 2 Note An error results if you input the condition ot...

Page 213: ...95 format only Condition 0 staddr 1 4 endaddr 1 4 last program memory address Examples Format 1 ta 400 600 Sets a trace area from address 0x400 to 0x600 Format 2 ta all Sets as entire program memory to be traced Format 3 ta Trace area 0000 0fff 1 set 2 clear 3 clear all 3 Clears all areas ta No trace extract address is defined 1 set 2 clear 3 clear all 1 Start address 100 Sets a trace area from ad...

Page 214: ... specify more than 4 address ranges at a time But for guidance mode there is no such limitation so you can specify more than 4 address ranges before terminating the command by the Enter key If you set an address range to trace area this address range will be added to current trace area So if you want to set trace area from nothing you should at first clear current trace area You can use this comma...

Page 215: ...ace area from 0x400 to 0x600 ta Trace area 0000 03ff 0601 0fff 1 set 2 clear 3 clear all Notes The addresses must be specified within the range of the program memory area available for each microcomputer model An error results if the input one is not a hexadecimal number or a valid symbol Error invalid value An error results if the limit is exceeded Error Program address out of range An error resu...

Page 216: ...race pointer Function This command displays the current location of the trace pointer The pointer points to the location in the trace memory into which the last trace information has been stored Format tp direct input mode Example tp LOC 2058 Current trace pointer value GUI utility None ...

Page 217: ...hed code hexadecimal and unassembled content mnemonic PC PC address hexadecimal A B X Y Values of A B X Y registers hexadecimal IDZC Values of I D Z and C flags binary after cycle execution MemOP Read write operation denoted by R or W at the beginning of data accessed data memory address hexadecimal and data hexadecimal OtherOP Interrupt process INT1 stack INT2 vector fetch 1 When Trace window is ...

Page 218: ... 1 W07E 0 W07D 8 0014 e00 LD A 0x0 0206 0 0 004 100 0100 0015 e80 LD XP A 0207 0 0 004 100 0100 0016 b00 LD X 0x0 0208 0 0 000 100 0100 0017 e00 LD A 0x0 0209 0 0 000 100 0100 0018 f41 SCF 020a 0 0 000 100 0101 0019 f28 ACPX MX A 020b 0 0 000 100 0100 R000 0 W000 1 0020 f28 ACPX MX A 020c 0 0 001 100 0110 R001 0 W001 0 Notes Trace memory has a capacity of 8 192 cycles On the other hand the S1C6200...

Page 219: ...s Format 1 ts option address direct input mode 2 ts guidance mode 1 Pc address 2 Data read address 3 Data write address 1 2 3 Search address address Search result is displayed option Condition type program address data read address or data write address pc dr dw address Search address hexadecimal or symbol IEEE 695 format only Display The search results are displayed in the Trace window if it is o...

Page 220: ...cimal number or not a valid symbol Error invalid value An error results if the limit is exceeded for program memory address Error Program address out of range An error results if the limit is exceeded for data memory address Error Data address out of range GUI utility Trace Trace Search menu item When this menu item is selected a dialog appears for setting a search condition Select a option using ...

Page 221: ...n extracted by the td command Tracing into file OK Format 2 tf Start point 0 End point The oldest data is specified by the Enter key File name test trc Tracing into file OK Notes If an existing file is specified the file is overwritten with the new data The default value of num1 is 0 the default value of num2 is the last location GUI utility Trace Trace File menu item When this menu item is select...

Page 222: ...thin the range from 0x100 to 0x1ff Coverage Information 0 0100 0108 Notes The addresses specified here must be within the range of the program memory area available with each microcomputer model An error results if the input one is not a hexadecimal number or a valid symbol Error invalid value An error results if the limit is exceeded Error Program address out of range If the cv command is input w...

Page 223: ...S5U1C62000A MANUAL EPSON 211 S1C60 62 FAMILY ASSEMBLER PACKAGE CHAPTER 9 DEBUGGER cvc coverage clear Function This command clears the coverage information Format cvc direct input mode GUI utility None ...

Page 224: ...conds 2 2 sec of interval is inserted after each command execution Notes Any contents other than commands cannot be written in the command file An error results if the file you specified does not exist Error can t open file Another command file can be read from a command file However the nesting of command files is limited to a maximum of 5 levels An error results if a com command at the sixth lev...

Page 225: ... window or set breakpoints in the Source window by double clicking the mouse the corresponding commands are also displayed in the Command window and output to the specified file At the first time you should specify the file name to which all debug commands following the rec command will be output Once an output command file is open the recording is suspended and resumed toggled every time you inpu...

Page 226: ... the corresponding commands and the execution results are also displayed in the Command window and output to the specified file The displayed contents of the Data Trace or Register window produced by command execution are displayed in the Command window as well The on the fly information is also displayed However the updated contents of each window after some execution as well as the contents of e...

Page 227: ...input mode Example ma Map Information Rom Size 1000 Rom Start Address 0000 Rom End Address 0fff Ram Size 1000 Ram Start Address 0000 Ram End Address 0fff I O Area List 0080 00ff 0180 01ff 0280 02ff Segment Area List 0050 007f 0450 047f Read Only Area 0091 0095 00c9 00ca 00f8 00fc 0191 Write Only Area 0450 047f Read Write Area 0080 0081 00c1 00c4 00c6 00c8 00d1 Unused Area 0082 008f 0093 0097 009f ...

Page 228: ...or gr go after reset command Format otf direct input mode Example otf Set on the fly display off This command toggles the on the fly display function otf Set on the fly display on Note The on the fly display is turned on at power on by default GUI utility Option Mode Setting menu item When this menu item is selected a dialog box appears allowing selection of the on the fly display option Use the O...

Page 229: ...mmand Either execution time count mode or step count mode can be selected Format tim direct input mode Example tim Set step count mode This command toggles the measurement mode tim Set real time count mode Note The execution time count mode is set at power on by default GUI utility Option Mode Setting menu item When this menu item is selected a dialog box appears allowing selection of a measuremen...

Page 230: ...M read write test Format chk direct input mode Display If a ROM check error is detected the normal value and the error value will be displayed chk ROM check error 5F FF normal value 5F error value FF If a RAM check error is detected the memory address the normal value and the error value will be displayed chk RAM check error 110 5 F address 110 normal value 5 error value F GUI utility Option Self ...

Page 231: ... 219 S1C60 62 FAMILY ASSEMBLER PACKAGE CHAPTER 9 DEBUGGER 9 9 20 Quit q quit Function This command quits the debugger Format q direct input mode GUI utility File Exit menu item Selecting this menu item terminates the debugger ...

Page 232: ...address is larger than the end address pf pm df dm bp cv Error error file type extension should be CMD The extension of the command file should be CMD com Error Incorrect identifier use An illegal parameter has been specified for an item of the bm PC ADDR DATA OPT A B X Y F command bm Error illegal code The input code is not available pe pf Error illegal mnemonic The input mnemonic is invalid for ...

Page 233: ...S1C62 Family Assembler Package Quick Reference ...

Page 234: ... Carry borrow 0 No carry CMOS 4 bit Single Chip Microcomputer S1C62 Family Assembler Package Quick Reference for Development Step 0x0 0x1 0xf 0xff Maximum configulation Maximum configulation Data Memory Map Page 0 Bank 0 Page 1 Page 15 Page 0 Bank 1 Page 1 Page 15 Program start address Interrupt vector area Program area NPP NBP Page 1 Bank 0 Step 0x0 0xff Program area Other pages Step 0x0 0x1 0xf ...

Page 235: ...counter bank PCB or its contents 1 bit PCP Program counter page PCP or its contents 4 bits PCS Program counter step PCS or its contents 8 bits PCSH 4 high order bits of PCS 4 bits PCSL 4 low order bits of PCS 4 bits Memory Addresses Memory Data MX M X Data memory addressed by IX or the contents of the specified memory MY M Y Data memory addressed by IY or the contents of the specified memory Mn M ...

Page 236: ...ck cycles No operation 7 clock cycles Halt stop CPU Sleep stop CPU and oscillation X X 1 Y Y 1 XH x 7 4 XL x 3 0 YH y 7 4 YL y 3 0 XP r XH r XL r YP r YH r YL r r XP r XH r XL r YP r YH r YL XH XH i C XL XL i C YH YH i C YL YL i C Clk 5 5 5 5 5 5 5 7 7 7 12 12 5 7 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 7 7 7 7 1 0 0 0 0 0 1 0 0 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 1 1 1 1 1 1...

Page 237: ... SP YL SP SP 1 M SP F r M SP SP SP 1 Clk 7 7 7 7 5 5 5 5 5 5 5 5 5 5 5 7 7 7 7 7 7 7 7 7 7 5 5 5 5 5 5 5 5 5 5 5 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 Z 1 0 1 0 C 1 0 1 0 I 1 0 1 0 D 1 0 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 0 0 0 0 1 1...

Page 238: ...M X M X r C X X 1 M Y M Y r C Y Y 1 r r Clk 5 5 5 5 5 5 5 5 5 5 5 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 5 7 7 7 7 7 7 7 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 0 1 0 1 0 1 0 1 0 1 1 1 1 0 1 1 1 1 1 1 1 1 Z C I D 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 0 1 0 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 1 0 0 0 0 0 1 0 1 1 ...

Page 239: ...tools for each model and Steps 3 and 5 are not covered in the S1C62 Family Assembler Package and the tools used for development depend on the model For details refer to the tool manual associated with each specific model Development tools for each model Work Bench wb62 Assembler as62 file MS Preprocessed source file s Linker lk62 file O file LST Object file s Assembly list file s file ALS Absolute...

Page 240: ...can be opened in the edit window area Project window This window shows the currently opened work space folder and lists all the source files in the project with a structure similar to Windows Explorer Double clicking a source file icon opens the source file in the Edit window Output window This window displays the messages delivered from the executed tools in a build or assemble process Double cli...

Page 241: ...t source header or project Open button Opens a document source header or project Save button Saves the document in the active Edit window to the file The file will be overwritten Save All button Saves the documents of all Edit windows and the project information to the respective files Cut button Cuts the selected text in the Edit window to the clipboard Copy button Copies the selected text in the...

Page 242: ...ds in the active Edit window Go To Ctrl G Jumps to the specified line or label in the active Edit window The file names listed in this menu are recently used source and project files Selecting one opens the file File menu Standard Bar Shows or hides the standard toolbar Status Bar Shows or hides the status bar Output Window Opens or closes the Output window Project Window Opens or closes the Proje...

Page 243: ...nd before closing task is being processed Would you like to build it The debugger invoke command is specified when the build task has not already been completed Short Cut Key List Ctrl N Creates a new document Ctrl O Opens an existing document Ctrl F12 Opens an existing document Ctrl S Saves the document Ctrl P Print the active document Ctrl Shift F12 Print the active document Ctrl Z Undoes the la...

Page 244: ...macro are specified with 1 to n endm par Dummy parameters ifdef name Conditional assembling statements 1 name defined statements 1 is assembled else name undefined statements 2 is assembled statements 2 endif ifndef name Conditional assembling statements 1 name undefined statements 1 is assembled else name defined statements 2 is assembled statements 2 endif code Declares the start of a code secti...

Page 245: ...l label Reference was made to an undefined label Unknown mnemonic name A non existing instruction was described Unknown symbol mask name The symbol mask has a description error Unsupported directive directive A non existing pseudo instruction was described Warning Message Second definition of define symbol symbol The symbol is multiply defined by define Section activation expected use code bss The...

Page 246: ...l file name FILE NAME specified with The file name specified with the option is incorrect option option Illegal object format FILE NAME The input file is not an object file in IEEE 695 format Illegal option option An illegal option is specified CODE section address address overlaps The address range of the section is duplicated with section type section address address No address specified with op...

Page 247: ...d Cannot read file kind file FILE NAME The file cannot be read Cannot write file kind file FILE NAME Data cannot be written to the file Different processor types The ICE parameter file contains an illegal parameter setting Illegal file name FILE NAME The specified input file name is incorrect Illegal option option An illegal option is specified Illegal absolute object format The input file is not ...

Page 248: ...t be read Cannot write file kind file FILE NAME Data cannot be written to the file Illegal file name FILE NAME The specified input file name is incorrect Illegal HEX data format The input file is not an Intel HEX format file Illegal offset address offset address The specified address is invalid Illegal option option An illegal option is specified No ICE parameter file specified ICE parameter file ...

Page 249: ...reased efficiency in the debugging tasks Window Start up Command Usage Usage db62 parameter file name startup option Options command file specifies a command file comX X 1 4 com port default com1 b baud rate 1200 4800 9600 19200 default Source window Displays programs with unassemble codes source codes or disassemble and source codes Register window Displays register values and fetched codes Trace...

Page 250: ...log box for the debugger Tool bar Find button Searches the specified word and moves the source display to the found word location Search Label pull down list box Moves the source display to the selected label location Controls on Source window Debugger db62 2 Development Tools Menus Load File Reads an object file in the IEEE 695 format into the debugger Load Option Reads a program or optional HEX ...

Page 251: ...ode Opens or activates the Source window and displays the program from the current PC address in the display mode selected from the sub menu items Data Dump Opens or activates the Data window and displays the data memory contents from the memory start address Register Opens or activates the Register window and displays the current values of the registers Trace Opens or activates the Trace window a...

Page 252: ...ssemble display sc addr Source display m addr Mix display Symbol information sy keyword keyword a List symbols Load file lf file name Load IEEE 695 format absolute object file lo file name Load Intel HEX format file ROM access rp Load program from ROM vp Verify the contents of ROM with program memory rom 64 128 256 512 Set ROM type Trace tc s m e Set trace condition ta all start1 end1 start4 end4 ...

Page 253: ...E62 firmware RAM error found during self diagnostic test Error undefined code detected Some undefined code is detected when loading file ICE status Status break hit A breakpoint is met when executing a program Status break switch pushed Break switch is pressed Status halt The status of ICE is halt Status key break Key break is pressed Status reset switch target Reset switch is pressed Status reset...

Page 254: ... del Vallès SPAIN Phone 34 93 544 2490 Fax 34 93 544 2491 ASIA EPSON CHINA CO LTD 23F Beijing Silver Tower 2 North RD DongSanHuan ChaoYang District Beijing CHINA Phone 64106655 Fax 64107319 SHANGHAI BRANCH 4F Bldg 27 No 69 Gui Qing Road Caohejing Shanghai CHINA Phone 21 6485 5552 Fax 21 6485 0775 EPSON HONG KONG LTD 20 F Harbour Centre 25 Harbour Road Wanchai Hong Kong Phone 852 2585 4600 Fax 852 ...

Page 255: ...60 62 Family Assembler Package S5U1C62000A Manual EPSON Electronic Devices Website ELECTRONIC DEVICES MARKETING DIVISION First issue September 1998 Printed March 2002 in Japan B L M http www epsondevice com ...

Reviews: