]> Joshua Wise's Git repositories - fpgaboy.git/blobdiff - rom.asm
Timer works.
[fpgaboy.git] / rom.asm
diff --git a/rom.asm b/rom.asm
index 93f8524713edd8bb709ba7496a57f76d39295fcb..5527ea889a0bd0a9e07c39024757aabc5a2be5ad 100644 (file)
--- a/rom.asm
+++ b/rom.asm
@@ -4,7 +4,7 @@ main:
        ld c, $51       ; Note that we are alive.
        ld a, $FF
        ld [c],a
-
+       
        ld sp, $DFFF
 
        ld hl, signon
@@ -105,7 +105,7 @@ waitsw:
        call puts
        
        ld c, $07
-       ld a, $07       ;start timer, 4.096KHz
+       ld a, $04       ;start timer, 4.096KHz
        ld [c], a
        
        ld c, $51
@@ -138,13 +138,8 @@ testa:
        ret z
        xor a
        ld [c], a
-       ld hl, $D000
-       ld c, [hl]
-       inc bc
-       ld [hl], c
-       ld a, c
-       ld c, $50
-       ld [c], a
+       ld a, $41
+       call putc
        ret
 
 ; Core instruction basic acceptance tests.
@@ -258,10 +253,12 @@ insntest:
 putc:
        ld b, 0
        ld c, $50
+       push af
 .waitport:
        ld a,[c]
        cp b
        jr nz,.waitport
+       pop af
        ld [c],a
        ret
 
@@ -269,6 +266,8 @@ puts:
        ld a, [hli]
        ld b, $00
        cp b
-       ret z
+       jr z, .done
        call putc
        jr puts
+.done:
+       ret
This page took 0.023934 seconds and 4 git commands to generate.