more code

This commit is contained in:
Kelvin Sherlock 2021-09-20 22:45:02 -04:00
parent d97b32a699
commit dfdf608018
4 changed files with 90 additions and 3 deletions

View File

@ -1,5 +1,5 @@
* lst off lst off
rel rel
xc xc
xc xc
@ -308,4 +308,4 @@ arrow
lda key lda key
jmp dispatch jmp dispatch
sav vt52.key.L sav vt100.key.L

View File

@ -13,6 +13,7 @@
asm vt100.csi.S asm vt100.csi.S
asm vt100.screen.S asm vt100.screen.S
asm vt100.modem.S asm vt100.modem.S
asm vt100.key.S
* lnk boot.S * lnk boot.S
@ -30,5 +31,6 @@
lnk vt100.csi.L lnk vt100.csi.L
lnk vt100.screen.L lnk vt100.screen.L
lnk vt100.modem.L lnk vt100.modem.L
lnk vt100.key.L
sav vt100.bin sav vt100.bin

View File

@ -9,6 +9,91 @@
ext scroll_down ext scroll_down
ext recalc_cursor,recalc_cursor_x,recalc_cursor_y ext recalc_cursor,recalc_cursor_x,recalc_cursor_y
ext write_modem,read_modem,init_modem,keypress
ext disable_cursor,enable_cursor
ext erase_screen
SET80VID equ $c00d
SETALTCHAR equ $c00f
TXTSET equ $c051
VGCINT equ $c023
SCANINT equ $c032
main
clc
xce
cli
jsr init
jsr enable_cursor
lda #4
tsb VGCINT ; enable 1-sec interrupt.
stz SCANINT ; reset 1-sec interrupt
loop
bit LOCAL
bmi :kb
jsr read_modem
bcc :kb
pha
jsr disable_cursor
pla
jsr vt100
:kb
jsr keypress
jsr enable_cursor
bra loop
init
sta TXTSET
sta SET80VID
sta SETALTCHAR
rep #$30
ldx #254
:zloop stz 0,x
dex
dex
bpl :zloop
lda #$0400
sta cursor_base
lda #$01
sta cursor_base+2
sep #$30
lda #"_"
sta cursor_char
lda #" "
sta erase_char
lda #23
sta DECBM
jsr erase_screen
jsr init_modem
rts
dispatch ent
mx %11
* a = character to xmit
bit LOCAL
bmi :local
jmp write_modem
:local
pha
jsr disable_cursor
pla
* fall through
vt100 vt100
mx %11 mx %11

View File

@ -15,7 +15,7 @@ SCCADATA equ $c03b
init_modem init_modem ent
sep #$30 sep #$30
* reset channel B (modem port) * reset channel B (modem port)
ldx #9 ldx #9