mirror of
https://github.com/deater/dos33fsprogs.git
synced 2024-09-10 08:54:51 +00:00
ds: move things off of $9000 so everything fits
BLURGH lots of hard-coded $9000s everywhere
This commit is contained in:
parent
226798be95
commit
3ef490be2d
@ -7,8 +7,8 @@ appleII_intro:
|
|||||||
|
|
||||||
;===================
|
;===================
|
||||||
; init screen
|
; init screen
|
||||||
jsr TEXT
|
; jsr TEXT
|
||||||
jsr HOME
|
; jsr HOME
|
||||||
bit KEYRESET
|
bit KEYRESET
|
||||||
|
|
||||||
;===================
|
;===================
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
; Autogenerates code that does interleaved Page0/Page1 lores mode
|
; Autogenerates code that does interleaved Page0/Page1 lores mode
|
||||||
; but leaving room for 14 pixels/line of per-scanline color
|
; but leaving room for 14 pixels/line of per-scanline color
|
||||||
|
|
||||||
UPDATE_START = $9000
|
UPDATE_START = $9800
|
||||||
|
|
||||||
DEFAULT_COLOR = $0
|
DEFAULT_COLOR = $0
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
; First 9 (?) lines = text mode
|
; First 9 (?) lines = text mode
|
||||||
;
|
;
|
||||||
|
|
||||||
UPDATE2_START = $9000
|
UPDATE2_START = $9800
|
||||||
|
|
||||||
;DEFAULT_COLOR = $0
|
;DEFAULT_COLOR = $0
|
||||||
|
|
||||||
@ -62,50 +62,50 @@ setup_update_type2:
|
|||||||
; add call to TEXT
|
; add call to TEXT
|
||||||
|
|
||||||
lda #$2c ; bit C051 ; 4
|
lda #$2c ; bit C051 ; 4
|
||||||
sta $9003
|
sta UPDATE2_START+3 ; $9003
|
||||||
lda #$51
|
lda #$51
|
||||||
sta $9004
|
sta UPDATE2_START+4 ; $9004
|
||||||
lda #$c0
|
lda #$c0
|
||||||
sta $9005
|
sta UPDATE2_START+5 ; $9005
|
||||||
|
|
||||||
lda #$A5 ; lda ZERO ; 3
|
lda #$A5 ; lda ZERO ; 3
|
||||||
sta $9006
|
sta UPDATE2_START+6 ; $9006
|
||||||
lda #$FA
|
lda #$FA
|
||||||
sta $9007
|
sta UPDATE2_START+7 ; $9007
|
||||||
|
|
||||||
lda #$A2 ; ldx, 1 ; 3
|
lda #$A2 ; ldx, 1 ; 3
|
||||||
sta $9008
|
sta UPDATE2_START+8 ; $9008
|
||||||
lda #$01
|
lda #$01
|
||||||
sta $9009
|
sta UPDATE2_START+9 ; $9009
|
||||||
|
|
||||||
; set first 9 lines to PAGE0
|
; set first 9 lines to PAGE0
|
||||||
|
|
||||||
lda #$54
|
lda #$54
|
||||||
sta $9030
|
sta UPDATE2_START+$30 ; $9030
|
||||||
sta $908E
|
sta UPDATE2_START+$8E ; $908E
|
||||||
sta $90EC
|
sta UPDATE2_START+$EC ; $90EC
|
||||||
sta $914A
|
sta UPDATE2_START+$14A ; $914A
|
||||||
|
|
||||||
|
|
||||||
; add call to GRAPHICS
|
; add call to GRAPHICS
|
||||||
; line 9 (91a7)
|
; line 9 (91a7)
|
||||||
|
|
||||||
lda #$2c ; bit C051 ; 4
|
lda #$2c ; bit C051 ; 4
|
||||||
sta $91aa
|
sta UPDATE2_START+$1aa ; $91aa
|
||||||
lda #$50
|
lda #$50
|
||||||
sta $91ab
|
sta UPDATE2_START+$1ab ; $91ab
|
||||||
lda #$c0
|
lda #$c0
|
||||||
sta $91ac
|
sta UPDATE2_START+$1ac ; $91ac
|
||||||
|
|
||||||
lda #$A5 ; lda ZERO ; 3
|
lda #$A5 ; lda ZERO ; 3
|
||||||
sta $91ad
|
sta UPDATE2_START+$1ad ; $91ad
|
||||||
lda #$FA
|
lda #$FA
|
||||||
sta $91ae
|
sta UPDATE2_START+$1ae ; $91ae
|
||||||
|
|
||||||
lda #$A2 ; ldx, 1 ; 3
|
lda #$A2 ; ldx, 1 ; 3
|
||||||
sta $91af
|
sta UPDATE2_START+$1af ; $91af
|
||||||
lda #$01
|
lda #$01
|
||||||
sta $91b0
|
sta UPDATE2_START+$1b0 ; $91b0
|
||||||
|
|
||||||
;====================
|
;====================
|
||||||
;====================
|
;====================
|
||||||
|
@ -8,8 +8,8 @@ credits:
|
|||||||
|
|
||||||
;===================
|
;===================
|
||||||
; init screen
|
; init screen
|
||||||
jsr TEXT
|
; jsr TEXT
|
||||||
jsr HOME
|
; jsr HOME
|
||||||
bit KEYRESET
|
bit KEYRESET
|
||||||
|
|
||||||
;===================
|
;===================
|
||||||
@ -37,24 +37,24 @@ credits:
|
|||||||
; 0 34 78 12 5 4 78 12 56 9
|
; 0 34 78 12 5 4 78 12 56 9
|
||||||
; 11 1 2 22 33 33 3
|
; 11 1 2 22 33 33 3
|
||||||
lda #$54
|
lda #$54
|
||||||
sta $9001+(49*3)
|
sta UPDATE_START+1+(49*3)
|
||||||
sta $9001+(49*7)
|
sta UPDATE_START+1+(49*7)
|
||||||
sta $9001+(49*11)
|
sta UPDATE_START+1+(49*11)
|
||||||
sta $9001+(49*15)
|
sta UPDATE_START+1+(49*15)
|
||||||
sta $9001+(49*27)
|
sta UPDATE_START+1+(49*27)
|
||||||
sta $9001+(49*31)
|
sta UPDATE_START+1+(49*31)
|
||||||
sta $9001+(49*35)
|
sta UPDATE_START+1+(49*35)
|
||||||
sta $9001+(49*39)
|
sta UPDATE_START+1+(49*39)
|
||||||
|
|
||||||
lda #$55
|
lda #$55
|
||||||
sta $9001+(49*0)
|
sta UPDATE_START+1+(49*0)
|
||||||
sta $9001+(49*4)
|
sta UPDATE_START+1+(49*4)
|
||||||
sta $9001+(49*8)
|
sta UPDATE_START+1+(49*8)
|
||||||
sta $9001+(49*12)
|
sta UPDATE_START+1+(49*12)
|
||||||
sta $9001+(49*24)
|
sta UPDATE_START+1+(49*24)
|
||||||
sta $9001+(49*28)
|
sta UPDATE_START+1+(49*28)
|
||||||
sta $9001+(49*32)
|
sta UPDATE_START+1+(49*32)
|
||||||
sta $9001+(49*36)
|
sta UPDATE_START+1+(49*36)
|
||||||
|
|
||||||
|
|
||||||
;=============================
|
;=============================
|
||||||
@ -158,7 +158,7 @@ tloopB: dex ; 2
|
|||||||
|
|
||||||
credits_loop:
|
credits_loop:
|
||||||
|
|
||||||
jsr $9000
|
jsr $9800
|
||||||
|
|
||||||
;======================================================
|
;======================================================
|
||||||
; We have 4550 cycles in the vblank, use them wisely
|
; We have 4550 cycles in the vblank, use them wisely
|
||||||
|
@ -18,14 +18,21 @@ demosplash2019:
|
|||||||
jsr clear_ay_both
|
jsr clear_ay_both
|
||||||
jsr pt3_init_song
|
jsr pt3_init_song
|
||||||
|
|
||||||
|
;====================================
|
||||||
|
; turn on language card
|
||||||
|
; enable read/write, use 1st 4k bank
|
||||||
|
; lda $C08B
|
||||||
|
; lda $C08B
|
||||||
|
|
||||||
;====================================
|
;====================================
|
||||||
; generate 4 patterns worth of music
|
; generate 4 patterns worth of music
|
||||||
; at address $9000
|
; at address $D000-$FC00
|
||||||
|
|
||||||
|
; page offset
|
||||||
lda #0
|
lda #0
|
||||||
sta FRAME_PAGE
|
sta FRAME_PAGE
|
||||||
|
|
||||||
|
; offset within page
|
||||||
lda #0
|
lda #0
|
||||||
sta FRAME_OFFSET
|
sta FRAME_OFFSET
|
||||||
|
|
||||||
@ -35,27 +42,64 @@ frame_decode_loop:
|
|||||||
jsr pt3_write_frame
|
jsr pt3_write_frame
|
||||||
|
|
||||||
inc FRAME_OFFSET
|
inc FRAME_OFFSET
|
||||||
|
|
||||||
|
lda FRAME_OFFSET
|
||||||
|
cmp #59 ; FIXME: make this depend on song
|
||||||
|
; hardcoding for 59 for our song
|
||||||
bne frame_decode_loop
|
bne frame_decode_loop
|
||||||
|
|
||||||
inc r0_wrsmc+2 ; 6
|
; add 11 to all of the output pointers
|
||||||
inc r1_wrsmc+2 ; 6
|
.if 0
|
||||||
inc r2_wrsmc+2 ; 6
|
clc
|
||||||
inc r4_wrsmc+2 ; 6
|
lda r0_wrsmc+2
|
||||||
inc r13_wrsmc+2 ; 6
|
adc #$b
|
||||||
inc r6_wrsmc+2 ; 6
|
sta r0_wrsmc+2
|
||||||
inc r7_wrsmc+2 ; 6
|
|
||||||
inc r8_wrsmc+2 ; 6
|
|
||||||
inc r9_wrsmc+2 ; 6
|
|
||||||
inc r11_wrsmc+2 ; 6
|
|
||||||
inc r12_wrsmc+2 ; 6
|
|
||||||
|
|
||||||
|
lda r1_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r1_wrsmc+2
|
||||||
|
|
||||||
|
lda r2_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r2_wrsmc+2
|
||||||
|
|
||||||
|
lda r4_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r4_wrsmc+2
|
||||||
|
|
||||||
|
lda r13_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r13_wrsmc+2
|
||||||
|
|
||||||
|
lda r6_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r6_wrsmc+2
|
||||||
|
|
||||||
|
lda r7_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r7_wrsmc+2
|
||||||
|
|
||||||
|
lda r8_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r8_wrsmc+2
|
||||||
|
|
||||||
|
lda r9_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r9_wrsmc+2
|
||||||
|
|
||||||
|
lda r11_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r11_wrsmc+2
|
||||||
|
|
||||||
|
lda r12_wrsmc+2
|
||||||
|
adc #$b
|
||||||
|
sta r12_wrsmc+2
|
||||||
|
.endif
|
||||||
|
|
||||||
inc FRAME_PAGE
|
inc FRAME_PAGE
|
||||||
lda FRAME_PAGE
|
lda FRAME_PAGE
|
||||||
|
|
||||||
|
cmp #4
|
||||||
|
|
||||||
cmp #3
|
|
||||||
bne frame_decode_loop
|
bne frame_decode_loop
|
||||||
|
|
||||||
lda #0
|
lda #0
|
||||||
@ -113,7 +157,8 @@ frame_decode_loop:
|
|||||||
; start irq music
|
; start irq music
|
||||||
;========================
|
;========================
|
||||||
|
|
||||||
cli ; enable interrupts
|
nop
|
||||||
|
; cli ; enable interrupts
|
||||||
|
|
||||||
;===========================
|
;===========================
|
||||||
; opening book scene
|
; opening book scene
|
||||||
|
@ -9,8 +9,8 @@ escape:
|
|||||||
|
|
||||||
;===================
|
;===================
|
||||||
; init screen
|
; init screen
|
||||||
jsr TEXT
|
; jsr TEXT
|
||||||
jsr HOME
|
; jsr HOME
|
||||||
bit KEYRESET
|
bit KEYRESET
|
||||||
|
|
||||||
;===================
|
;===================
|
||||||
@ -173,7 +173,7 @@ loopRR: dex ; 2
|
|||||||
|
|
||||||
sprites_display_loop:
|
sprites_display_loop:
|
||||||
|
|
||||||
jsr $9000
|
jsr $9800
|
||||||
;.include "sprites_screen.s"
|
;.include "sprites_screen.s"
|
||||||
|
|
||||||
;======================================================
|
;======================================================
|
||||||
@ -1540,8 +1540,6 @@ escape_keys:
|
|||||||
.byte ' '+$80,30
|
.byte ' '+$80,30
|
||||||
.byte 27+$80,2
|
.byte 27+$80,2
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
escape_keys_after:
|
escape_keys_after:
|
||||||
|
|
||||||
.assert >escape_keys_before = >escape_keys_after, error, "keys crosses page"
|
.assert >escape_keys_before = >escape_keys_after, error, "keys crosses page"
|
||||||
|
@ -6,6 +6,8 @@
|
|||||||
//#define START 40
|
//#define START 40
|
||||||
#define START 48
|
#define START 48
|
||||||
|
|
||||||
|
#define OFFSET 0x9800
|
||||||
|
|
||||||
int main(int argc, char **argv) {
|
int main(int argc, char **argv) {
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
@ -15,7 +17,7 @@ int main(int argc, char **argv) {
|
|||||||
for(i=0;i<NUMBER;i++) {
|
for(i=0;i<NUMBER;i++) {
|
||||||
if (i%8==0) printf(".byte\t");
|
if (i%8==0) printf(".byte\t");
|
||||||
//printf(">(smc%3d+1)",i+START);
|
//printf(">(smc%3d+1)",i+START);
|
||||||
printf(">($%4X)",0x9000+(i+START)*49+4);
|
printf(">($%4X)",OFFSET+(i+START)*49+4);
|
||||||
if (i%8!=7) printf(",");
|
if (i%8!=7) printf(",");
|
||||||
else printf("\n");
|
else printf("\n");
|
||||||
}
|
}
|
||||||
@ -23,7 +25,7 @@ int main(int argc, char **argv) {
|
|||||||
for(i=0;i<NUMBER;i++) {
|
for(i=0;i<NUMBER;i++) {
|
||||||
if (i%8==0) printf(".byte\t");
|
if (i%8==0) printf(".byte\t");
|
||||||
//printf("<(smc%3d+1)",i+START);
|
//printf("<(smc%3d+1)",i+START);
|
||||||
printf("<($%4X)",0x9000+(i+START)*49+4);
|
printf("<($%4X)",OFFSET+(i+START)*49+4);
|
||||||
if (i%8!=7) printf(",");
|
if (i%8!=7) printf(",");
|
||||||
else printf("\n");
|
else printf("\n");
|
||||||
}
|
}
|
||||||
|
@ -6,6 +6,8 @@
|
|||||||
//#define START 40
|
//#define START 40
|
||||||
//#define START 48
|
//#define START 48
|
||||||
|
|
||||||
|
#define OFFSET 0x9800
|
||||||
|
|
||||||
int main(int argc, char **argv) {
|
int main(int argc, char **argv) {
|
||||||
|
|
||||||
int i;
|
int i;
|
||||||
@ -15,7 +17,7 @@ int main(int argc, char **argv) {
|
|||||||
for(i=0;i<NUMBER;i++) {
|
for(i=0;i<NUMBER;i++) {
|
||||||
if (i%8==0) printf(".byte\t");
|
if (i%8==0) printf(".byte\t");
|
||||||
//printf(">(smc%3d+1)",i+START);
|
//printf(">(smc%3d+1)",i+START);
|
||||||
printf(">($%4X)",0x9000+(i+START)*47+4);
|
printf(">($%4X)",OFFSET+(i+START)*47+4);
|
||||||
if (i%8!=7) printf(",");
|
if (i%8!=7) printf(",");
|
||||||
else printf("\n");
|
else printf("\n");
|
||||||
}
|
}
|
||||||
@ -23,7 +25,7 @@ int main(int argc, char **argv) {
|
|||||||
for(i=0;i<NUMBER;i++) {
|
for(i=0;i<NUMBER;i++) {
|
||||||
if (i%8==0) printf(".byte\t");
|
if (i%8==0) printf(".byte\t");
|
||||||
//printf("<(smc%3d+1)",i+START);
|
//printf("<(smc%3d+1)",i+START);
|
||||||
printf("<($%4X)",0x9000+(i+START)*47+4);
|
printf("<($%4X)",OFFSET+(i+START)*47+4);
|
||||||
if (i%8!=7) printf(",");
|
if (i%8!=7) printf(",");
|
||||||
else printf("\n");
|
else printf("\n");
|
||||||
}
|
}
|
||||||
|
@ -23,28 +23,32 @@ PADDLE_BUTTON0 = $C061
|
|||||||
PADDL0 = $C064
|
PADDL0 = $C064
|
||||||
PTRIG = $C070
|
PTRIG = $C070
|
||||||
|
|
||||||
|
; Language card
|
||||||
|
; C080
|
||||||
|
; C08B
|
||||||
|
|
||||||
;; BASIC ROUTINES
|
;; BASIC ROUTINES
|
||||||
|
|
||||||
NORMAL = $F273
|
;NORMAL = $F273
|
||||||
|
|
||||||
;; MONITOR ROUTINES
|
;; MONITOR ROUTINES
|
||||||
|
|
||||||
HLINE = $F819 ;; HLINE Y,$2C at A
|
;HLINE = $F819 ;; HLINE Y,$2C at A
|
||||||
VLINE = $F828 ;; VLINE A,$2D at Y
|
;VLINE = $F828 ;; VLINE A,$2D at Y
|
||||||
CLRSCR = $F832 ;; Clear low-res screen
|
;CLRSCR = $F832 ;; Clear low-res screen
|
||||||
CLRTOP = $F836 ;; clear only top of low-res screen
|
;CLRTOP = $F836 ;; clear only top of low-res screen
|
||||||
SETCOL = $F864 ;; COLOR=A
|
;SETCOL = $F864 ;; COLOR=A
|
||||||
TEXT = $FB36
|
;TEXT = $FB36
|
||||||
TABV = $FB5B ;; VTAB to A
|
;TABV = $FB5B ;; VTAB to A
|
||||||
BELL = $FBDD ;; ring the bell
|
;BELL = $FBDD ;; ring the bell
|
||||||
BASCALC = $FBC1 ;;
|
;BASCALC= $FBC1 ;;
|
||||||
VTAB = $FC22 ;; VTAB to CV
|
;VTAB = $FC22 ;; VTAB to CV
|
||||||
HOME = $FC58 ;; Clear the text screen
|
;HOME = $FC58 ;; Clear the text screen
|
||||||
WAIT = $FCA8 ;; delay 1/2(26+27A+5A^2) us
|
;WAIT = $FCA8 ;; delay 1/2(26+27A+5A^2) us
|
||||||
SETINV = $FE80 ;; INVERSE
|
;SETINV = $FE80 ;; INVERSE
|
||||||
SETNORM = $FE84 ;; NORMAL
|
;SETNORM= $FE84 ;; NORMAL
|
||||||
COUT = $FDED ;; output A to screen
|
;COUT = $FDED ;; output A to screen
|
||||||
COUT1 = $FDF0 ;; output A to screen
|
;COUT1 = $FDF0 ;; output A to screen
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -8,8 +8,8 @@ missing_intro:
|
|||||||
|
|
||||||
;===================
|
;===================
|
||||||
; init screen
|
; init screen
|
||||||
jsr TEXT
|
; jsr TEXT
|
||||||
jsr HOME
|
; jsr HOME
|
||||||
bit KEYRESET
|
bit KEYRESET
|
||||||
|
|
||||||
;===================
|
;===================
|
||||||
@ -135,7 +135,7 @@ mloopB: dex ; 2
|
|||||||
|
|
||||||
missing_display_loop:
|
missing_display_loop:
|
||||||
|
|
||||||
jsr $9000 ; update_type1
|
jsr $9800 ; update_type1
|
||||||
;.include "missing_screen_update.s"
|
;.include "missing_screen_update.s"
|
||||||
|
|
||||||
;======================================================
|
;======================================================
|
||||||
|
@ -1,34 +1,34 @@
|
|||||||
y_lookup_h:
|
y_lookup_h:
|
||||||
.byte >($9934),>($9965),>($9996),>($99C7),>($99F8),>($9A29),>($9A5A),>($9A8B)
|
.byte >($A134),>($A165),>($A196),>($A1C7),>($A1F8),>($A229),>($A25A),>($A28B)
|
||||||
.byte >($9ABC),>($9AED),>($9B1E),>($9B4F),>($9B80),>($9BB1),>($9BE2),>($9C13)
|
.byte >($A2BC),>($A2ED),>($A31E),>($A34F),>($A380),>($A3B1),>($A3E2),>($A413)
|
||||||
.byte >($9C44),>($9C75),>($9CA6),>($9CD7),>($9D08),>($9D39),>($9D6A),>($9D9B)
|
.byte >($A444),>($A475),>($A4A6),>($A4D7),>($A508),>($A539),>($A56A),>($A59B)
|
||||||
.byte >($9DCC),>($9DFD),>($9E2E),>($9E5F),>($9E90),>($9EC1),>($9EF2),>($9F23)
|
.byte >($A5CC),>($A5FD),>($A62E),>($A65F),>($A690),>($A6C1),>($A6F2),>($A723)
|
||||||
.byte >($9F54),>($9F85),>($9FB6),>($9FE7),>($A018),>($A049),>($A07A),>($A0AB)
|
.byte >($A754),>($A785),>($A7B6),>($A7E7),>($A818),>($A849),>($A87A),>($A8AB)
|
||||||
.byte >($A0DC),>($A10D),>($A13E),>($A16F),>($A1A0),>($A1D1),>($A202),>($A233)
|
.byte >($A8DC),>($A90D),>($A93E),>($A96F),>($A9A0),>($A9D1),>($AA02),>($AA33)
|
||||||
.byte >($A264),>($A295),>($A2C6),>($A2F7),>($A328),>($A359),>($A38A),>($A3BB)
|
.byte >($AA64),>($AA95),>($AAC6),>($AAF7),>($AB28),>($AB59),>($AB8A),>($ABBB)
|
||||||
.byte >($A3EC),>($A41D),>($A44E),>($A47F),>($A4B0),>($A4E1),>($A512),>($A543)
|
.byte >($ABEC),>($AC1D),>($AC4E),>($AC7F),>($ACB0),>($ACE1),>($AD12),>($AD43)
|
||||||
.byte >($A574),>($A5A5),>($A5D6),>($A607),>($A638),>($A669),>($A69A),>($A6CB)
|
.byte >($AD74),>($ADA5),>($ADD6),>($AE07),>($AE38),>($AE69),>($AE9A),>($AECB)
|
||||||
.byte >($A6FC),>($A72D),>($A75E),>($A78F),>($A7C0),>($A7F1),>($A822),>($A853)
|
.byte >($AEFC),>($AF2D),>($AF5E),>($AF8F),>($AFC0),>($AFF1),>($B022),>($B053)
|
||||||
.byte >($A884),>($A8B5),>($A8E6),>($A917),>($A948),>($A979),>($A9AA),>($A9DB)
|
.byte >($B084),>($B0B5),>($B0E6),>($B117),>($B148),>($B179),>($B1AA),>($B1DB)
|
||||||
.byte >($AA0C),>($AA3D),>($AA6E),>($AA9F),>($AAD0),>($AB01),>($AB32),>($AB63)
|
.byte >($B20C),>($B23D),>($B26E),>($B29F),>($B2D0),>($B301),>($B332),>($B363)
|
||||||
.byte >($AB94),>($ABC5),>($ABF6),>($AC27),>($AC58),>($AC89),>($ACBA),>($ACEB)
|
.byte >($B394),>($B3C5),>($B3F6),>($B427),>($B458),>($B489),>($B4BA),>($B4EB)
|
||||||
.byte >($AD1C),>($AD4D),>($AD7E),>($ADAF),>($ADE0),>($AE11),>($AE42),>($AE73)
|
.byte >($B51C),>($B54D),>($B57E),>($B5AF),>($B5E0),>($B611),>($B642),>($B673)
|
||||||
.byte >($AEA4),>($AED5),>($AF06),>($AF37),>($AF68),>($AF99),>($AFCA),>($AFFB)
|
.byte >($B6A4),>($B6D5),>($B706),>($B737),>($B768),>($B799),>($B7CA),>($B7FB)
|
||||||
.byte >($B02C),>($B05D),>($B08E),>($B0BF),>($B0F0),>($B121),>($B152),>($B183)
|
.byte >($B82C),>($B85D),>($B88E),>($B8BF),>($B8F0),>($B921),>($B952),>($B983)
|
||||||
y_lookup_l:
|
y_lookup_l:
|
||||||
.byte <($9934),<($9965),<($9996),<($99C7),<($99F8),<($9A29),<($9A5A),<($9A8B)
|
.byte <($A134),<($A165),<($A196),<($A1C7),<($A1F8),<($A229),<($A25A),<($A28B)
|
||||||
.byte <($9ABC),<($9AED),<($9B1E),<($9B4F),<($9B80),<($9BB1),<($9BE2),<($9C13)
|
.byte <($A2BC),<($A2ED),<($A31E),<($A34F),<($A380),<($A3B1),<($A3E2),<($A413)
|
||||||
.byte <($9C44),<($9C75),<($9CA6),<($9CD7),<($9D08),<($9D39),<($9D6A),<($9D9B)
|
.byte <($A444),<($A475),<($A4A6),<($A4D7),<($A508),<($A539),<($A56A),<($A59B)
|
||||||
.byte <($9DCC),<($9DFD),<($9E2E),<($9E5F),<($9E90),<($9EC1),<($9EF2),<($9F23)
|
.byte <($A5CC),<($A5FD),<($A62E),<($A65F),<($A690),<($A6C1),<($A6F2),<($A723)
|
||||||
.byte <($9F54),<($9F85),<($9FB6),<($9FE7),<($A018),<($A049),<($A07A),<($A0AB)
|
.byte <($A754),<($A785),<($A7B6),<($A7E7),<($A818),<($A849),<($A87A),<($A8AB)
|
||||||
.byte <($A0DC),<($A10D),<($A13E),<($A16F),<($A1A0),<($A1D1),<($A202),<($A233)
|
.byte <($A8DC),<($A90D),<($A93E),<($A96F),<($A9A0),<($A9D1),<($AA02),<($AA33)
|
||||||
.byte <($A264),<($A295),<($A2C6),<($A2F7),<($A328),<($A359),<($A38A),<($A3BB)
|
.byte <($AA64),<($AA95),<($AAC6),<($AAF7),<($AB28),<($AB59),<($AB8A),<($ABBB)
|
||||||
.byte <($A3EC),<($A41D),<($A44E),<($A47F),<($A4B0),<($A4E1),<($A512),<($A543)
|
.byte <($ABEC),<($AC1D),<($AC4E),<($AC7F),<($ACB0),<($ACE1),<($AD12),<($AD43)
|
||||||
.byte <($A574),<($A5A5),<($A5D6),<($A607),<($A638),<($A669),<($A69A),<($A6CB)
|
.byte <($AD74),<($ADA5),<($ADD6),<($AE07),<($AE38),<($AE69),<($AE9A),<($AECB)
|
||||||
.byte <($A6FC),<($A72D),<($A75E),<($A78F),<($A7C0),<($A7F1),<($A822),<($A853)
|
.byte <($AEFC),<($AF2D),<($AF5E),<($AF8F),<($AFC0),<($AFF1),<($B022),<($B053)
|
||||||
.byte <($A884),<($A8B5),<($A8E6),<($A917),<($A948),<($A979),<($A9AA),<($A9DB)
|
.byte <($B084),<($B0B5),<($B0E6),<($B117),<($B148),<($B179),<($B1AA),<($B1DB)
|
||||||
.byte <($AA0C),<($AA3D),<($AA6E),<($AA9F),<($AAD0),<($AB01),<($AB32),<($AB63)
|
.byte <($B20C),<($B23D),<($B26E),<($B29F),<($B2D0),<($B301),<($B332),<($B363)
|
||||||
.byte <($AB94),<($ABC5),<($ABF6),<($AC27),<($AC58),<($AC89),<($ACBA),<($ACEB)
|
.byte <($B394),<($B3C5),<($B3F6),<($B427),<($B458),<($B489),<($B4BA),<($B4EB)
|
||||||
.byte <($AD1C),<($AD4D),<($AD7E),<($ADAF),<($ADE0),<($AE11),<($AE42),<($AE73)
|
.byte <($B51C),<($B54D),<($B57E),<($B5AF),<($B5E0),<($B611),<($B642),<($B673)
|
||||||
.byte <($AEA4),<($AED5),<($AF06),<($AF37),<($AF68),<($AF99),<($AFCA),<($AFFB)
|
.byte <($B6A4),<($B6D5),<($B706),<($B737),<($B768),<($B799),<($B7CA),<($B7FB)
|
||||||
.byte <($B02C),<($B05D),<($B08E),<($B0BF),<($B0F0),<($B121),<($B152),<($B183)
|
.byte <($B82C),<($B85D),<($B88E),<($B8BF),<($B8F0),<($B921),<($B952),<($B983)
|
||||||
|
@ -1,34 +1,34 @@
|
|||||||
y_lookup2_h:
|
y_lookup2_h:
|
||||||
.byte >($95E4),>($9613),>($9642),>($9671),>($96A0),>($96CF),>($96FE),>($972D)
|
.byte >($9DE4),>($9E13),>($9E42),>($9E71),>($9EA0),>($9ECF),>($9EFE),>($9F2D)
|
||||||
.byte >($975C),>($978B),>($97BA),>($97E9),>($9818),>($9847),>($9876),>($98A5)
|
.byte >($9F5C),>($9F8B),>($9FBA),>($9FE9),>($A018),>($A047),>($A076),>($A0A5)
|
||||||
.byte >($98D4),>($9903),>($9932),>($9961),>($9990),>($99BF),>($99EE),>($9A1D)
|
.byte >($A0D4),>($A103),>($A132),>($A161),>($A190),>($A1BF),>($A1EE),>($A21D)
|
||||||
.byte >($9A4C),>($9A7B),>($9AAA),>($9AD9),>($9B08),>($9B37),>($9B66),>($9B95)
|
.byte >($A24C),>($A27B),>($A2AA),>($A2D9),>($A308),>($A337),>($A366),>($A395)
|
||||||
.byte >($9BC4),>($9BF3),>($9C22),>($9C51),>($9C80),>($9CAF),>($9CDE),>($9D0D)
|
.byte >($A3C4),>($A3F3),>($A422),>($A451),>($A480),>($A4AF),>($A4DE),>($A50D)
|
||||||
.byte >($9D3C),>($9D6B),>($9D9A),>($9DC9),>($9DF8),>($9E27),>($9E56),>($9E85)
|
.byte >($A53C),>($A56B),>($A59A),>($A5C9),>($A5F8),>($A627),>($A656),>($A685)
|
||||||
.byte >($9EB4),>($9EE3),>($9F12),>($9F41),>($9F70),>($9F9F),>($9FCE),>($9FFD)
|
.byte >($A6B4),>($A6E3),>($A712),>($A741),>($A770),>($A79F),>($A7CE),>($A7FD)
|
||||||
.byte >($A02C),>($A05B),>($A08A),>($A0B9),>($A0E8),>($A117),>($A146),>($A175)
|
.byte >($A82C),>($A85B),>($A88A),>($A8B9),>($A8E8),>($A917),>($A946),>($A975)
|
||||||
.byte >($A1A4),>($A1D3),>($A202),>($A231),>($A260),>($A28F),>($A2BE),>($A2ED)
|
.byte >($A9A4),>($A9D3),>($AA02),>($AA31),>($AA60),>($AA8F),>($AABE),>($AAED)
|
||||||
.byte >($A31C),>($A34B),>($A37A),>($A3A9),>($A3D8),>($A407),>($A436),>($A465)
|
.byte >($AB1C),>($AB4B),>($AB7A),>($ABA9),>($ABD8),>($AC07),>($AC36),>($AC65)
|
||||||
.byte >($A494),>($A4C3),>($A4F2),>($A521),>($A550),>($A57F),>($A5AE),>($A5DD)
|
.byte >($AC94),>($ACC3),>($ACF2),>($AD21),>($AD50),>($AD7F),>($ADAE),>($ADDD)
|
||||||
.byte >($A60C),>($A63B),>($A66A),>($A699),>($A6C8),>($A6F7),>($A726),>($A755)
|
.byte >($AE0C),>($AE3B),>($AE6A),>($AE99),>($AEC8),>($AEF7),>($AF26),>($AF55)
|
||||||
.byte >($A784),>($A7B3),>($A7E2),>($A811),>($A840),>($A86F),>($A89E),>($A8CD)
|
.byte >($AF84),>($AFB3),>($AFE2),>($B011),>($B040),>($B06F),>($B09E),>($B0CD)
|
||||||
.byte >($A8FC),>($A92B),>($A95A),>($A989),>($A9B8),>($A9E7),>($AA16),>($AA45)
|
.byte >($B0FC),>($B12B),>($B15A),>($B189),>($B1B8),>($B1E7),>($B216),>($B245)
|
||||||
.byte >($AA74),>($AAA3),>($AAD2),>($AB01),>($AB30),>($AB5F),>($AB8E),>($ABBD)
|
.byte >($B274),>($B2A3),>($B2D2),>($B301),>($B330),>($B35F),>($B38E),>($B3BD)
|
||||||
.byte >($ABEC),>($AC1B),>($AC4A),>($AC79),>($ACA8),>($ACD7),>($AD06),>($AD35)
|
.byte >($B3EC),>($B41B),>($B44A),>($B479),>($B4A8),>($B4D7),>($B506),>($B535)
|
||||||
y_lookup2_l:
|
y_lookup2_l:
|
||||||
.byte <($95E4),<($9613),<($9642),<($9671),<($96A0),<($96CF),<($96FE),<($972D)
|
.byte <($9DE4),<($9E13),<($9E42),<($9E71),<($9EA0),<($9ECF),<($9EFE),<($9F2D)
|
||||||
.byte <($975C),<($978B),<($97BA),<($97E9),<($9818),<($9847),<($9876),<($98A5)
|
.byte <($9F5C),<($9F8B),<($9FBA),<($9FE9),<($A018),<($A047),<($A076),<($A0A5)
|
||||||
.byte <($98D4),<($9903),<($9932),<($9961),<($9990),<($99BF),<($99EE),<($9A1D)
|
.byte <($A0D4),<($A103),<($A132),<($A161),<($A190),<($A1BF),<($A1EE),<($A21D)
|
||||||
.byte <($9A4C),<($9A7B),<($9AAA),<($9AD9),<($9B08),<($9B37),<($9B66),<($9B95)
|
.byte <($A24C),<($A27B),<($A2AA),<($A2D9),<($A308),<($A337),<($A366),<($A395)
|
||||||
.byte <($9BC4),<($9BF3),<($9C22),<($9C51),<($9C80),<($9CAF),<($9CDE),<($9D0D)
|
.byte <($A3C4),<($A3F3),<($A422),<($A451),<($A480),<($A4AF),<($A4DE),<($A50D)
|
||||||
.byte <($9D3C),<($9D6B),<($9D9A),<($9DC9),<($9DF8),<($9E27),<($9E56),<($9E85)
|
.byte <($A53C),<($A56B),<($A59A),<($A5C9),<($A5F8),<($A627),<($A656),<($A685)
|
||||||
.byte <($9EB4),<($9EE3),<($9F12),<($9F41),<($9F70),<($9F9F),<($9FCE),<($9FFD)
|
.byte <($A6B4),<($A6E3),<($A712),<($A741),<($A770),<($A79F),<($A7CE),<($A7FD)
|
||||||
.byte <($A02C),<($A05B),<($A08A),<($A0B9),<($A0E8),<($A117),<($A146),<($A175)
|
.byte <($A82C),<($A85B),<($A88A),<($A8B9),<($A8E8),<($A917),<($A946),<($A975)
|
||||||
.byte <($A1A4),<($A1D3),<($A202),<($A231),<($A260),<($A28F),<($A2BE),<($A2ED)
|
.byte <($A9A4),<($A9D3),<($AA02),<($AA31),<($AA60),<($AA8F),<($AABE),<($AAED)
|
||||||
.byte <($A31C),<($A34B),<($A37A),<($A3A9),<($A3D8),<($A407),<($A436),<($A465)
|
.byte <($AB1C),<($AB4B),<($AB7A),<($ABA9),<($ABD8),<($AC07),<($AC36),<($AC65)
|
||||||
.byte <($A494),<($A4C3),<($A4F2),<($A521),<($A550),<($A57F),<($A5AE),<($A5DD)
|
.byte <($AC94),<($ACC3),<($ACF2),<($AD21),<($AD50),<($AD7F),<($ADAE),<($ADDD)
|
||||||
.byte <($A60C),<($A63B),<($A66A),<($A699),<($A6C8),<($A6F7),<($A726),<($A755)
|
.byte <($AE0C),<($AE3B),<($AE6A),<($AE99),<($AEC8),<($AEF7),<($AF26),<($AF55)
|
||||||
.byte <($A784),<($A7B3),<($A7E2),<($A811),<($A840),<($A86F),<($A89E),<($A8CD)
|
.byte <($AF84),<($AFB3),<($AFE2),<($B011),<($B040),<($B06F),<($B09E),<($B0CD)
|
||||||
.byte <($A8FC),<($A92B),<($A95A),<($A989),<($A9B8),<($A9E7),<($AA16),<($AA45)
|
.byte <($B0FC),<($B12B),<($B15A),<($B189),<($B1B8),<($B1E7),<($B216),<($B245)
|
||||||
.byte <($AA74),<($AAA3),<($AAD2),<($AB01),<($AB30),<($AB5F),<($AB8E),<($ABBD)
|
.byte <($B274),<($B2A3),<($B2D2),<($B301),<($B330),<($B35F),<($B38E),<($B3BD)
|
||||||
.byte <($ABEC),<($AC1B),<($AC4A),<($AC79),<($ACA8),<($ACD7),<($AD06),<($AD35)
|
.byte <($B3EC),<($B41B),<($B44A),<($B479),<($B4A8),<($B4D7),<($B506),<($B535)
|
||||||
|
@ -1,17 +1,17 @@
|
|||||||
; ZZ points to offset from pointer
|
; ZZ points to offset from pointer
|
||||||
|
|
||||||
|
|
||||||
;0 $9000,$9100,$9200 = A Low (reg0)
|
;D000 ;0 $9000,$9100,$9200 = A Low (reg0)
|
||||||
;1 $9300,$9400,$9500 = A high (reg1) [top], B high (reg3) [bottom]
|
;D100 ;1 $9300,$9400,$9500 = A high (reg1) [top], B high (reg3) [bottom]
|
||||||
;2 $9600,$9700,$9800 = B Low (reg2)
|
;D200 ;2 $9600,$9700,$9800 = B Low (reg2)
|
||||||
;3 $9900,$9A00,$9B00 = C Low (reg4)
|
;D300 ;3 $9900,$9A00,$9B00 = C Low (reg4)
|
||||||
;4 $9C00,$9D00,$9E00 = Envelope Shape (r13) [top], C high (reg5) [bot]
|
;D400 ;4 $9C00,$9D00,$9E00 = Envelope Shape (r13) [top], C high (reg5) [bot]
|
||||||
;5 $9F00,$A000,$A100 = Noise (r6), bit7 = don't change envelope
|
;D500 ;5 $9F00,$A000,$A100 = Noise (r6), bit7 = don't change envelope
|
||||||
;6 $A200,$A300,$A400 = Enable (r7)
|
;D600 ;6 $A200,$A300,$A400 = Enable (r7)
|
||||||
;7 $A500,$A600,$A700 = A amp (r8), bit 5 of r8,r9,r10
|
;D700 ;7 $A500,$A600,$A700 = A amp (r8), bit 5 of r8,r9,r10
|
||||||
;8 $A800,$A900,$AA00 = C amp (r10) [top], B amp (r9) [bottom]
|
;D800 ;8 $A800,$A900,$AA00 = C amp (r10) [top], B amp (r9) [bottom]
|
||||||
;9 $AB00,$AC00,$AD00 = ENV low (r11)
|
;D900 ;9 $AB00,$AC00,$AD00 = ENV low (r11)
|
||||||
;a $AE00,$AF00,$B000 = ENV high (r12)
|
;DA00 ;a $AE00,$AF00,$B000 = ENV high (r12)
|
||||||
|
|
||||||
; 3+ 72 + 72 + 83 + 74 + 72 + 77 + 19 + 70 + 74 + 72 +
|
; 3+ 72 + 72 + 83 + 74 + 72 + 77 + 19 + 70 + 74 + 72 +
|
||||||
; 77 + 18 + 82 + 85 + 72 + 72 + 8 + 72 + 6 = 1180
|
; 77 + 18 + 82 + 85 + 72 + 72 + 8 + 72 + 6 = 1180
|
||||||
@ -23,7 +23,7 @@ play_frame_compressed:
|
|||||||
; Register 0: A fine
|
; Register 0: A fine
|
||||||
ldx #0 ; 2
|
ldx #0 ; 2
|
||||||
r0_smc:
|
r0_smc:
|
||||||
lda $9000,Y ; 4+
|
lda $D000,Y ; 4+
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
;======
|
;======
|
||||||
; 72
|
; 72
|
||||||
@ -31,7 +31,7 @@ r0_smc:
|
|||||||
; Register 2: B fine
|
; Register 2: B fine
|
||||||
ldx #2 ; 2
|
ldx #2 ; 2
|
||||||
r2_smc:
|
r2_smc:
|
||||||
lda $9600,Y ; 4+
|
lda $9200,Y ; 4+
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
;======
|
;======
|
||||||
; 72
|
; 72
|
||||||
@ -39,7 +39,7 @@ r2_smc:
|
|||||||
; Register 1: A coarse
|
; Register 1: A coarse
|
||||||
ldx #1 ; 2
|
ldx #1 ; 2
|
||||||
r1_smc:
|
r1_smc:
|
||||||
lda $9300,Y ; 4+
|
lda $9100,Y ; 4+
|
||||||
pha ; 3
|
pha ; 3
|
||||||
lsr ; 2
|
lsr ; 2
|
||||||
lsr ; 2
|
lsr ; 2
|
||||||
@ -59,7 +59,7 @@ r1_smc:
|
|||||||
; Register 4: C fine
|
; Register 4: C fine
|
||||||
ldx #4 ; 2
|
ldx #4 ; 2
|
||||||
r4_smc:
|
r4_smc:
|
||||||
lda $9900,Y ; 4+
|
lda $D300,Y ; 4+
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
;=======
|
;=======
|
||||||
; 72
|
; 72
|
||||||
@ -67,7 +67,7 @@ r4_smc:
|
|||||||
; Register 5: C coarse
|
; Register 5: C coarse
|
||||||
ldx #5 ; 2
|
ldx #5 ; 2
|
||||||
r5_smc:
|
r5_smc:
|
||||||
lda $9C00,Y ; 4+
|
lda $9400,Y ; 4+
|
||||||
pha ; 3
|
pha ; 3
|
||||||
and #$f ; 2
|
and #$f ; 2
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
@ -82,7 +82,7 @@ r5_smc:
|
|||||||
lsr ; 2
|
lsr ; 2
|
||||||
|
|
||||||
r13_smc:
|
r13_smc:
|
||||||
ldx $9F00,Y ; check for env update ; 4
|
ldx $D500,Y ; check for env update ; 4
|
||||||
bmi skip_envelope_write ; 3
|
bmi skip_envelope_write ; 3
|
||||||
;============
|
;============
|
||||||
; 19
|
; 19
|
||||||
@ -107,7 +107,7 @@ done_envelope_write:
|
|||||||
; Register 6: Noise
|
; Register 6: Noise
|
||||||
ldx #6 ; 2
|
ldx #6 ; 2
|
||||||
r6_smc:
|
r6_smc:
|
||||||
lda $9F00,Y ; 4+
|
lda $D500,Y ; 4+
|
||||||
and #$1f ; 2
|
and #$1f ; 2
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
;=======
|
;=======
|
||||||
@ -116,7 +116,7 @@ r6_smc:
|
|||||||
; Register 7: Enable
|
; Register 7: Enable
|
||||||
ldx #7 ; 2
|
ldx #7 ; 2
|
||||||
r7_smc:
|
r7_smc:
|
||||||
lda $A200,Y ; 4+
|
lda $D600,Y ; 4+
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
;========
|
;========
|
||||||
; 72
|
; 72
|
||||||
@ -124,7 +124,7 @@ r7_smc:
|
|||||||
; Register 8: a-amp
|
; Register 8: a-amp
|
||||||
ldx #8 ; 2
|
ldx #8 ; 2
|
||||||
r8_smc:
|
r8_smc:
|
||||||
lda $A500,Y ; 4+
|
lda $D700,Y ; 4+
|
||||||
pha ; 3
|
pha ; 3
|
||||||
and #$1f ; 2
|
and #$1f ; 2
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
@ -144,7 +144,7 @@ r8_smc:
|
|||||||
; Register 9: b-amp (bottom)
|
; Register 9: b-amp (bottom)
|
||||||
ldx #9 ; 2
|
ldx #9 ; 2
|
||||||
r9_smc:
|
r9_smc:
|
||||||
lda $A800,Y ; 4+
|
lda $D800,Y ; 4+
|
||||||
pha ; 3
|
pha ; 3
|
||||||
and #$f ; 2
|
and #$f ; 2
|
||||||
ora AY_REGISTERS ; 3
|
ora AY_REGISTERS ; 3
|
||||||
@ -169,7 +169,7 @@ r9_smc:
|
|||||||
; Register 11: E fine
|
; Register 11: E fine
|
||||||
ldx #11 ; 2
|
ldx #11 ; 2
|
||||||
r11_smc:
|
r11_smc:
|
||||||
lda $AB00,Y ; 4+
|
lda $D900,Y ; 4+
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
;======
|
;======
|
||||||
; 72
|
; 72
|
||||||
@ -177,7 +177,7 @@ r11_smc:
|
|||||||
; Register 12: E coarse
|
; Register 12: E coarse
|
||||||
ldx #12 ; 2
|
ldx #12 ; 2
|
||||||
r12_smc:
|
r12_smc:
|
||||||
lda $AE00,Y ; 4+
|
lda $DA00,Y ; 4+
|
||||||
jsr play_mb_write ; 6+60
|
jsr play_mb_write ; 6+60
|
||||||
;======
|
;======
|
||||||
; 72
|
; 72
|
||||||
|
@ -1,17 +1,17 @@
|
|||||||
; ZZ points to offset from pointer
|
; ZZ points to offset from pointer
|
||||||
|
|
||||||
|
|
||||||
;0 $9000,$9100,$9200 = A Low (reg0)
|
;D000 ;0 $9000,$9100,$9200 = A Low (reg0)
|
||||||
;1 $9300,$9400,$9500 = A high (reg1) [top], B high (reg3) [bottom]
|
;D100 ;1 $9300,$9400,$9500 = A high (reg1) [top], B high (reg3) [bottom]
|
||||||
;2 $9600,$9700,$9800 = B Low (reg2)
|
;D200 ;2 $9600,$9700,$9800 = B Low (reg2)
|
||||||
;3 $9900,$9A00,$9B00 = C Low (reg4)
|
;D300 ;3 $9900,$9A00,$9B00 = C Low (reg4)
|
||||||
;4 $9C00,$9D00,$9E00 = Envelope Shape (r13) [top], C high (reg5) [bot]
|
;D400 ;4 $9C00,$9D00,$9E00 = Envelope Shape (r13) [top], C high (reg5) [bot]
|
||||||
;5 $9F00,$A000,$A100 = Noise (r6), bit7 = don't change envelope
|
;D500 ;5 $9F00,$A000,$A100 = Noise (r6), bit7 = don't change envelope
|
||||||
;6 $A200,$A300,$A400 = Enable (r7)
|
;D600 ;6 $A200,$A300,$A400 = Enable (r7)
|
||||||
;7 $A500,$A600,$A700 = A amp (r8), bit 5 of r8,r9,r10
|
;D700 ;7 $A500,$A600,$A700 = A amp (r8), bit 5 of r8,r9,r10
|
||||||
;8 $A800,$A900,$AA00 = C amp (r10) [top], B amp (r9) [bottom]
|
;D800 ;8 $A800,$A900,$AA00 = C amp (r10) [top], B amp (r9) [bottom]
|
||||||
;9 $AB00,$AC00,$AD00 = ENV low (r11)
|
;D900 ;9 $AB00,$AC00,$AD00 = ENV low (r11)
|
||||||
;a $AE00,$AF00,$B000 = ENV high (r12)
|
;DA00 ;a $AE00,$AF00,$B000 = ENV high (r12)
|
||||||
|
|
||||||
|
|
||||||
pt3_write_frame:
|
pt3_write_frame:
|
||||||
@ -22,7 +22,7 @@ pt3_write_frame:
|
|||||||
; Register 0: A fine
|
; Register 0: A fine
|
||||||
lda A_FINE_TONE
|
lda A_FINE_TONE
|
||||||
r0_wrsmc:
|
r0_wrsmc:
|
||||||
sta $9000,Y
|
sta $D000,Y
|
||||||
|
|
||||||
;==========================
|
;==========================
|
||||||
; Register 1/3: A/B coarse
|
; Register 1/3: A/B coarse
|
||||||
@ -33,13 +33,13 @@ r0_wrsmc:
|
|||||||
asl
|
asl
|
||||||
ora B_COARSE_TONE
|
ora B_COARSE_TONE
|
||||||
r1_wrsmc:
|
r1_wrsmc:
|
||||||
sta $9300,Y
|
sta $D100,Y
|
||||||
|
|
||||||
;====================
|
;====================
|
||||||
; Register 2: B fine
|
; Register 2: B fine
|
||||||
lda B_FINE_TONE
|
lda B_FINE_TONE
|
||||||
r2_wrsmc:
|
r2_wrsmc:
|
||||||
sta $9600,Y
|
sta $D200,Y
|
||||||
|
|
||||||
;====================
|
;====================
|
||||||
; Register 3: B coarse already done
|
; Register 3: B coarse already done
|
||||||
@ -49,7 +49,7 @@ r2_wrsmc:
|
|||||||
; Register 4: C fine
|
; Register 4: C fine
|
||||||
lda C_FINE_TONE
|
lda C_FINE_TONE
|
||||||
r4_wrsmc:
|
r4_wrsmc:
|
||||||
sta $9900,Y
|
sta $D300,Y
|
||||||
|
|
||||||
;=======================================
|
;=======================================
|
||||||
; Register 5: Envelope Shape [top] / C coarse [bottom]
|
; Register 5: Envelope Shape [top] / C coarse [bottom]
|
||||||
@ -81,7 +81,7 @@ done_envelope:
|
|||||||
|
|
||||||
lda C_COARSE_TONE
|
lda C_COARSE_TONE
|
||||||
r13_wrsmc:
|
r13_wrsmc:
|
||||||
sta $9C00,Y
|
sta $D400,Y
|
||||||
|
|
||||||
|
|
||||||
;=====================
|
;=====================
|
||||||
@ -90,13 +90,13 @@ r13_wrsmc:
|
|||||||
and #$1f
|
and #$1f
|
||||||
ora ENVELOPE_SHAPE
|
ora ENVELOPE_SHAPE
|
||||||
r6_wrsmc:
|
r6_wrsmc:
|
||||||
sta $9F00,Y
|
sta $D500,Y
|
||||||
|
|
||||||
;=====================
|
;=====================
|
||||||
; Register 7: Enable
|
; Register 7: Enable
|
||||||
lda ENABLE
|
lda ENABLE
|
||||||
r7_wrsmc:
|
r7_wrsmc:
|
||||||
sta $A200,Y
|
sta $D600,Y
|
||||||
|
|
||||||
;=====================
|
;=====================
|
||||||
; Register 8: a-amp
|
; Register 8: a-amp
|
||||||
@ -117,7 +117,7 @@ r7_wrsmc:
|
|||||||
asl
|
asl
|
||||||
ora A_VOLUME
|
ora A_VOLUME
|
||||||
r8_wrsmc:
|
r8_wrsmc:
|
||||||
sta $A500,Y
|
sta $D700,Y
|
||||||
|
|
||||||
;============================
|
;============================
|
||||||
; Register 9/10: b-amp (bottom) , c-amp (top)
|
; Register 9/10: b-amp (bottom) , c-amp (top)
|
||||||
@ -133,7 +133,7 @@ r8_wrsmc:
|
|||||||
asl
|
asl
|
||||||
ora B_VOLUME
|
ora B_VOLUME
|
||||||
r9_wrsmc:
|
r9_wrsmc:
|
||||||
sta $A800,Y
|
sta $D800,Y
|
||||||
|
|
||||||
;=====================
|
;=====================
|
||||||
; Register 10: c-amp already handled
|
; Register 10: c-amp already handled
|
||||||
@ -143,13 +143,13 @@ r9_wrsmc:
|
|||||||
; Register 11: E fine
|
; Register 11: E fine
|
||||||
lda ENVELOPE_FINE
|
lda ENVELOPE_FINE
|
||||||
r11_wrsmc:
|
r11_wrsmc:
|
||||||
sta $AB00,Y
|
sta $D900,Y
|
||||||
|
|
||||||
;=======================
|
;=======================
|
||||||
; Register 12: E coarse
|
; Register 12: E coarse
|
||||||
lda ENVELOPE_COARSE
|
lda ENVELOPE_COARSE
|
||||||
r12_wrsmc:
|
r12_wrsmc:
|
||||||
sta $AE00,Y
|
sta $DA00,Y
|
||||||
|
|
||||||
;=============================
|
;=============================
|
||||||
; Register 13: already handled
|
; Register 13: already handled
|
||||||
|
@ -9,8 +9,8 @@ end_book:
|
|||||||
|
|
||||||
;===================
|
;===================
|
||||||
; init screen
|
; init screen
|
||||||
jsr TEXT
|
; jsr TEXT
|
||||||
jsr HOME
|
; jsr HOME
|
||||||
bit KEYRESET
|
bit KEYRESET
|
||||||
|
|
||||||
;===================
|
;===================
|
||||||
@ -133,7 +133,7 @@ loopR: dex ; 2
|
|||||||
|
|
||||||
book_loop:
|
book_loop:
|
||||||
|
|
||||||
jsr $9000 ; cycle-counted page0/page1 flip code
|
jsr $9800 ; cycle-counted page0/page1 flip code
|
||||||
|
|
||||||
;======================================================
|
;======================================================
|
||||||
; We have 4550 cycles in the vblank, use them wisely
|
; We have 4550 cycles in the vblank, use them wisely
|
||||||
|
Loading…
Reference in New Issue
Block a user