summaryrefslogtreecommitdiff
path: root/source/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'source/main.c')
-rw-r--r--source/main.c32
1 files changed, 21 insertions, 11 deletions
diff --git a/source/main.c b/source/main.c
index 9d25ee0..2fc613c 100644
--- a/source/main.c
+++ b/source/main.c
@@ -75,7 +75,7 @@ static void Splash(void)
{
static char scroller[]=
{
- " "
+ " "
"Welcome to DS81, a ZX81 emulator for the Ninetendo DS. "
"You can safely ignore this message. I was just bored for half an "
"hour. "
@@ -109,7 +109,10 @@ static void Splash(void)
ZX81SuspendDisplay();
ZX81DisplayString("10 print '%the zx81 is ace%'\n20 goto 10");
- TM_printf(0,23,"%-34.34s",scroller);
+ SUB_BG2_XDX = 0x080;
+ SUB_BG2_YDY = 0x080;
+
+ TM_printf(0,11,"%-18.18s",scroller);
FB_Clear();
@@ -186,13 +189,15 @@ static void Splash(void)
memmove(scroller,scroller+1,l-2);
scroller[l-2] = c;
- TM_printf(0,23,"%-34.34s",scroller);
+ TM_printf(0,11,"%-18.18s",scroller);
}
- SUB_BG0_X0 = scr_x;
+ SUB_BG2_CX = scr_x << 8;
}
- SUB_BG0_X0 = 0;
+ SUB_BG2_XDX = 0x100;
+ SUB_BG2_YDY = 0x100;
+ SUB_BG2_CX = 0;
ZX81ResumeDisplay();
}
@@ -296,15 +301,20 @@ int main(int argc, char *argv[])
/* Set up the sub-screen for rotation (basically for use as a framebuffer).
Now overlaid with a text screen for the monitor (I thought a bitmapped
printing routine would needlessly slow down the monitor when watching
- the ZX81 run).
+ the ZX81 run). Having said the overlay is currently a rotation map
+ for some pointless frippery! Still be quicker though.
*/
- videoSetModeSub(MODE_3_2D | DISPLAY_BG0_ACTIVE | DISPLAY_BG3_ACTIVE);
+ videoSetModeSub(MODE_4_2D | DISPLAY_BG2_ACTIVE | DISPLAY_BG3_ACTIVE);
vramSetBankC(VRAM_C_SUB_BG_0x06200000);
- SUB_BG0_CR = BG_COLOR_256 | BG_64x32 | BG_MAP_BASE(4) |
+ SUB_BG2_CR = BG_COLOR_256 | BG_RS_64x64 | BG_MAP_BASE(4) |
BG_TILE_BASE(0) | BG_PRIORITY(0);
- SUB_BG0_X0 = 0;
- SUB_BG0_Y0 = 0;
+ SUB_BG2_XDX = 0x100;
+ SUB_BG2_XDY = 0;
+ SUB_BG2_YDX = 0;
+ SUB_BG2_YDY = 0x100;
+ SUB_BG2_CX = 0;
+ SUB_BG2_CY = 0;
SUB_BG3_CR = BG_BMP8_256x256 | BG_BMP_BASE(1) | BG_PRIORITY(1);
SUB_BG3_XDX = 0x100;
@@ -321,7 +331,7 @@ int main(int argc, char *argv[])
/* Set up lower screen text overlay
*/
FB_LoadASCIITiles((uint16*)BG_TILE_RAM_SUB(0));
- TM_Init((uint16*)BG_MAP_RAM_SUB(4),64,32,FALSE);
+ TM_Init((uint16*)BG_MAP_RAM_SUB(4),64,64,TRUE);
/* Set up interrupts and timers
*/