From 33e8319078be087dc7f59050772889e636a646d3 Mon Sep 17 00:00:00 2001 From: Tom Greene Date: Wed, 29 Jul 2020 22:27:46 -0400 Subject: [PATCH] Treat SHR registers as write-only (#318) * Treat SHR registers as write-only * Revert "no VidHD" This reverts commit dffb3b1cda9aeb3b67a228960802d16533786a56. --- src/4cade.init.a | 12 ------------ src/ui.attract.shr.a | 9 +++------ src/ui.common.a | 6 +++--- 3 files changed, 6 insertions(+), 21 deletions(-) diff --git a/src/4cade.init.a b/src/4cade.init.a index 8afbbc146..88476543a 100644 --- a/src/4cade.init.a +++ b/src/4cade.init.a @@ -35,18 +35,6 @@ sta zpMachineStatus sta SETC3ROM jsr HasVidHDCard ; check for VidHD card (allows super hi-res artwork even on non-IIgs machines) - bcc + - - ldy #@VidHDlen -- lda @s_VidHD,y - sta $68A,y - dey - bpl - -@hang2 bmi @hang2 -@s_VidHD !scrxor $80,"CANNOT RUN WITH VIDHD" -@VidHDlen=(*-@s_VidHD)-1 - -+ sta CLRC3ROM ror zpMachineStatus lda ROM_MACHINEID diff --git a/src/ui.attract.shr.a b/src/ui.attract.shr.a index 7f0bd8d3e..fac37298b 100644 --- a/src/ui.attract.shr.a +++ b/src/ui.attract.shr.a @@ -123,14 +123,12 @@ SHRArtworkCallback BlankSHR jsr Home - lda NEWVIDEO ; set GS NEWVIDEO mode to turn on linearize - ora #%01000000 ; can't use TSB here - might not be 65816 + lda #%01000001 ; set GS NEWVIDEO mode to turn on linearize sta NEWVIDEO sta WRITEAUXMEM ; writes go to auxmem - lda SHADOW ; enable auxmem-to-bank-E1 shadowing on IIgs - and #$F7 ; can't use TRB here - might not be 65816 + lda #$00 ; enable auxmem-to-bank-E1 shadowing on IIgs sta SHADOW lda #$20 ; clear $2000..$9FFF in auxmem @@ -139,8 +137,7 @@ BlankSHR sta WRITEMAINMEM ; writes go to main memory - lda NEWVIDEO ; set GS NEWVIDEO mode to turn on SHR mode - ora #%10000001 ; can't use TSB here - might not be 65816 + lda #%11000001 ; set GS NEWVIDEO mode to turn on SHR mode sta NEWVIDEO rts diff --git a/src/ui.common.a b/src/ui.common.a index 59ea601f6..b2198197d 100755 --- a/src/ui.common.a +++ b/src/ui.common.a @@ -22,11 +22,11 @@ Home lda MachineStatus and #SUPPORTS_SHR beq @noSHR - lda NEWVIDEO - and #%00011111 ; bit 7 = 0 -> IIgs Apple II-compatible video modes + lda #%00000001 ; bit 7 = 0 -> IIgs Apple II-compatible video modes ; bit 6 = 0 -> IIgs 128K memory map is the same as the Apple IIe ; bit 5 = 0 -> IIgs DHGR is color, not monochrome - ; bits 0-4 unchanged + ; bits 1-4 reserved + ; bit 0 = 1 -> disable bank latch sta NEWVIDEO lda #$F0 sta TBCOLOR ; white text on black background