diff --git a/vt.equ.S b/vt.equ.S index 87767a5..c8b30ad 100644 --- a/vt.equ.S +++ b/vt.equ.S @@ -82,6 +82,7 @@ mod ds 2 * saved cursor saved_x ds 2 saved_y ds 2 +saved_decom ds 2 do *>256 err "too big" diff --git a/vt100.esc.S b/vt100.esc.S index 100ad39..5349ec7 100644 --- a/vt100.esc.S +++ b/vt100.esc.S @@ -134,21 +134,24 @@ vt100_esc ent esc_7 ; save cursor position, graphic rendition, and character set. - +* based on testing, DECOM is also saved/restored. lda x sta saved_x lda y sta saved_y + lda DECOM + sta saved_decom rts esc_8 ; restore cursor position, graphic rendition, and character set. -* TODO - how does this interact with DECOM? - lda saved_x sta x lda saved_y sta y + lda saved_decom + sta DECOM + jmp recalc_cursor esc_eq ; enter alternate keypad mode