Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rc2014: adapt to new RomWBW memory layout #1126

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 27 additions & 4 deletions Kernel/platform/platform-rc2014/boot-romwbw.s
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@ bootit:
ld hl,#0x8000 ; Don't copy first 256 bytes over
ld de,#0x4000
ld bc,#0x4000 ; We've loaded 0000-4000
ld a,#32
ld a,#40

di
out (MPGSEL_1),a ; Low bank at 0x4000 please
out (MPGSEL_1),a ; Bank 4 first 16K at 0x4000
ldir

;
Expand All @@ -102,8 +102,9 @@ bootit:
ld hl,#0x8000 ; Move it into place
ld de,#0x4000
ld bc,#0x4000
ld a,#33
out (MPGSEL_1),a ; Second kernel bank at 0x4000 please
ld a,#41
di
out (MPGSEL_1),a ; Bank 4 second 16K at 0x4000
ldir
pop bc

Expand Down Expand Up @@ -207,6 +208,28 @@ bootit:
out (MPGSEL_1),a
ldir

;
; Copy from bank 4 to bank 0
;
ld hl,#0x4000
ld de,#0x0000
ld bc,#0x4000
ld a,#40
out (MPGSEL_1),a
ld a,#32
out (MPGSEL_0),a
ldir

; page 41 to page 33
ld hl,#0x4000
ld de,#0x0000
ld bc,#0x4000
ld a,#41
out (MPGSEL_1),a
ld a,#33
out (MPGSEL_0),a
ldir

;
; Map the kernel low 16K block and jump into it
;
Expand Down
Loading