mirror of
https://github.com/tjboldt/Apple2-IO-RPi.git
synced 2024-11-24 15:31:14 +00:00
Add test assembler code to match Go and Node.js code
This commit is contained in:
parent
3c08efa01c
commit
7acbbc1d26
3
Firmware/assemble_test.sh
Executable file
3
Firmware/assemble_test.sh
Executable file
@ -0,0 +1,3 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
ca65 test.asm
|
||||||
|
ld65 test.o -o test.bin -t none
|
11
Firmware/test.asm
Normal file
11
Firmware/test.asm
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
ldx #$50 ;slot 5 for this test
|
||||||
|
start: lda #$80 ;set read flag low (ready to read)
|
||||||
|
sta $c08d,x ;bit 1 low for writing values
|
||||||
|
waitwl: lda $c08e,x ;bit 0 low for reading values
|
||||||
|
bmi waitwl ;wait for write flag low
|
||||||
|
jsr $fde3 ;print nibble of data
|
||||||
|
lda #$c0 ;set read flag high (done reading)
|
||||||
|
sta $c08d,x
|
||||||
|
waitwh: lda $c08e,x
|
||||||
|
bpl waitwh ;wait for write flag high
|
||||||
|
bmi start ;go around againg for next nibble
|
Loading…
Reference in New Issue
Block a user