Debug is a byte editor that enables files to be viewed and modified at the byte level. It is generally recommended that this utility is not used by the faint of heart or when under the influence of drugs or alcohol. There is no "undo" command, so make a backup before playing, eh?
Once Debug has been called, the somewhat cryptic "Debug prompt", a hyphen (-), is displayed. At the prompt, the following "Debug commands" are valid:
|?||.||This list of Debug commands.|
|D||[startaddress [endaddress|L range]]||Displays (part of) a segment of memory. By default startaddress is offset 100 of the first free segment of memory, or offset 100 of the segment containing a file loaded by Debug. The default endaddress is 017F (ie. a range of 128 bytes).|
|L||-||Loads a previously "named" (see N) file into memory where it can be viewed/edited. |
|L||number||Used with commands accepting a "range" argument to denote a number of bytes. Typically used in arguments as: startaddress L number. If number should take endaddress past the end of the segment, then number is truncated so the endaddress is the last byte of the segment.|
|N||[path] filename [arglist]||"Names" a file for Debug. A file must be "named" before it can be loaded for viewing/editing.|
|W||[address] [drive] [firstsector] [number]||write|
|XA||[#pages]||allocate expanded memory|
|XD||[handle]||de-allocate expanded memory|
|XM||[Lpage] [Ppage] [handle]||map expanded memory pages|
|XS||.||display expanded memory status|
- Debug.exe is one of those little programs that, in the hands of a skilled user, is an amazingly powerful tool with which one can view and edit the contents of memory both short term (RAM) and long term (hard/floppy/tape media). One can also compile (and, up to a point, decompile) assembly language code.
- After struggling for some time to come to grips with the ins and outs of Debug, I have finally decided to leave the explanations to others.
|File Name||Default Location||Dos Ver.||Win Ver.||Size||Date||Source|
Superscripts denote which same size files, if any, are identical (using FC).
|DOS Debug Tutorial|
- Fran Golden
|A comprehensive guide to DEBUG that starts with an introduction to machine code, moves on to assembly language|