c64-io_monitor
c64-io_monitor copied to clipboard
Don't reset to normal bank, and copy BASIC from ROM to RAM if already swapped out
example: Durexforth reported by Whammo, BASIC
An explicit method to set the memory bounds of the log.
A function to return the length of the log.
Durexforth takes care of it's own banking- on QUIT or run/stop restore it goes bank 6
Good ideas, and thanks for the info on own banking -- sounds like it has its own NMI handler so control doesn't got back to BASIC. Makes sense.
I upgraded the NMI handler to deal with rs232, and run/stop restore in this manner. :-)
SYS is in the Kernal ROM so we hi-jacked it for Durexforth, and preserved the zero page for the register load/read.
( Calls Basic/Kernal routines.
Uses ar/xr/yr/sr for register I/O. )
$30c value ar $30d value xr
$30e value yr $30f value sr
.C:2440 B5 3B LDA $3B,X ; lsb from top of stack
.C:2442 85 14 STA $14 ; sys pointer
.C:2444 B5 73 LDA $73,X ; msb
.C:2446 85 15 STA $15 ; sys pointer
.C:2448 8A TXA
.C:2449 48 PHA ; save forth stack pointer
.C:244a 20 30 E1 JSR $E130 ; sys call
.C:244d 68 PLA ; restore forth stack pointer
.C:244e AA TAX
.C:244f E8 INX ; drop address from stack
.C:2450 60 RTS