DEBUG
Advanced Programmer's Command
DEBUG [([switch] [,] [parameter])]
The DEBUG command sets up the debug monitor, which allows you
to enter, test, and debug machine-language programs.
The
switches are:
ON turns
on
DEBUG
OFF turns off DEBUG
If switch is not specified,
ON
is assumed.
The
parameter is:
EXT specifies the extended debugger
EXT, ON, and OFF can be abbreviated to
E,
Y,
and
N.
Once you have turned on DEBUG, you automatically enter the debug
monitor whenever you do one of the following:
1.
Press the
(BREAK)
key (provided
(BREAK)
is enabled)
2.
Load and execute a user program (as long as the file's
protection is not execute only)
You can also automatically activate the debugger by holding down the
([)
key while the system is booting.
While
in
the DEBUG monitor, you can enter any of a special set of
single-key commands to study how your program is working (as
detailed under Command Description below).
EXT loads a separate block of the system debugger into high
memory. While DEBUG is on, TRSDOS automatically protects this
area of memory from being overlaid by BASIC or other user
programs.
If
you execute a program with execute only protection, DEBUG turns
off.
Examples
DEBUG
(ENTER)
turns
on
the standard DEBUG and waits for it to be activated.
DEBUG
(E)H)
(ENTER)
turns on extended DEBUG (loads it into high memory) and waits for it
to be activated.
DEBUG
(OFF)
(ENTER)
1-55