API for package: cl-6502
Homepage: Github
*cpu*: #S(|6502|:CPU :PC 65532 :SP 253 :SR 36 :XR 0 :YR 0 :AR 0 :CC 0) variable
The 6502 instance used by default during execution.
cpu (structure-object) class
A 6502 CPU with an extra slot for tracking the cycle count/clock ticks.
asm source standard-generic-function
Assemble SOURCE into a bytevector and return it.
current-instruction cpu &optional print-p function
Return a list representing the current instruction. If PRINT-P is non-nil,
print the current address and instruction and return NIL.
disasm start end function
Disassemble memory from START to END.
disasm-to-list start end function
Disassemble a given region of memory into a sexp-based format.
disasm-to-str start end function
Call DISASM with the provided args and return its output as a string.
execute cpu function
Step the CPU until a BRK instruction.
get-byte address function
Get a byte from RAM at the given ADDRESS.
(setf get-byte) new-val address function
Set ADDRESS in *ram* to NEW-VAL.
get-range start &optional end function
Get a range of bytes from RAM, starting from START and stopping at END if
(setf get-range) bytevector start function
Replace the contents of RAM, starting from START with BYTEVECTOR.
get-word address &optional wrap-p function
Get a word from RAM starting at the given ADDRESS.
(setf get-word) new-val address function
Set ADDRESS and (1+ ADDRESS) in *ram* to NEW-VAL, little endian ordering.
jit-step cpu pc function
If the current block has been JIT compiled, run it, otherwise JIT compile it.
nmi obj standard-generic-function
Generate a non-maskable interrupt. Used for vblanking in NES.
reset obj standard-generic-function
Reset the OBJ to an initial state.
step-cpu cpu opcode function
Step the CPU through the next OPCODE.