mirror of
https://github.com/deater/dos33fsprogs.git
synced 2025-01-06 06:30:36 +00:00
demo: rename and optimize
This commit is contained in:
parent
485822d8d8
commit
123d684970
@ -6,14 +6,14 @@ EMPTYDISK = ../../empty_disk/empty.dsk
|
||||
PICTUREDSK = ~/research/picturedsk.git/picturedsk
|
||||
LINKER_SCRIPTS = ../../linker_scripts/
|
||||
|
||||
all: hgr_escape.dsk
|
||||
all: apple_desire.dsk
|
||||
|
||||
###
|
||||
|
||||
hgr_escape.dsk: HELLO ESCAPE
|
||||
cp $(EMPTYDISK) hgr_escape.dsk
|
||||
$(DOS33) -y hgr_escape.dsk SAVE A HELLO
|
||||
$(DOS33) -y hgr_escape.dsk BSAVE -a 0xc00 ESCAPE
|
||||
apple_desire.dsk: HELLO APPLE_DESIRE
|
||||
cp $(EMPTYDISK) apple_desire.dsk
|
||||
$(DOS33) -y apple_desire.dsk SAVE A HELLO
|
||||
$(DOS33) -y apple_desire.dsk BSAVE -a 0xc00 APPLE_DESIRE
|
||||
|
||||
###
|
||||
|
||||
@ -21,31 +21,31 @@ HELLO: hello.bas
|
||||
$(TOKENIZE) < hello.bas > HELLO
|
||||
|
||||
|
||||
#submit: escape512.zip
|
||||
#submit: apple_desire512.zip
|
||||
|
||||
#escape512.zip: ESCAPE escape.s file_id.diz escape_512.dsk
|
||||
# mkdir -p lovebyte2021_escape_512
|
||||
# cp ESCAPE ./lovebyte2021_escape_512
|
||||
# cp *.s ./lovebyte2021_escape_512
|
||||
# cp file_id.diz ./lovebyte2021_escape_512
|
||||
# cp escape_512.dsk ./lovebyte2021_escape_512
|
||||
# cp escape_512.woz ./lovebyte2021_escape_512
|
||||
# cp escape_720p.mp4 ./lovebyte2021_escape_512
|
||||
# cp desire2.png ./lovebyte2021_escape_512
|
||||
# zip -r escape512.zip lovebyte2021_escape_512
|
||||
#apple_desire512.zip: APPLE_DESIRE apple_desire.s file_id.diz apple_desire_512.dsk
|
||||
# mkdir -p lovebyte2021_apple_desire_512
|
||||
# cp APPLE_DESIRE ./lovebyte2021_apple_desire_512
|
||||
# cp *.s ./lovebyte2021_apple_desire_512
|
||||
# cp file_id.diz ./lovebyte2021_apple_desire_512
|
||||
# cp apple_desire_512.dsk ./lovebyte2021_apple_desire_512
|
||||
# cp apple_desire_512.woz ./lovebyte2021_apple_desire_512
|
||||
# cp apple_desire_720p.mp4 ./lovebyte2021_apple_desire_512
|
||||
# cp desire2.png ./lovebyte2021_apple_desire_512
|
||||
# zip -r apple_desire512.zip lovebyte2021_apple_desire_512
|
||||
|
||||
####
|
||||
|
||||
ESCAPE: escape.o
|
||||
ld65 -o ESCAPE escape.o -C $(LINKER_SCRIPTS)/apple2_c00.inc
|
||||
APPLE_DESIRE: apple_desire.o
|
||||
ld65 -o APPLE_DESIRE apple_desire.o -C $(LINKER_SCRIPTS)/apple2_c00.inc
|
||||
|
||||
escape.o: escape.s \
|
||||
apple_desire.o: apple_desire.s \
|
||||
logo_intro.s zp.inc \
|
||||
ay3_write_regs.s escape.s interrupt_handler.s \
|
||||
ay3_write_regs.s apple_desire.s interrupt_handler.s \
|
||||
play_frame.s draw_letter.s freq.s freq_h.s bamps.s \
|
||||
apple_logo.s \
|
||||
mA2E_4.s mockingboard_constants.s mockingboard_init.s tracker_init.s
|
||||
ca65 -o escape.o escape.s -l escape.lst
|
||||
ca65 -o apple_desire.o apple_desire.s -l apple_desire.lst
|
||||
|
||||
####
|
||||
|
||||
@ -58,5 +58,5 @@ make_points.o: make_points.c
|
||||
####
|
||||
|
||||
clean:
|
||||
rm -f *~ *.o *.lst ESCAPE *.zip make_points
|
||||
rm -f *~ *.o *.lst APPLE_DESIRE *.zip make_points
|
||||
|
||||
|
@ -10,13 +10,12 @@ draw_apple:
|
||||
sta HGR_SCALE
|
||||
|
||||
ldy #0
|
||||
ldx #70
|
||||
lda #60
|
||||
ldx #60
|
||||
txa
|
||||
; lda #60
|
||||
|
||||
jsr HPOSN ; set screen position to X= (y,x) Y=(a)
|
||||
|
||||
|
||||
|
||||
ldx #<apple_table ; point to bottom byte of shape address
|
||||
ldy #>apple_table ; point to top byte of shape address
|
||||
|
||||
|
@ -4,7 +4,9 @@
|
||||
; X has color
|
||||
|
||||
draw_logo:
|
||||
jsr HCOLOR1
|
||||
pha
|
||||
|
||||
jsr HCOLOR1 ; set color to X
|
||||
|
||||
ldx #5 ; draw 5 letters
|
||||
letter_time:
|
||||
@ -26,7 +28,9 @@ letter_time:
|
||||
|
||||
dex
|
||||
bpl letter_time
|
||||
rts
|
||||
|
||||
pla
|
||||
jmp draw_apple
|
||||
|
||||
|
||||
|
||||
@ -42,6 +46,10 @@ letter_time:
|
||||
draw_letter:
|
||||
sty LETTER_X ; store X-coord
|
||||
|
||||
lda LETTER_Y ; alternate up/down
|
||||
eor #$8
|
||||
sta LETTER_Y
|
||||
|
||||
ldy #$FF ; iterator
|
||||
letter_loop:
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
5 HOME
|
||||
10 PRINT " HGR ESCAPE -- A 1K BYTE APPLE II INTRO"
|
||||
15 PRINT " BY DEATER / DSR"
|
||||
10 PRINT "APPLE_DESIRE -- A 1K BYTE APPLE II INTRO"
|
||||
15 PRINT " BY DEATER & MA2E / DSR"
|
||||
20 PRINT CHR$(4)"CATALOG"
|
||||
25 PRINT:PRINT "PRESS ANY KEY TO 'BRUN ESCAPE'"
|
||||
25 PRINT:PRINT "PRESS ANY KEY TO 'BRUN APPLE_DESIRE'"
|
||||
30 GET A$
|
||||
35 PRINT
|
||||
40 PRINT CHR$(4)"BRUN ESCAPE"
|
||||
40 PRINT CHR$(4)"BRUN APPLE_DESIRE"
|
||||
|
||||
|
@ -20,7 +20,7 @@
|
||||
interrupt_handler:
|
||||
php ; save status flags
|
||||
cld ; clear decimal mode
|
||||
pha ; save A ; 3
|
||||
; pha ; save A ; 3
|
||||
; A is saved in $45 by firmware
|
||||
txa
|
||||
pha ; save X
|
||||
@ -47,7 +47,7 @@ done_ay3_irq_handler:
|
||||
tay ; restore Y
|
||||
pla
|
||||
tax ; restore X
|
||||
pla ; restore a ; 4
|
||||
; pla ; restore a ; 4
|
||||
|
||||
; on II+/IIe (but not IIc) we need to do this?
|
||||
interrupt_smc:
|
||||
|
@ -11,20 +11,20 @@
|
||||
|
||||
show_logo:
|
||||
|
||||
; 101 0000
|
||||
|
||||
lda #80
|
||||
sta LETTER_Y
|
||||
ldx #$7 ; color white
|
||||
lda #1 ; apple rotation
|
||||
jsr draw_logo
|
||||
lda #1
|
||||
jsr draw_apple
|
||||
|
||||
lda #$20
|
||||
lda #$20 ; switch HGR draw page
|
||||
sta HGR_PAGE
|
||||
|
||||
lda #72
|
||||
lda #88
|
||||
sta LETTER_Y
|
||||
ldx #$0 ; color black
|
||||
lda #63 ; apple rotation
|
||||
jsr draw_logo
|
||||
lda #63
|
||||
jsr draw_apple
|
||||
|
||||
|
@ -85,19 +85,8 @@ mockingboard_init:
|
||||
; NOTE: we don't support IIc as it's a hack
|
||||
; traditionally Mockingboard on IIc was rare
|
||||
|
||||
;========================
|
||||
; set up interrupt
|
||||
; Vector address goes to 0x3fe/0x3ff
|
||||
|
||||
; can save 10 bytes if we load in memory so this
|
||||
; is in the right place automatically
|
||||
|
||||
lda #<interrupt_handler ; 2
|
||||
sta $03fe ; 3
|
||||
lda #>interrupt_handler ; 2
|
||||
sta $03ff ; 3
|
||||
;=========
|
||||
; 10
|
||||
;=========================
|
||||
; Initialize the 6522s
|
||||
; Reset Left AY-3-8910
|
||||
@ -108,7 +97,7 @@ mockingboard_init:
|
||||
|
||||
; assume Y=0 on entry?
|
||||
|
||||
ldy #0 ; 2
|
||||
; ldy #0 ; 2
|
||||
init_it_loop:
|
||||
lda init_values,Y ; 3
|
||||
ldx init_addresses,Y ; 3
|
||||
@ -117,3 +106,15 @@ init_it_loop:
|
||||
sta $c400,X ; 3
|
||||
bne init_it_loop ; 2
|
||||
doneit:
|
||||
|
||||
;========================
|
||||
; set up interrupt
|
||||
; Vector address goes to 0x3fe/0x3ff
|
||||
|
||||
|
||||
lda #<interrupt_handler ; 2
|
||||
sta $03fe ; 3
|
||||
lda #>interrupt_handler ; 2
|
||||
sta $03ff ; 3
|
||||
;=========
|
||||
; 10
|
||||
|
Loading…
Reference in New Issue
Block a user