X-Git-Url: http://git.joshuawise.com/fpgaboy.git/blobdiff_plain/f888201b9894683abfff012bd68b641319fb2744..f2b745a710572fd5cb2b1cf97d1d05a9b74d4fe1:/diag.asm?ds=sidebyside diff --git a/diag.asm b/diag.asm index 28fce99..786052e 100644 --- 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