Searched Projects

Tags: 12-bit

project.name
3 Stars     220 Views

A toy 12-bit 8 ISA CPU.

4 bit op-code, 8 bit address, 8 bit ALU.

Implements LDA (load accumulator with value at address), STA (store accumulator at address), ADD (accumulator + register b), SUB (accumulator - register b), MBA (move accumulator to register b), JMP (jump to address), JZ (jump to address if zero flag set), HLT (halt), with op-codes 0001 to 0111 and 1111, respectively.

You can write your own program, load it into the RAM, and press the start button to watch magic happen.

Examples:

0b000000000000 0b000000001010 0b000100000001 0b010100000000 0b000100000000 0b001100000000 0b001000000000 0b010110000100 0b111111111111

0, 5, LDA 1, MBA, LDA 0, ADD, STA 0, JMP 4, HLT

0b000100001011 0b010100000000 0b000100001100 0b010000000000 0b011100000110 0b011000000011 0b000100001100 0b010000000000 0b011100001010 0b011000000111 0b111111111111 0b000000000001 0b000000000011

LDA 11, MBA, LDA 12, SUB, JZ 6, JMP 3, LDA 8, SUB, JZ 10, JMP 7, HLT, 1, 3