diff --git a/README.md b/README.md index 2165e2c..a8bc1e0 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ in the racket repl (comments for reader comprehension, remove before running): will evaluate to: ``` -PC: $16, SP: $00, Flags: %00000000 +PC: $0161, SP: $0000, Flags: %00000000 BC: $0000, DE: $0000 HL: $0163, AF: $6000 (HL): $60 diff --git a/vm.rkt b/vm.rkt index 56183d7..cf88bc0 100644 --- a/vm.rkt +++ b/vm.rkt @@ -192,9 +192,9 @@ (define (print-state m) (displayln (format "PC: $~a, SP: $~a, Flags: %~a" - (display-byte-hex (mem-pc m)) - (display-byte-hex (mem-sp m)) - (display-bin(mem-flags m))))) + (display-word-hex (mem-pc m)) + (display-word-hex (mem-sp m)) + (display-bin (mem-flags m))))) (define (print-part-bank start count m) (define (print-mem v)