From 8f54381b818cf2db4288455b9a60784d3e97004a Mon Sep 17 00:00:00 2001 From: geijoenr Date: Mon, 16 Mar 2015 10:28:13 +0000 Subject: [PATCH] msx2: use font6x8 required to initialize vdp from Fuzix instead of from the bios; besides, this font looks better. --- Kernel/platform-msx2/config.h | 2 ++ Kernel/platform-msx2/crt0.s | 16 ++++++++++++++++ Kernel/platform-msx2/fuzix.lnk | 2 ++ 3 files changed, 20 insertions(+) diff --git a/Kernel/platform-msx2/config.h b/Kernel/platform-msx2/config.h index 30981335..546ad16a 100644 --- a/Kernel/platform-msx2/config.h +++ b/Kernel/platform-msx2/config.h @@ -17,6 +17,8 @@ /* As reported to user space - 4 banks, 16K page size */ #define CONFIG_BANKS 4 +#define CONFIG_FONT6X8 + /* Vt definitions */ #define VT_WIDTH 80 #define VT_HEIGHT 24 diff --git a/Kernel/platform-msx2/crt0.s b/Kernel/platform-msx2/crt0.s index fbc4181c..d15b06df 100644 --- a/Kernel/platform-msx2/crt0.s +++ b/Kernel/platform-msx2/crt0.s @@ -25,6 +25,8 @@ .globl init_hardware .globl s__DATA .globl l__DATA + .globl s__FONT + .globl l__FONT .globl s__DISCARD .globl l__DISCARD .globl s__COMMONMEM @@ -87,6 +89,20 @@ start: ld bc, #l__COMMONMEM ldir + ; move font where it belongs + ; FIXME: font6x8 is shifted the wrong way for msx vdp + ; so correct it here for now + ld de, #s__FONT + ld bc, #l__FONT +cpfont: + sla (hl) + sla (hl) + ldi + ld a,b + or c + jr nz, cpfont + + ; move the discardable memory where it belongs ld de, #s__DISCARD ld bc, #l__DISCARD diff --git a/Kernel/platform-msx2/fuzix.lnk b/Kernel/platform-msx2/fuzix.lnk index 4fd1e2ec..ff81d2c2 100644 --- a/Kernel/platform-msx2/fuzix.lnk +++ b/Kernel/platform-msx2/fuzix.lnk @@ -3,6 +3,7 @@ -b _CODE=0x0000 -b _COMMONMEM=0xF000 -b _DISCARD=0xE000 +-b _FONT=0xFA00 -l z80 platform-msx2/crt0.rel platform-msx2/commonmem.rel @@ -35,6 +36,7 @@ vt.rel devsys.rel usermem.rel usermem_std-z80.rel +font6x8.rel platform-msx2/blkdev.rel platform-msx2/devsd.rel platform-msx2/devsd_discard.rel -- 2.34.1