diff --git a/demos/tiny_wip/Makefile b/demos/tiny_wip/Makefile new file mode 100644 index 00000000..016d2ecd --- /dev/null +++ b/demos/tiny_wip/Makefile @@ -0,0 +1,51 @@ +include ../../Makefile.inc + +DOS33 = ../../utils/dos33fs-utils/dos33 +TOKENIZE = ../../utils/asoft_basic-utils/tokenize_asoft +EMPTYDISK = ../../empty_disk/empty.dsk +LINKER_SCRIPTS = ../../linker_scripts/ + +all: tiny_demos.dsk + +tiny_demos.dsk: HELLO CHEVRON_17 CIRCUIT_17 TIGER_22 + cp $(EMPTYDISK) tiny_demos.dsk + $(DOS33) -y tiny_demos.dsk SAVE A HELLO + $(DOS33) -y tiny_demos.dsk BSAVE -a 0xE7 CHEVRON_17 + $(DOS33) -y tiny_demos.dsk BSAVE -a 0xE7 CIRCUIT_17 + $(DOS33) -y tiny_demos.dsk BSAVE -a 0xE7 TIGER_22 + +### + +HELLO: hello.bas + $(TOKENIZE) < hello.bas > HELLO + +### + +CHEVRON_17: chevron_17.o + ld65 -o CHEVRON_17 chevron_17.o -C $(LINKER_SCRIPTS)/apple2_e7_zp.inc + +chevron_17.o: chevron_17.s + ca65 -o chevron_17.o chevron_17.s -l chevron_17.lst + +### + +CIRCUIT_17: circuit_17.o + ld65 -o CIRCUIT_17 circuit_17.o -C $(LINKER_SCRIPTS)/apple2_e7_zp.inc + +circuit_17.o: circuit_17.s + ca65 -o circuit_17.o circuit_17.s -l circuit_17.lst + +### + +TIGER_22: tiger_22.o + ld65 -o TIGER_22 tiger_22.o -C $(LINKER_SCRIPTS)/apple2_e7_zp.inc + +tiger_22.o: tiger_22.s + ca65 -o tiger_22.o tiger_22.s -l tiger_22.lst + +#### + +clean: + rm -f *~ *.o *.lst HELLO \ + CHEVRON_17 CIRCUIT_17 TIGER_22 *.zip + diff --git a/demos/tiny_wip/chevron_17.s b/demos/tiny_wip/chevron_17.s new file mode 100644 index 00000000..a8b3032f --- /dev/null +++ b/demos/tiny_wip/chevron_17.s @@ -0,0 +1,110 @@ +; 17B interesting XDRAW pattern + +; This one looks vaguely like a chevron shape + +; by Vince `deater` Weaver / dSr + +; zero page locations +GBASL = $26 +GBASH = $27 +HGR_SCALE = $E7 +HGR_COLLISIONS = $EA + +; ROM locations +HGR2 = $F3D8 +HPOSN = $F411 +XDRAW0 = $F65D +XDRAW1 = $F661 +HPLOT0 = $F457 + +chevron17: + + ; we load at zero page $E7 which is HGR_SCALE + ; this means the scale is $20 (JSR) + + ; $20 $D8 $F3 + + jsr HGR2 ; Hi-res, full screen ; 3 + ; Y=0, A=0 after this call + + ; A and Y are 0 here. + ; X is left behind by the boot process? + + ; set GBASL/GBASH + ; we really have to call this, otherwise it won't run + ; on some real hardware depending on setup of zero page at boot + + jsr HPLOT0 ; set screen position to X= (y,x) Y=(a) + ; saves X,Y,A to zero page + ; after Y= orig X/7 + ; A and X are ?? + + + ; aa = (orange)tiger stripes + ; 55 = purple + ; 2a = green +; lda #$2a +; jsr $F3F4 + +tiny_loop: + + ; e2/e3 + ; 0.. 63? + ; 0 = maze + ; 1 = scaly + ; 2 = ?? + ; 3 = tower plates + ; 4 = bubbles + ; 5 = strings + ; 6 = circuit board * + ; 7 = noodles + ; 8 = pickup sticks + ; 9 = meh + ; 10 = interesting + ; 11 = meh + ; 12 = static + ; 13 = weave + ; 14 = core + ; 15 = masts * + ; 16 = maze again + ; 17 = spots * + ; 18 = bamboo * + ; 19 = mesh + ; 20 = coils + ; 21 = sunspots + ; 22 = gridy + ; 23 = dominos + ; 24 = chevron ** + ; 25 = borg + ; 26 = grid + ; 27 = plants + ; 28 = spaces + ; 29 = ridges + ; 30 = net + ; 31 = odd + ; 32 = maze again + + ; e2/e5 + ; e3 looks best? + ; a0 interesting, green train + +; inc rot_smc+1 ; broken glass + +; bit $C030 + +rot_smc: + lda #$D8 ; $18, $58, $98, $D8 + + ; ROT=$D8 + + ldy #$E2 ; + ldx #$E3 ; Y=$E2 + ; X=$E3 + + jsr XDRAW0 ; XDRAW, A =ROTATE, X/Y = point to shape + ; Both A and X are 0 at exit + ; Z flag set on exit + ; Y varies + + beq tiny_loop ; bra + diff --git a/demos/tiny_wip/circuit_17.s b/demos/tiny_wip/circuit_17.s new file mode 100644 index 00000000..99a038b8 --- /dev/null +++ b/demos/tiny_wip/circuit_17.s @@ -0,0 +1,110 @@ +; 17B interesting XDRAW pattern + +; This one looks vaguely like a circuit board + +; by Vince `deater` Weaver / dSr + +; zero page locations +GBASL = $26 +GBASH = $27 +HGR_SCALE = $E7 +HGR_COLLISIONS = $EA + +; ROM locations +HGR2 = $F3D8 +HPOSN = $F411 +XDRAW0 = $F65D +XDRAW1 = $F661 +HPLOT0 = $F457 + +circuit17: + + ; we load at zero page $E7 which is HGR_SCALE + ; this means the scale is $20 (JSR) + + ; $20 $D8 $F3 + + jsr HGR2 ; Hi-res, full screen ; 3 + ; Y=0, A=0 after this call + + ; A and Y are 0 here. + ; X is left behind by the boot process? + + ; set GBASL/GBASH + ; we really have to call this, otherwise it won't run + ; on some real hardware depending on setup of zero page at boot + + jsr HPLOT0 ; set screen position to X= (y,x) Y=(a) + ; saves X,Y,A to zero page + ; after Y= orig X/7 + ; A and X are ?? + + + ; aa = (orange)tiger stripes + ; 55 = purple + ; 2a = green +; lda #$2a +; jsr $F3F4 + +tiny_loop: + + ; e2/e3 + ; 0.. 63? + ; 0 = maze + ; 1 = scaly + ; 2 = ?? + ; 3 = tower plates + ; 4 = bubbles + ; 5 = strings + ; 6 = circuit board * + ; 7 = noodles + ; 8 = pickup sticks + ; 9 = meh + ; 10 = interesting + ; 11 = meh + ; 12 = static + ; 13 = weave + ; 14 = core + ; 15 = masts * + ; 16 = maze again + ; 17 = spots * + ; 18 = bamboo * + ; 19 = mesh + ; 20 = coils + ; 21 = sunspots + ; 22 = gridy + ; 23 = dominos + ; 24 = chevron ** + ; 25 = borg + ; 26 = grid + ; 27 = plants + ; 28 = spaces + ; 29 = ridges + ; 30 = net + ; 31 = odd + ; 32 = maze again + + ; e2/e5 + ; e3 looks best? + ; a0 interesting, green train + +; inc rot_smc+1 ; broken glass + +; bit $C030 + +rot_smc: + lda #$6 ; $6 + + ; ROT=$C6 + + ldy #$E2 ; + ldx #$E3 ; Y=$E2 + ; X=$E3 + + jsr XDRAW0 ; XDRAW, A =ROTATE, X/Y = point to shape + ; Both A and X are 0 at exit + ; Z flag set on exit + ; Y varies + + beq tiny_loop ; bra + diff --git a/demos/tiny_wip/hello.bas b/demos/tiny_wip/hello.bas new file mode 100644 index 00000000..0e3aae36 --- /dev/null +++ b/demos/tiny_wip/hello.bas @@ -0,0 +1,2 @@ +5 HOME +40 PRINT CHR$(4)"CATALOG"