]> Joshua Wise's Git repositories - fpgaboy.git/commitdiff
Don't print A until we have to.
authorJoshua Wise <joshua@rebirth.joshuawise.com>
Mon, 7 Apr 2008 06:50:15 +0000 (02:50 -0400)
committerJoshua Wise <joshua@rebirth.joshuawise.com>
Mon, 7 Apr 2008 06:50:15 +0000 (02:50 -0400)
diag.asm

index 28fce997faa6229368ced11d2339e3c536590264..786052e76801b8ef901312ad0c2c474d660331e0 100644 (file)
--- a/diag.asm
+++ b/diag.asm
@@ -13,7 +13,8 @@ main:
 
        ld hl, $DF81
        xor a
-       ld [hl], a
+       ld [hli], a
+       ld [hli], a
        
        ld hl, signon
        call puts
@@ -44,10 +45,13 @@ irqhand:
        ld c, $0F       ; ack the irq
        ld [c], a
        
+       ld hl, $DF82
+       ld a, [hld]
+       cp 0
+       jr z, .noprint
        ld a, $41       ; print A
        call putc
-       
-       ld hl, $DF81
+.noprint:
        ld a, [hl]
        add 1
        ld c, $51
@@ -138,6 +142,10 @@ puthex:                            ; Put two hex nibbles to the serial console.
 waitsw:
        ld hl,waitswstr
        call puts
+       
+       ld hl,$DF82
+       ld a, 1
+       ld [hl], a
 
        ld c, $51
        xor a
This page took 0.030565 seconds and 4 git commands to generate.