DDT (Dunion's Debugging Tool) and Extended DDT
- Year
- 1982
- Publisher
- Atari Program Exchange (APX-20150); later OSS (in MAC/65) and Antic/The Catalog (Extended DDT)
- Type
- Development tool
- Category
- 6502 machine-language debugger
- Developer
- Jim Dunion
- Language
- 6502 assembly
- Requirements
- APX version: Atari Macro Assembler and Program Text Editor; Extended DDT: 48K and the MAC/65 cartridge
- Tags
- devtool, debugger, 6502, assembly, apx, mac-65, oss, breakpoints, single-step
- Related
- BUG/65, Altirra, Atari Macro Assembler (AMAC), MAC/65, SpartaDOS X, SpartaDOS
Overview
DDT, short for Dunion's Debugging Tool, is a machine-language debugger by Jim Dunion. It began life with the joke name "Little Jimmy D's Bugger". Its first public form was an Atari Program Exchange release (APX-20150, 1982) meant to sit alongside the Atari Macro Assembler and Program Text Editor. Mark Chasin's Assembly Language Programming for the Atari Computers (1984) listed "AMAC, MEDIT (an editor), and DDT (a debugger), all from the APX" as one of the six assembler packages then available for the Atari. Versions 0.92 (pre-release) and 1.00 survive.
DDT then moved into OSS's MAC/65 cartridge, where typing DDT at the editor prompt enters the debugger. That version reached the most people, and Ian Chadwick wrote in Mapping the Atari that he "used it constantly" while writing his chapter on the XL operating system. Its ASCII display and its disassembly of visible memory were what he found most useful. A disk-based Extended DDT followed. Antic's June 1988 "Power Tools" round-up, reviewing it bundled with a floating-point package for MAC/65 (catalogue AP0189, $19.95), called it "the best debugger for the Atari" and said "the amount of information it gives is overwhelming".
What it shows
DDT's strength is a full-screen display that is always up to date, unlike the line-at-a-time monitors of the Assembler Editor cartridge or BUG/65:
- a disassembly window around the program counter, which you can scroll;
- the stack;
- a table of watched variables and values, preset with OS locations such as RAMSIZ, MEMLO, MEMTOP, SDLSTL, SAVMSC and the colour registers;
- six breakpoint slots and two traps;
- the registers: PC, accumulator, the NV-BDIZC flags as bits, X, Y and SP.
The console keys run the session: OPTION single-steps, SELECT toggles the screen between DDT and your program's display, and START returns to the code. Single-letter commands examine memory, continue and leave breakpoints, set and clear breakpoints, change registers, deposit hex strings, go to an address, search memory, set traps, toggle the display window, and enter an interpretive mode.
Quirks
DDT moves its cursor with the bare - = + * keys, without CONTROL. That is handy on a real Atari but confusing in an emulator, where the PC arrow keys normally send CONTROL plus those keys. In Altirra, use the + and - keys directly, or change the keyboard mapping and make sure no joystick mapping captures them. Under SpartaDOS X, Extended DDT must be relocated out of the banked-memory window at $4000–$7FFF; users suggest $8000–$9FFF or configuring SDX to use OS RAM. It works more easily from a disk-based SpartaDOS 3.2 or 2.3. MAC/65 and DDT also use $480–$67F as buffers, so keep test code out of page 6.
Using it today
The MAC/65 cartridge image with DDT runs in Altirra, and in 2021 an AtariAge member even put a MAC/65 + DDT environment in a web page using MAME. For serious work, Altirra's own debugger now does far more, but DDT is still the most comfortable way to step through code on the Atari itself, for example while working through a book like Atari Roots.
Credits
- Picture: The APX version of DDT: disassembly, stack, watched variables, breakpoints and registers on one screen. — Screenshot from AtariMania
- AtariMania — Dunion's Debugging Tool (APX-20150, 1982; 'Little Jimmy D's Bugger'; v0.92/v1.00; requires AMAC and Program Text Editor; screenshots) — Screenshot from AtariMania, 1982
- Antic Vol. 7 No. 2 (June 1988) — Power Tools (Floating Point Package bundled with Extended DDT), Charles Cherry — SuperDOS screen photo from Antic Vol. 7 No. 2 (June 1988), via atarimagazines.com (Magazine illustration — used for identification/commentary), 1988
- Mapping the Atari (revised edition), Ian Chadwick — note on DDT in MAC/65
- AtariAge — DDT Question (key handling in emulators) — AtariAge forum members
- AtariAge — A good OS to run MAC/65 and EXDDT (May 2023; SpartaDOS/SDX relocation) — AtariAge forum members, 2023
- AtariAge — MAC/65 with DDT debugger, live emulator online (April 2021) — AtariAge forum members, 2021
- Assembly Language Programming for the Atari Computers (Mark Chasin, 1984), ch. 6 — AMAC, MEDIT and DDT from APX — AtariArchives.org, 1984
