# HG changeset patch # User Robert McIntyre # Date 1334313355 18000 # Node ID ddb3c6299619615c14314b83f48498fb33925d58 # Parent 0591dcddf83171bae99de745325ba2da477bf592 allowed non-even initial blank inputs. diff -r 0591dcddf831 -r ddb3c6299619 clojure/com/aurellem/gb/rlm_assembly.clj --- a/clojure/com/aurellem/gb/rlm_assembly.clj Fri Apr 13 05:28:17 2012 -0500 +++ b/clojure/com/aurellem/gb/rlm_assembly.clj Fri Apr 13 05:35:55 2012 -0500 @@ -217,7 +217,7 @@ 0xAF ;; test for output-mode (bytes-to-write > 0) 0x00 ;; (cp A B) 0x7B ;; E->A - 0x20 ;; skip input section if + 0x20 ;; skip input section if :to-output ;; we're not in input mode :to-be-executed @@ -226,13 +226,18 @@ 0xEA :to-be-executed-address + ;; if A is zero, skip the protection section + 0xA7 + 0x28 + 0x09 + 0x0C ;; inc C 0xCB 0x41 ;; test bit 0 of C 0x20 ;; if (0 == (C % 2)) 0x04 0xAF ;; put a no op (0x00) in to-be-executed - 0xEA + 0xEA ;; every other time. :to-be-executed-address 0x18 ;; return @@ -335,9 +340,10 @@ (let [after (-> (bootstrap-base) (step []) - (step []) (step (buttons 0x67)) (step (buttons n)) + (step []) + (step []) )] (hex (H after))))