1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type"
content="text/html; charset=iso-8859-1">
<meta name="GENERATOR" content="Mozilla 1.1 under Linux">
<title>TiEmu User's Manual</title>
<meta name="author" content="The TiEmu team">
<meta name="description" content="User's Manual">
</head>
<body style="background-color: rgb(255, 255, 255);">
<div align="center">
<div style="text-align: left;">
<div class="NAVFOOTER">
<hr align="left" width="100%">
<table summary="Footer navigation table" border="0" cellpadding="0"
cellspacing="0" width="100%">
<tbody>
<tr>
<td align="left" valign="top" width="33%"><a href="chapter06.html"
accesskey="P">Prev</a></td>
<td align="center" valign="top" width="34%"><a
href="Manual_en.html" accesskey="H">Home</a></td>
<td align="right" valign="top" width="33%"><a
href="chapter08.html" accesskey="N">Next</a></td>
</tr>
<tr>
<td align="left" valign="top" width="33%">Popup menu<br>
</td>
<td align="center" valign="top" width="34%"> </td>
<td align="right" valign="top" width="33%">Screenshots<br>
</td>
</tr>
</tbody>
</table>
<hr align="left" width="100%">
</div>
</div>
</div>
<h1>7. Debugger</h1>
Debugging mode is entered when a breakpoint is encountered or when the
user launches the debugger by the popup menu or by pressing the F11
key. This will stop the emulation engine but the LCD is still refreshed.<br>
<br>
Note: Debugger windows are preloaded at startup in order to display
them quicker. The source code window may take a while to be displayed
the first time: this is due to ROM call parsing.<br>
<br>
The debugger is made-up of several frames:<br>
- source code<br>
- registers<br>
- memory<br>
- breakpoints<br>
- PC trace<br>
- stack<br>
- heap (handles)<br>
<br>
These frames can be moved and/or resized (TiEmu saves/restores this with
the configuration).<br>
Frames are automatically refreshed when a change occurs from another
frame.<br>
<h2>7.1 Source code<br>
</h2>
<div style="text-align: center;">
<div style="text-align: left;">This frame is the main one:<br>
</div>
<img alt="" src="dbg_source.png" style="width: 328px; height: 321px;"><br>
</div>
<br>
You can browse the source code with the arrow and PageUp/Down keys. The
green bar shows the current PC location. The blue one is the selection. The
red cross is a breakpoint.<br>
<br>
By right-clicking, you get the popup menu:<br>
- <span style="font-style: italic;">go to address</span>: enter the
address to go,<br>
- <span style="font-style: italic;">go to PC</span>: jump to PC
location,<br>
- <span style="font-style: italic;">set breakpoint (F2)</span>: place
a breakpoint at the selection. The bkpt frame is updated,<br>
- <span style="font-style: italic;">set temporary breakpoint</span>:
place a breakpoint at the selection. This bkpt will be automatically
removed when encountered.<br>
- <span style="font-style: italic;">set PC to selection</span>: load
PC with the address at the selection,<br>
- <span style="font-style: italic;">view memory</span>: open a tab in
the memory frame with the address at the selection.<br>
<br>
The combo box lets you choose a ROM call by using the arrow. You can
type it, too. It has automatic completion. Once selected, the view is
updated to begin on the ROM call's address.<br>
<br>
Debugging facilities provided are: <br>
- <span style="font-style: italic;">run/break</span>: start/stop
emulation engine without closing frames, <br>
- <span style="font-style: italic;">step in/out/over</span>: <br>
step in equals to step by step<br>
step out runs PC until a RTS/RTR/RTD/RTE/STOP
instruction is reached (go out of the sub-routine)<br>
step over runs PC until the instruction after the
current one is reached (skips all code in a sub-routine for instance),
except for branches. <br>
This works for JSR/BSR/FLINE/DBCC/TRAP, <br>
- <span style="font-style: italic;">run to cursor</span>: runs PC
until the address under the cursor is reached.<br>
<br>
Miscellaneous shortcuts:<br>
- F6: (internal use) copy source code window content to C:\disasm.txt<br>
- F1: set selection and PC to next line<br>
<h2>7.2 Registers</h2>
<table style="width: 100%; text-align: left;" border="0" cellpadding="2"
cellspacing="2">
<tbody>
<tr>
<td style="text-align: center; vertical-align: top;"><img alt=""
src="dbg_registers.png" style="width: 188px; height: 392px;"><br>
</td>
<td style="vertical-align: top;">This frame displays all of the
registers of the MC68000 processor. Take a look at the m68k
user's manual if needed.<br>
<br>
USP = User Stack Pointer (A7 in user mode, S=0).<br>
SSP = System Stack Pointer (A7 is supervisor mode, S=1).<br>
The active pointer is displayed in the stack frame.<br>
<br>
SR is displayed in 2 modes: hexadecimal and single flags.<br>
<br>
Each field is in-place editable.<br>
<br>
By right-clicking on the address/data registers content, you will open
a tab in the memory view at the adress contained in the register.
Useful for browsing pointers and/or arrays.<br>
<br>
If you double-click on sf/uf, you will be able to edit each flag:<br>
<div style="text-align: center;"><img alt="" src="dbg_sr.png"
style="width: 413px; height: 129px;"><br>
</div>
</td>
</tr>
</tbody>
</table>
<br>
<h2>7.3 Memory</h2>
<div style="text-align: center;">
<div style="text-align: left;">
<table style="width: 100%; text-align: left;" border="0" cellpadding="2"
cellspacing="2">
<tbody>
<tr>
<td style="vertical-align: top;"><img alt="" src="dbg_mem.png"
style="width: 534px; height: 274px;"></td>
<td style="vertical-align: top;">You can add/remove as many tabs
as you want. Click on +/- to add_remove tabs.<br>
Use the arrow keys or Page Up/Down keys to browse memory.<br>
<br>
Each value can be edited in-place. Click the cell and you will be able
to enter an hexadecimal string (like 12, 1234, 567890).<br>
<br>
By right-clicking, you will get the popup menu:<br>
- <span style="font-style: italic;">find / find next</span>: opens a
search dialog,<br>
- <span style="font-style: italic;">go to address</span>: lets you
enter a hexadecimal address to go to,<br>
- <span style="font-style: italic;">dis-assemble</span>: updates the
source frame at the selected address.<br>
</td>
</tr>
</tbody>
</table>
Note: The memory window may show aliases (ghosts) which does not
really exist on the real calculator. For instance, RAM on the TI-89
Titanium exists at 0x00000-0x3ffff only but if you open a tab at
0x40000, you will see RAM content at 0x000000. So, be careful!<br>
<br>
</div>
</div>
About the search dialog:<br>
<br>
<table style="width: 100%; text-align: left;" border="0" cellpadding="2"
cellspacing="2">
<tbody>
<tr>
<td style="vertical-align: top;"><img alt="" src="dbg_search.png"
style="width: 306px; height: 191px;"><br>
</td>
<td style="vertical-align: top;">You can search for hexadecimal
values or strings with or without case sensitivity (strings only).<br>
<br>
Click the right button to start a search.<br>
Click the middle button to find the next occurrence.<br>
<br>
The occurrence is highlighted in green in the memory frame.<br>
</td>
</tr>
</tbody>
</table>
<br>
<h2>7.4 Breakpoints</h2>
<br>
<table style="width: 100%; text-align: left;" border="0" cellpadding="2"
cellspacing="2">
<tbody>
<tr>
<td style="vertical-align: top;"><img alt="" src="dbg_bkpts.png"
style="width: 351px; height: 210px;"><br>
</td>
<td style="vertical-align: top;">This frame lets you manage
several kinds of breakpoints:<br>
- code (added from the source frame)<br>
- exception (traps, auto-ints, ...)<br>
- data (access or range)<br>
- program entry (the debugger is raised at the beginning of the program you
have just launched).<br>
<br>
Each breakpoint can be added or removed and enabled or disabled. You
can go to the breakpoint location, too (last toolbar button).<br>
</td>
</tr>
</tbody>
</table>
<h2>7.5 PC trace</h2>
This frame shows the 10 latest PC values. Double-clicking the row will
update the source frame with the address in the row.<br>
<h2>7.6 Stack frame</h2>
<br>
<table style="width: 100%; text-align: left;" border="0" cellpadding="2"
cellspacing="2">
<tbody>
<tr>
<td style="vertical-align: top;"><img alt="" src="dbg_stack.png"
style="width: 168px; height: 284px;"><br>
</td>
<td style="vertical-align: top;">The 'A7 (stack) is' shows the
current active stack pointer (user/supervisor).<br>
<br>
The frame displays the stack pointer (A7) and the frame pointer (A6)
used on the TI for function call and data storage.<br>
<br>
Content is displayed as word values only. You can browse it by using
the arrow or Page Up/Down keys.<br>
</td>
</tr>
</tbody>
</table>
<br>
<h2>7.7 Heap</h2>
<br>
<table style="width: 100%; text-align: left;" border="0" cellpadding="2"
cellspacing="2">
<tbody>
<tr>
<td style="vertical-align: top;"><img alt="" src="dbg_heap.png"
style="width: 168px; height: 274px;"><br>
</td>
<td style="vertical-align: top;">This frame displays all the
handles the calculator has. It shows: <br>
- handle number,<br>
- address in memory,<br>
- and size.<br>
<br>
Double click the row to open a tab in the memory frame at the address
pointed by the handle.<br>
</td>
</tr>
</tbody>
</table>
<br>
<hr>
</body>
</html>
|