diff --git a/src/aliases/,aliases_hardware_m65.s b/src/aliases/,aliases_hardware_m65.s index 75688eaf..075f5ac6 100644 --- a/src/aliases/,aliases_hardware_m65.s +++ b/src/aliases/,aliases_hardware_m65.s @@ -10,24 +10,34 @@ // VIC-IV registers - .label VIC_KEY = $D02F - .label VIC_CTRLA = $D030 - .label VIC_CTRLB = $D031 + .label VIC_KEY = $D02F + .label VIC_CTRLA = $D030 + .label VIC_CTRLB = $D031 - .label VIC_XPOS = $D050 + .label VIC_XPOS = $D050 - .label VIC_CTRLC = $D054 + .label VIC_CTRLC = $D054 - .label VIC_CHARSTEP = $D058 // 2 bytes - logical characters per line + .label VIC_CHARSTEP = $D058 // 2 bytes - logical characters per line - .label VIC_SCRNPTR = $D060 // 4 bytes - pointer to start of screen memory - .label VIC_COLPTR = $D064 // 2 bytes - pointer to start of color memory + .label VIC_SCRNPTR = $D060 // 4 bytes - pointer to start of screen memory + .label VIC_COLPTR = $D064 // 2 bytes - pointer to start of color memory - .label VIC_CHARPTR = $D068 // 3 bytes - pointer to start of character generator + .label VIC_CHARPTR = $D068 // 3 bytes - pointer to start of character generator + + // DMAgic + + .label DMA_ADDRLSBTRIG = $D700 + .label DMA_ADDRMSB = $D701 + .label DMA_ADDRBANK = $D702 + .label DMA_EN018B = $D703 + .label DMA_ADDRMB = $D704 + .label DMA_ETRIG = $D705 + .label DMA_ADDRLSB = $D70E // MISC registers - .label MISC_BOARDID = $D629 // board identification byte - .label MISC_EMU = $D710 // to enable badlines and slow interrupts + .label MISC_BOARDID = $D629 // board identification byte + .label MISC_EMU = $D710 // to enable badlines and slow interrupts #endif diff --git a/src/aliases/,aliases_ram_over64K_m65.s b/src/aliases/,aliases_ram_over64K_m65.s index 19ef2082..f26d15a7 100644 --- a/src/aliases/,aliases_ram_over64K_m65.s +++ b/src/aliases/,aliases_ram_over64K_m65.s @@ -6,12 +6,11 @@ // $10000-$17FFF (32KB) - reserved for DOS // $18000-$18FFF (4KB) - chargen copied to RAM, to allow character redefinition - // $19000-$1B7FF (10KB) - reserved for virtual text screenk, 80x128 + // $19000-$1B7FF (10KB) - reserved for virtual text screen, 80x128 .const MEMCONF_SCRBASE = $9000 .const MEMCONF_SCRROWS = 128 - // $1B800-$1DFFF (10KB) - reserved for a color RAM backup when switchin between text/graphics modes // (4KB) - reserved for sprites // (2KB) - reserved for future use diff --git a/src/dos_m65/,aliases_dos.s b/src/dos_m65/,aliases_dos.s index f182d3ce..920c62b6 100644 --- a/src/dos_m65/,aliases_dos.s +++ b/src/dos_m65/,aliases_dos.s @@ -12,3 +12,8 @@ .label UNIT_FLOPPY = $06 .label UNIT_RAMDISK = $07 + + // NOTES: + // - DOS zeropage is mirrored at $8000 + // - starting from $8000, 16KB RAM is available (starting from $10000 in C65 address space) + // - additional 16KB RAM is reserved for DOS too ($14000-$17FFF), and can be banked-in if needed diff --git a/src/kernal/board_m65/mega65_map_helpers.s b/src/kernal/board_m65/mega65_map_helpers.s index 1453ef6c..7e2b41e0 100644 --- a/src/kernal/board_m65/mega65_map_helpers.s +++ b/src/kernal/board_m65/mega65_map_helpers.s @@ -74,15 +74,15 @@ map_DOS_1: phy phz - lda #$C0 + lda #$80 tab // from now on, zeropage starts from $C000 - ldy #$40 - lda #$40 - taz // $C000 <- map 8KB from $10000 + ldy #$80 + lda #$30 + taz // $8000 <- map 16KB RAM from $10000 lda #$C0 - ldx #$C1 // $4000 <- map 16KB from $20000 + ldx #$C1 // $4000 <- map 16KB ROM from $20000 map jmp_8 map_end_no_eom // no EOM, we do not want interrupts within DOS! diff --git a/src/kernal/extapi_m65/mega65__jumptable.s b/src/kernal/extapi_m65/mega65__jumptable.s index 2cf575d5..00f2a016 100644 --- a/src/kernal/extapi_m65/mega65__jumptable.s +++ b/src/kernal/extapi_m65/mega65__jumptable.s @@ -11,7 +11,7 @@ M65_JMODE64: jsr M65_MODE64 -M65_JMODE65: +M65_JMODE65: // XXX consider combining with M65_JMODE64 jsr M65_MODE65 M65_JISMODE65: @@ -20,7 +20,7 @@ M65_JISMODE65: M65_JSLOW: jsr M65_SLOW -M65_JFAST: +M65_JFAST: // XXX consider combining with M65_JSLOW jsr M65_FAST M65_JSELDEV: @@ -29,13 +29,13 @@ M65_JSELDEV: M65_JCLRSCR: jsr M65_CLRSCR -M65_JCLRWIN: +M65_JCLRWIN: // XXX consider combining with M65_JCLRSCR jsr M65_CLRWIN M65_JSETWIN_XY: jsr M65_SETWIN_XY -M65_JSETWIN_WH: +M65_JSETWIN_WH: // XXX combine this with M65_JSETWIN_N, M65_JSETWIN_Y, and possibly M65_JSETWIN_XY jsr M65_SETWIN_WH M65_JSETWIN_N: