diff --git a/demos/lovebyte2024/d2v/Makefile b/demos/lovebyte2024/d2v/Makefile index 598a3eee..4561b634 100644 --- a/demos/lovebyte2024/d2v/Makefile +++ b/demos/lovebyte2024/d2v/Makefile @@ -7,11 +7,12 @@ LINKERSCRIPTS = ../../../linker_scripts/ all: dont.dsk -dont.dsk: HELLO DONT DONT2 +dont.dsk: HELLO DONT DONT2 SA_ED cp $(EMPTYDISK) dont.dsk $(DOS33) -y dont.dsk SAVE A HELLO $(DOS33) -y dont.dsk BSAVE -a 0xc00 DONT $(DOS33) -y dont.dsk BSAVE -a 0xc00 DONT2 + $(DOS33) -y dont.dsk BSAVE -a 0xc00 SA_ED ### @@ -52,6 +53,15 @@ DONT2: dont2.o dont2.o: dont2.s still.s ca65 -o dont2.o dont2.s -l dont2.lst +### + +SA_ED: sa_ed.o + ld65 -o SA_ED sa_ed.o -C $(LINKERSCRIPTS)/apple2_c00.inc + +sa_ed.o: sa_ed.s duet.s + ca65 -o sa_ed.o sa_ed.s -l sa_ed.lst + + #### diff --git a/demos/lovebyte2024/d2v/dont2.s b/demos/lovebyte2024/d2v/dont2.s index ac3dec2b..5e9d753f 100644 --- a/demos/lovebyte2024/d2v/dont2.s +++ b/demos/lovebyte2024/d2v/dont2.s @@ -8,6 +8,7 @@ ; 135 bytes = more optimization ; zero page locations +CH = $24 GBASL = $26 GBASH = $27 H2 = $2C @@ -37,6 +38,7 @@ HOME = $FC58 ; Clear the text screen TEXT = $FB36 HLINE = $F819 ; HLINE Y,$2C at A VLINE = $F828 ; VLINE A,$2D at Y +TABV = $FB5B ; go to A HGR2 = $F3D8 diff --git a/demos/lovebyte2024/d2v/still.s b/demos/lovebyte2024/d2v/still.s index d777d922..3724a76c 100644 --- a/demos/lovebyte2024/d2v/still.s +++ b/demos/lovebyte2024/d2v/still.s @@ -46,7 +46,7 @@ still: lda #20 sta $20 ; left edge - sta $21 ; right edge + sta $21 ; width lda #2 sta $22 ; top edge @@ -61,7 +61,7 @@ still: ldy #0 opening_loop: lda (INL),Y - beq done_still + beq play_music ora #$80 jsr COUT1 iny @@ -70,6 +70,25 @@ opening_loop: ;=========================== ; play music and draw loop +play_music: + + + ;========================== + ; set screen for wrap again + + lda #1 + sta $20 ; left edge + lda #15 ; width + sta $21 + lda #2 + sta $22 ; top edge + lda #18 + sta $23 + + lda #2 + sta CH + jsr TABV + lda #music_data @@ -102,6 +121,16 @@ ahead: jmp play_tone done_tone: + lda #'@'|$80 + jsr COUT1 + lda #'@'|$80 + jsr COUT1 + lda #'@'|$80 + jsr COUT1 + lda #' '|$80 + jsr COUT1 + + ldy SAVEY jmp music_loop @@ -131,17 +160,8 @@ opening: ; F,D music_data: - .byte 85,54 - .byte 91,54 - .byte 102,54 - .byte 102,54 - .byte 91,54 + .byte 85,54, 91,54, 102,54, 102,54, 91,54, 1,54 + .byte 152,54, 85,54, 91,54, 102,54, 102,108, 91,54, 1,54 + .byte 114,108, 102,54, 152, 108, 1,108 .byte 0 -;80 T$="This ":D=54:F=85:GOSUB 8 -;82 T$="was ":F=91:GOSUB 8 -;84 T$="a ":F=102:GOSUB 8 -;86 T$="tri":GOSUB 8 -;89 T$="umph."+C$:F=91:GOSUB 8 -;90 FOR I=1 TO 800:NEXT -