The design for a simple portable computer that only a pen and a piece of paper.
The computer consists of a sheet of paper that contains both the program as well as a number of data registers and a paper nibble dice, that will be used to represent the contents of the data registers. This is a modified and extended edition of the papiercomputer by Wolfgang Back and Ulrich Rohde.
To begin, the pen, representing the program counter, is positioned at the line
00 of a program. The instruction in that line is then processed by the user by either moving the pen(program counter), modifying the value of a data register or by checking if a data register has become “empty”(zeroed).
This very rudimentary instruction set will not allow to write sophisticated applications, but will teach about the use of commands to program, mnemonics to write up commands in a short code similarly to assembly language instructions and introduce the concepts of registers
ENDAborts the execution of your program, so that you can examine the contents of your data registers.
SKP R#Checks if the data register R# is zero(contains no value). If it is zero, the program counter is increased by 2, otherwise the program counter is increased only by 1.
JMP ##Sets the program counter to line number ##, “jump” to line ## in your program.
ADD R#Increments the contents of the data register R# and increases the program counter by 1.
SUB R#Decrements the contents of the data register R# and increases the program counter by 1.
To encode a program into a 8-bits punched card, we will be using 3 bits of space to encode the operation, which leaves 5 bits for the value. This computer's programs uses only 5 operations out of a possible 8, leaving 3 unused.
The following program subtracts from
R1 and adds to
R0 until the value of
R1 is zero. The result of the addition of
R1 will be stored in
The binary expression of the operation and value of the previous program can be encoded vertically as the following punched card:
v v v v v v • • • • • • • • • • •
Ref. 5-bits Table
The following table show the binary table for 32 addressable lines of a program.
incoming(2): binary nibble dice