double: add some text

This commit is contained in:
Vince Weaver 2023-05-09 22:24:01 -04:00
parent 335ad44c1a
commit bf32f928f9
5 changed files with 118 additions and 5 deletions

View File

@ -25,7 +25,7 @@ DOUBLE: double.o
double.o: double.s \
zp.inc hardware.inc pt3_lib_mockingboard_detect.s \
pt3_lib_mockingboard_setup.s pt3_lib_detect_model.s \
zx02_optim.s copy_400.s \
zx02_optim.s copy_400.s gr_offsets.s \
graphics/sworg_hgr.hgr.zx02 \
graphics/sworg_dhgr.aux.zx02 \
graphics/sworg_dhgr.bin.zx02 \

View File

@ -58,6 +58,93 @@ not_a_iigs:
jsr SETGR ; set lo-res 40x40 mode
bit LORES
;====================================================
; setup text page2 screen of "Apple II Forever" text
;====================================================
; there are much better ways to accomplish this
sta SETMOUSETEXT
ldy #0
ldx #0
sty XX
a24e_newy:
lda gr_offsets_l,Y
sta stringing_smc+1
lda gr_offsets_h,Y
clc
adc #4
sta stringing_smc+2
a24e_loop:
lda a2_string,X
bne keep_stringing
ldx #0
lda a2_string,X
keep_stringing:
inx
eor #$80
stringing_smc:
sta $d000
inc stringing_smc+1
inc XX
lda XX
cmp #40
bne a24e_loop
lda #0
sta XX
iny
cpy #24
bne a24e_newy
stringing_done:
.if 0
lda a2_string,X
eor #$80
sta $800,X
sta $880+1,X
sta $900+2,X
sta $980+3,X
sta $A00+4,X
sta $A80+5,X
sta $B00+6,X
sta $B80+7,X
sta $828+0,X
sta $8A8+1,X
sta $928+2,X
sta $9A8+3,X
sta $A28+4,X
sta $AA8+5,X
sta $B28+6,X
sta $BA8+7,X
sta $850+0,X
sta $8D0+1,X
sta $950+2,X
sta $9D0+3,X
sta $A50+4,X
sta $AD0+5,X
sta $B50+6,X
sta $BD0+7,X
dex
bpl a24e_loop
.endif
; set 80-store mode
sta EIGHTYSTOREON ; PAGE2 selects AUX memory
@ -166,10 +253,9 @@ double_loop:
; each line 65 cycles (25 hblank+40 bytes)
; 3 LINES 80-COL TEXT AN3=0 PAGE=1
; 3 LINES 80-COL TEXT AN3=0 PAGE=2
nop
nop
bit PAGE2
nop
nop
@ -181,7 +267,7 @@ double_loop:
jsr delay_1552
; 3 LINES 40-COL TEXT AN3=0 PAGE=1
; 3 LINES 40-COL TEXT AN3=0 PAGE=2
nop
nop
@ -339,3 +425,13 @@ image_dgr_aux:
.incbin "graphics/sworg_dgr.aux.zx02"
image_dgr_main:
.incbin "graphics/sworg_dgr.main.zx02"
a2_string:
; 012345678901234567 8 9
.byte "Apple II Forever!! ",'@'+$80," "
.byte "Apple II Forever! ",'@'+$80," ",0
.byte "Apple II Forever! ",'@'+$80," "
.byte "Apple II Forever! ",'@'+$80," "
.byte "Apple II Forever! ",'@'+$80," "
.include "gr_offsets.s"

View File

@ -0,0 +1,10 @@
gr_offsets_h:
.byte $4,$4,$5,$5,$6,$6,$7,$7
.byte $4,$4,$5,$5,$6,$6,$7,$7
.byte $4,$4,$5,$5,$6,$6,$7,$7
gr_offsets_l:
.byte $00,$80,$00,$80,$00,$80,$00,$80
.byte $28,$a8,$28,$a8,$28,$a8,$28,$a8
.byte $50,$d0,$50,$d0,$50,$d0,$50,$d0

View File

@ -6,6 +6,7 @@ EIGHTYSTOREOFF = $C000 ; Write (turns off 80store)
EIGHTYSTOREON = $C001 ; Write (page2 writes to AUX memory)
CLR80COL = $C00C
SET80COL = $C00D
SETMOUSETEXT = $C00F ; (write) enable mouse text
TBCOLOR = $C022 ; IIgs text foreground / background colors
CLOCKCTL = $C034 ; bits 0-3 are IIgs border color

View File

@ -21,6 +21,12 @@ APPLEII_MODEL = $8B
HGRPAGE = $E6
TEMPY = $F0
XX = $F1
INL = $F2
INH = $F3
MB_VALUE = $F5
MB_ADDR_L = $F6
MB_ADDR_H = $F7