Nullcore is a puzzle about writing tiny assembly programs for a made-up microcontroller. You read numbers from input pins, do arithmetic in a register called ACC, and write answers out to output pins. Each level gives you a target behavior and three or four test cases — when your program passes all of them, the level is solved.
The microcontroller has four input pins (IN0–IN3), four output pins (OUT0–OUT3), and two scratch registers: ACC (where arithmetic happens) and DAT (a second slot, used by the last level to remember things between runs). Inputs are decided by the level; your job is to set the outputs.
| MOV src dst | Copy a value. src can be IN0-3, OUT0-3, ACC, DAT, or a number. dst can be OUT0-3, ACC, or DAT. |
| ADD val | ACC = ACC + val |
| SUB val | ACC = ACC - val |
| MUL val | ACC = ACC * val |
| AND val | ACC = ACC bitwise-AND val |
| OR val | ACC = ACC bitwise-OR val |
| NOT | ACC = bitwise NOT of ACC (8-bit) |
| JMP label | Unconditional jump to label. |
| JEZ label | Jump if ACC is equal to zero. |
| JNZ label | Jump if ACC is not zero. |
| JGZ label | Jump if ACC > 0. |
| JLZ label | Jump if ACC < 0. |
| NOP | Do nothing. |
| HALT | Stop execution. |
| label: | Define a jump target on its own line. |
| ; comment | Everything after a semicolon is ignored. |