MSDOS debugger

By | January 24, 2020

If you are not familiar how to enable old legacy MSDOS application capabilities on modern Windows OS, it is good to start with “WoW. 16-bit supplication on 32-bit Windows” article. The MS-DOS debugger is portable command line-oriented debugger in operating systems such as MS-DOS and OS/2, Windows (16-bit/32-bit versions only). It is started by DEBUG command from command prompt. It was rather powerful in old time with a lot of possibilities such as debugging, modifying and creating 16-bit applications. The DEBUG can be used as an assembler, disassembler, hex dumping and debugging. The list of DEBUG commands may be retrieved by typing “?”:
Debug Help
In 90s I liked to use it to created simple executable especially when I tested some peripheral equipment connection to serial or parallel ports.
The short illustrated tutorial how to use DEBUG to create simple COM executable, debug and modify later is presented below.
1. Create the file. Using “a” command type the code in 8086 assembler language, specify the text message (“e” command), the message text should be terminated with ‘$’ symbol. “n” and “w” commands for file name selection and saving. CX register should contain number of bytes to write in to the file. The code location of COM files has always offset 0x100. The bytes from 0 to 0xff are reserved for header.
Debug. New COM file
2. Debugging of the program:
Debugging of COM file
3. Modifying the program, changing text message:
Debug. Edit COM file

Leave a Reply

Your email address will not be published. Required fields are marked *