diff options
| -rw-r--r-- | MOS6502.lisp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/MOS6502.lisp b/MOS6502.lisp index e04c562..98fb8d9 100644 --- a/MOS6502.lisp +++ b/MOS6502.lisp @@ -7,12 +7,14 @@ ;;; needs a value, gets ready to read it from the next address and do something ;;; ;;; The implementation uses closures for the internal registers. -(defparameter *CPU* (let ((PC 0) (AC 0) (X 0) (Y 0) (SR 0) (SP 0)) #'(lambda () - (let ((mval (nth PC *M*))) - (if (eql mval +OP_BRK+) - () - (if (eql mval +OP_ORAxi+) - ())))))) +(defparameter *CPU* + (let ((PC 0) (AC 0) (X 0) (Y 0) (SR 0) (SP 0)) + #'(lambda () + (let ((mval (nth PC *M*))) + (if (eql mval +OP_BRK+) + () + (if (eql mval +OP_ORAxi+) + ())))))) ;;; External memory, where the zero page, stack and general purpose memory resides ;;; Another file has to implement it. |
