Memory Dump
Assembly code

Virtual machine/emulator based on architecture of CARDboard Illustrative Aid to Computation

Instruction format

label: operation argument

Instruction set

Instruction Alias Description
Standart instruction set
Data access
CLA xx LOAD Read memory at address xx into accumulator
STO xx STORE Write accumulator contents to memory at address xx
Arithmetic
ADD xx Add contents of memory at address xx to accumulator
SUB xx Subtract contents of memory at address xx from accumulator
SFT xy SHIFT Shift accumulator contents x times left and y times right
Control flow
JMP xx Saves program counter to memory cell 99 and jumps to address xx
TAC xx JNEG Jumps to address xx if accumulator content is less than 0
HRS xx RESET Stops evaluation and sets program counter to xx
I/O
INP xx Read user input to memory at address xx
OUT xx Writes content of memory at address xx
Additional assembler macros
ORG xx Following code will be put to memory starting from location xx
SET xxx Puts constant to accumulator (expands to 3 instructions)
RET Jump to saved return address (cleans accumulator)

Implementation details

For compatibility purposes memory cell 0 contains value 001, but instead of bootstrapping, assembled program is directly written to "memory" starting from address 1.