Getting in and out
Three ways in. ESC at the boot splash; the BRK statement in BASIC; any BRK opcode in user code. The prompt is a single ..
One way out. Type X. BASIC comes back warm — your program and variables are still there.
| Entry | Address | Used by |
| MonitorEntry | $EE00 | Cold entry from the boot menu, or X back from BASIC |
| MonitorBrkEntry | $EE03 | BRK entry with the register display |
Every command
| Cmd | Syntax | What it does |
| X | X | Exit to BASIC |
| R | R | Display CPU registers |
| M | M [addr] [addr] | Memory dump (hex + ASCII, 8 bytes/row) Default: 8 lines (64 bytes). Remembers position for continuation. |
| D | D [addr] [addr] | Disassemble 65C02 instructions Default: 20 lines. Remembers position for continuation. |
| > | > ADDR XX [XX XX ...] | Deposit (write) bytes to memory |
| F | F ADDR1 ADDR2 XX | Fill memory range with a byte value |
| T | T SRC_START SRC_END DEST | Copy memory block (handles overlapping regions) |
| H | H ADDR1 ADDR2 XX [XX XX ...] | Search for byte pattern in memory range Prints address of each match on its own line. |
| C | C ADDR1 ADDR2 ADDR3 | Compare two memory regions Compares [addr1,addr2] with block at addr3, prints differing addresses. |
| G | G [addr] | Go (JMP to address with full register restore via RTI) If addr given, sets BRK_PCL/PCH. Restores A, X, Y, P, SP via RTI. Program runs until BRK returns to monitor or forever. |
| J | J [addr] | Call subroutine and return to monitor on RTS Pushes monitor return address, restores A/X/Y, JMPs to target. When target does RTS, saves registers and re-enters monitor. |
| ; | ; PC xxxx A xx X xx Y xx SP xx P xx | Modify saved CPU registers Any subset, any order. Labels: PC, A, X, Y, SP, P |
| L | L ["FILE"] [ADDR] | Load from CF (with quoted filename) or XModem (without) CF path: L "FILENAME" [ADDR] — load file to addr (default $0800) Serial path: L [ADDR] — receive via XModem to addr (default $0800) |
| S | S ["FILE"] ADDR1 ADDR2 | Save to CF (with quoted filename) or XModem (without) CF path: S "FILENAME" ADDR1 ADDR2 — save [addr1,addr2) to file Serial path: S ADDR1 ADDR2 — send [addr1,addr2) via XModem |
| @ | @ | Display CF directory listing |
| N | N $XXXX | +DDDDD | %BBBB | Number base conversion Output: $XXXX +DDDDD %BBBBBBBBBBBBBBBB |
| # | # [NN] | Select / report the current CF disk bank |
Reading the register line
PC=E9D3 A=00 X=FF Y=68 SP=FA NV-BDIZC
The flag legend printed above the P byte by R and the BRK entry. A flag letter shown means the bit is set; a dash means it is clear. ; writes the same fields back.
Numbers
Addresses are typed as bare hex — M 0800, not M $0800. The N command is the exception and wants a prefix: $ hex, + decimal, % binary. It answers in all three.
. N $FF00
$FF00 +65280 %1111111100000000
Go versus Jump
Use J. J FF00 calls the code at an address and comes back to the monitor when it hits RTS. G hands the machine over for good — and it turns interrupts off on the way, so anything that waits for a keypress will sit there for ever.
The Wozmon easter egg. J FF00 from here, or SYS 65280 from BASIC, lands you in a copy of the original Apple I monitor. Its prompt is a backslash. FF00.FF07 reads eight bytes; 0800: A9 41 writes two.
The messages it prints
| Message | When |
| 6502 MONITOR v1.1 | On the way in, whichever route you came by |
| BRK AT $ | A BRK was hit — the address that follows is where |
| FILE NOT FOUND | L "NAME" and there is no such file on the current disk |
| DIRECTORY FULL | S "NAME" on a disk that already holds sixteen files |
| LOADED | A load finished — the byte count and address follow |
| SAVED | A save finished |
| BYTES AT $ | Tail of the load and save reports |
| BYTES | Tail of a report that has no address to give |
| I/O ERROR | The CompactFlash card did not answer |