fixed DOS memory mapping

This commit is contained in:
FeralChild64 committed 2020-08-22 21:48:36 +02:00
1 parent 7437dc4548
commit 274a3c070a
4 files changed
+44 -46

No files matched your search

+1 -28
View File
@@ -2,7 +2,7 @@
// A vector table to integrate DOS with the MEGA65 Kernal // A vector table to integrate DOS with the MEGA65 Kernal
.word dos_INIT .word dos_INIT
.word dos_HASUNIT .word dos_CHKUNIT
.word dos_ACPTR .word dos_ACPTR
.word dos_CIOUT .word dos_CIOUT
.word dos_LISTEN .word dos_LISTEN
@@ -11,30 +11,3 @@
.word dos_TKSA .word dos_TKSA
.word dos_UNTLK .word dos_UNTLK
.word dos_UNLSN .word dos_UNLSN
// Dummy implementations - XXX to be replaced with real ones
dos_INIT:
nop
dos_HASUNIT:
nop
dos_ACPTR:
nop
dos_CIOUT:
nop
dos_LISTEN:
nop
dos_SECOND:
nop
dos_TALK:
nop
dos_TKSA:
nop
dos_UNTLK:
nop
dos_UNLSN:
nop
sec
rts
+26
View File
@@ -0,0 +1,26 @@
// Dummy implementations - XXX to be replaced with real ones
dos_INIT:
nop
dos_CHKUNIT:
nop
dos_ACPTR:
nop
dos_CIOUT:
nop
dos_LISTEN:
nop
dos_SECOND:
nop
dos_TALK:
nop
dos_TKSA:
nop
dos_UNTLK:
nop
dos_UNLSN:
nop
sec
rts
+4 -5
View File
@@ -77,13 +77,12 @@ map_DOS_1:
lda #$C0 lda #$C0
tab // from now on, zeropage starts from $C000 tab // from now on, zeropage starts from $C000
ldy #$00 ldy #$40
lda #$41 lda #$40
taz // $C000 <- map 8KB from $10000 taz // $C000 <- map 8KB from $10000
// XXX what should be the value here?? lda #$C0
lda #$A0 ldx #$C1 // $4000 <- map 16KB from $20000
ldx #$C2 // $4000 <- map 16KB from ?????
map map
jmp_8 map_end_no_eom // no EOM, we do not want interrupts within DOS! jmp_8 map_end_no_eom // no EOM, we do not want interrupts within DOS!
+13 -13
View File
@@ -6,16 +6,16 @@
// //
.label VDOS_INIT = $4000 .label VDOS_INIT = $4000 + 0 * 2
.label VDOS_HASUNIT = $4002 .label VDOS_CHKUNIT = $4000 + 1 * 2
.label VDOS_ACPTR = $4004 .label VDOS_ACPTR = $4000 + 2 * 2
.label VDOS_CIOUT = $4006 .label VDOS_CIOUT = $4000 + 3 * 2
.label VDOS_LISTEN = $4008 .label VDOS_LISTEN = $4000 + 4 * 2
.label VDOS_SECOND = $400A .label VDOS_SECOND = $4000 + 5 * 2
.label VDOS_TALK = $400C .label VDOS_TALK = $4000 + 6 * 2
.label VDOS_TKSA = $400E .label VDOS_TKSA = $4000 + 7 * 2
.label VDOS_UNTLK = $4010 .label VDOS_UNTLK = $4000 + 8 * 2
.label VDOS_UNLSN = $4012 .label VDOS_UNLSN = $4000 + 9 * 2
// XXX connect this to core IEC implementation // XXX connect this to core IEC implementation
@@ -24,13 +24,13 @@
m65dos_init: m65dos_init:
jsr map_DOS_1 jsr map_DOS_1
// XXX do after memory mapping is correct: jsr_ind VDOS_INIT jsr_ind VDOS_INIT
jmp_8 !+ jmp_8 !+
m65dos_hasunit: m65dos_chkunit:
jsr map_DOS_1 jsr map_DOS_1
jsr_ind VDOS_HASUNIT jsr_ind VDOS_CHKUNIT
jmp_8 !+ jmp_8 !+
m65dos_acptr: m65dos_acptr: