Home
6809 DEBUGGER USER`S MANUAL 1st Printing COPYRIGHT (C
Contents
1. GO nX Set Breakpoint at n and proceed The G command is used to start realtime execution from the current context block the context block consists of all the registers displayed by the command All of the registers are loaded including the S register and control is transferred to the user program Instruction execution begins with the instruction pointed to by the P register and execution continues in real time If a breakpoint JSR is encountered IDB will regain control and give a register dump and enter command mode The nG command sets the P register in the context block to n then does a G command If the significance of n is one a leading zero byte is assumed The nX command is used to continue realtime execution from a breakpoint It also sets a new breakpoint at location n Copyright C 1984 SD 9 IDB Y 6809 DEBUGGER USER S MANUAL COMMAND SUMMARY n Open Location n and Display lt LF gt Display Next n lt LF gt Deposit and Display Next lt CR gt Close This Location n lt CR gt Deposit and Close Location Display Registers Current Instruction and Last Opened Location n A Set A Register to n n B Set B Register to n n C Set C Register ton n D Set D Register ton n X Set X Register to n n U Set U Register to n nsY Set Y Register to n n Z Set Z Register to n n S Set S Register ton n P Set P Register ton n Set Breakpoint on Location n G Start Realtime Execution GO nG Set P Register and GO n
2. IDBY9 6809 DEBUGGER USER S MANUAL VALUES ENTERED INTO THE DEBUGGER IDB accepts four formats for numbers Hex numbers a string of hex letters or digits dA BC9 22 BD3FA9 Period meaning the address of the last opened memory location whether it is open now or not This is referred to as the open location marker asterisk meaning the value that is displayed as the P register contents on a register dump location of next instruction to execute c single quote followed by any character meaning the ASCII value of the character c A is equivalent to typing in 41 hex likewise b hex 62 SIGNIFICANCE Numbers entered into IDB have significance size in bytes based on the number of digits keyed in This significance is used by commands which store into memory or 2 digits gives 1 byte significance or 4 digits gives 2 byte significance or 6 digits gives 3 byte significance or 8 digits gives 4 byte significance or 19 digits gives 5 byte significance Period has 2 bytes of significance Asterisk has 2 bytes of significance c has 1 byte of significance On UT O m IDB COMMANDS IDB commands fall into the following categories Examine and Modify Memory Set Register Breakpoints Execute Copyright C 1984 SD 2 IDB Y 6889 DEBUGGER USER S MANUAL Examine and Modify Commands The examine and modify commands are used to display and or change memory locations and registers COMMAND O
3. MANUAL Examples 1 FF 45 lt CR gt 27 45 lt LF gt 7 46 lt LF gt 0192 43 BD lt LF gt 7E3698 39 lt CR gt Kale opyright C 1984 SD DEPOSIT 45 OVER FF IN LOCATION 100 EXAMINE LOCATION 1099 EXAMINE NEXT OPEN THE LAST LOCATION EXAMINE NEXT CHANGE VALUE AND EXAMINE NEXT FIX INSTRUCTION AT P COUNTER DUMP REGISTERS C A 1 B FE Z X 3 31 U C27D P 3 5 S 4073 IDB09 6899 DEBUGGER USER S MANUAL SETTING REGISTERS The following commands are used to change the contents of a specific register by name COMMAND OPERATION n A Set A Register to n n B Set B Register to n n C Set C Register ton n X Set X Register to n n S Set S Register to n n P Set P Register to n n U Set U Register to n n Y Set Y Register to n n D Set D Register to n n Z Set Z register ton The n A n B n C n Z commands set registers A BC Z respectively to the rightmost byte of n The n X n S n P n U n Y and n D commands set registers XSP UY and D respectively to the rightmost two bytes of n If a one byte value is given a leading zero byte is assumed When the stack pointer is set IDB assumes that the value given minus 12 points to a interrupt context block i e n 12 points to a condition code byte The contents of this context block are used as the values of the registers When IDB starts up it allocates a 12 byte stack for the user s context block Copyright C 1984 SD 5 IDBY9 6889 DEBUGGER
4. USER S MANUAL Examples 1 A SET THE A REGISTER TO 61 FE B SET THE B REGISTER TO FE C C SET THE C REGISTER TO C SHOW REGISTERS C C A l B FE Z X 3 31 Y U C27D P 3 5 S 4873 1234 A SET THE A REGISTER TO 34 123456 B SET THE B REGISTER TO 56 SHOW REGISTERS C C A 34 B 56 Z X 3031 Y U P 3 5 S 4073 ole 1 X SET X TO 0001 SHOW REGISTERS C C A 34 B 56 Z X 0091 Y U P 3 5 S 4973 1234 X SET X TO 1234 SHOW REGISTERS C C A 34 B 56 Z X 1234 Y U P 3 5 S 4873 FE P SET P REGISTER TO FE FE LOOK AT LOCATION FE FE 2245 lt CR gt MAKE IT AN INSTRUCTION SHOW REGISTERS C C9 A 34 B 56 Z D X 1234 Y 0000 U P FE S 4 73 Caution setting the stack pointer S register causes the remaining registers to take on arbitrary new values according to their positions in the context block pointed to by the new value of the S register BE SET THE STACK POINTER TO FE SHOW REGISTERS F3 A 04 B 4 Z D X 9762 Y U C27D P 67 S FE Copyright C 1984 SD 6 IDB09 6809 DEBUGGER USER S MANUAL BREAKPOINT COMMAND Breakpoints are used to stop a program at a certain place so that the state of the machine can be examined The programmer places a breakpoint in his program where he wishes then he tells IDB to run his program see Execution Commands When the program hit
5. 6899 DEBUGGER USER S MANUAL lst Printing COPYRIGHT C 1984 SOFTWARE DYNAMICS NOTICE This manual describes IDB09 Version 1 9 Software Dynamics has carefully checked the information given in this manual and it is believed to be entirely reliable However no responsibility is assumed for inaccuracies Software Dynamics reserves the right to change the specifications without notice k kkkkkkkkkkekkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkikkkkk This manual describes software which is a proprietary product of Software Dynamics SD SD software is licensed for use on a single copy per computer basis and is covered by U S copyright laws Unless a written exception is obtained from SD the soft ware must be used only on the single computer whose unique SD assigned serial number matches that for which the software was purchased Copying the software for any purpose other than archival storage or use of the software on other than the as signed serial numbered CPU is strictly prohibited SD assumes no liability regarding the use of the software Ta Certain software programs and datafiles are delivered for use in an encrypted format The content of such programs and data are considered to be a trade secret of SD Attempts or suc cess at breaking the encryption publication of the results of such attempts or successes or copying storage or u
6. PERATION n Open Location n lt LF gt Display Next n lt LF gt Deposit and Display Next lt CR gt Close This Location n lt CR gt Deposit and Close Location Display Registers The n command is used to open location n and display its content Opening a location means to make it available for examination and or modification The lt LF gt line feed command is used to advance the open location address and display the contents of the new location The open location address is bumped by one and the next byte is displayed lt LF gt is only valid when a location is open The n lt LF gt command is used to deposit from one to five bytes The open location address is bumped by the significance of n n lt LF gt is only valid when a location is open The lt CR gt carriage return command is used to close the currently open location The open location address is not advanced lt CR gt is a no op when a location is not open The n lt CR gt command is used to deposit from one to five bytes into the open location The open location address is not advanced and the location is closed n lt CR gt is only valid when a location is open The Command is used to display the registers This display is referred to as a register dump elsewhere in this manual In a register dump the contents of the registers follow the letter naming that register Z refers to the page register Copyright C 1984 SD 3 IDB09 6899 DEBUGGER USER S
7. right do not appear as output of the debugger all other printed data is typical debugger output Many of the examples use previous examples to set up a known situation OPERATION The debugger gains control automatically in some ROM based systems Usually control is initially passed to the debugger by an SDOS DEBUG command or D typed to SDOS see SDOS Manual The programmer interacts with IDB via commands given at the keyboard IDB gives has no prompt but does dump the registers on startup IDB checks command input character by character If an entry is incorrect it is diagnosed immediately by a print out of 22 followed by a carriage return When a command error occurs any opened location is closed If a valid command is entered IDB executes the command and accepts another command All IDB commands and hexadecimal numbers can be entered in either upper or lower case In this manual only uppercase commands are shown A small letter immediately to the left of a command represents a numeric value entered by the operator COMMAND FORMAT All commmands to IDB fit one of the following forms E No Parameter nC Single Parameter n C Single Parameter where n is a hex number up to ten digits depending upon the command lt CR gt is a carriage return lt LF gt is a line feed and C is a command character letter punctuation mark lt CR gt or lt LF gt gt is a semicolon and is a comma Copyright C 1984 SD 1
8. s a breakpoint control is passed to IDB which results in a register dump The programmer then can examine or change memory place a new breakpoint start his program again or continue execution from where it left off COMMAND OPERATION n Set Unconditional Breakpoint on Address n Clear Breakpoint An IDB breakpoint consists of a JSR instruction The JSR instruction is planted at the breakpoint location to regain control when encountered Since a JSR takes three bytes no breakpoint may be set within two bytes of another breakpoint Setting breakpoints in ROM doesn t work This may not be obvious since the breakpoints can t be seen in the user s code while IDB is in the command input mode The breakpoint JSR instruction is not planted in the user code Execution is requested see Execution Commands For example if a breakpoint were set at location 208 by entering 209 examination of location 208 will still show the original user code rather than IDB S breakpoint JSR instruction Copyright C 1984 SD 7 IDBY9 6899 DEBUGGER USER S MANUAL When the user s program is executing and it encounters a breakpoint JSR then the breakpoint is hit the breakpoint JSR is removed the original user code is restored and a register dump is displayed IDB then enters command input mode When a breakpoint hits the next instruction to execute is the one at the breakpoint address the instruction at the breakpoint has not yet been exec
9. se of such a file in clear text form will be treated as theft of a trade sec ret and prosecuted as such kk POSSESSION OR USE OF THIS MANUAL OR THE SOFTWARE IT DESCRIBES CONSTITUTES AGREEMENT BY THE USER TO THESE TERMS REXEREREREK ARE RARA RARA RRA RARA AAA RR This manual and the software it describes are the copyrighted property of Software Dynamics TABLE OF CONTENTS INTRODUCTION s o o o o OPERATION o o o COMMAND FORMAT e o o VALUES ENTERED INTO THE DEBUGGER SIGNIFICANCE e o eo IDB COMMANDS e EXAMINE AND MODIFY COMMANDS SETTING REGISTERS e e e Ld e e e BREAKPOINT COMMANDS s e e e EXECUTION COMMANDS s e o COMMAND SUMMARY a e o Copyright C 1984 SD 19 IDB Y 6899 DEBUGGER USER S MANUAL INTRODUCTION IDB is a small memory stand alone debugger for 6809 microprocessor systems It is appropriate for debugging assembly language object programs IDB allows the programmer to display and change memory to display and change registers and to set breakpoints This manual describes IDB Version 1 09 NOTATION In the examples included in this manual underlined characters are typed by the operator Comments to the
10. uted Entering the G command on the console after hitting the breakpoint will result in an immediate breakpoint hit without having executed any instructions because the P register still points to the breakpoint location The convenient way to continue from a breakpoint is to use the set new breakpoint and proceed nX command Using a JSR instruction for a breakpoint causes some peculiarities Example BRA Ll LO BEQ L3 L1 LDAA 5 Breakpointing on L is hazardous during realtime execution if the BRA Ll is executed The reason for this is that the breakpoint JSR is planted at L and it will take up the first byte of Ll so that during realtime execution Ll does not contain a LDAA 5 instruction Example BSR XYZ Breakpointing the BSR is fatal when the RTS in subroutine XYZ is executed because the third byte of the breakpoint JSR covers the first byte of the instruction following the BSR When the called subroutine returns the instruction will most likely be invalid and at the very least will cause unpredictable results The set breakpoint command n is used to set the breakpoint on a particular location Examples 109 SET BREAK AT LOCATION 1909 4852 SET BREAK AT 4852 Copyright C 1984 SD 8 IDB 9 68099 DEBUGGER USER S MANUAL EXECUTION COMMANDS The execution commands are used for proceeding from a breakpoint or restarting a program COMMAND OPERATION G Start Realtime Execution GO nG Set P Register and
11. x Set new breakpoint and GO to location in P register Copyright C 1984 SD 19
Download Pdf Manuals
Related Search
Related Contents
Samsung GT-E1170I Εγχειρίδιο χρήσης Program Grapher Presentation Carlos Motta 18 Stuyvesant Oval # 6G, New York, NY, 10009 +1.917 POSH Revel S500 Manual de Usuario Memup MELODY Samsung S630 User`s Manual - Downloaded from ManualsCamera Pulse Recorder USER MANUAL Copyright © All rights reserved.
Failed to retrieve file