Back to main page

 The 8-bit Turbonator

My very own DIY 8-bit computer

  • The current state of the build.
  • The first modules were finished. PSU, Clock and Bus monitor.
  • I added a control monitor, an instruction counter and the A register.
  • Then I added some switches to play around with the bus and control lines.
  • Behold my ALU.
  • The ALU closeup.
  • Let there be RAM.
  • Freshly milled PCB for the control unit.
  • Now I needed an EEPROM writer.
  • It's ALIVE!!!
  • Let there be Quarz!
  • The new keyboard module.
  • The new MHz clock module and the reset/power up module.

The current state of the build.

I've built my own 8-bit computer from 4000 and 74HC series CMOS ICs. It has 4KB of RAM and is Turing complete. It has 16 arithmetic operations in its ALU and can perform conditional jumps. Programs are loaded by a BIOS module from a cartridge.

I was among others inspired by the work of Ben Eater:
https://eater.net/
https://www.youtube.com/channel/UCS0N5baNlQWJCUrhCEo8WlA
Thanks for the inspiration.

Here's some basic info about the computer:

Schematics and PCB layouts

The individual modules are plugged into a board connecting them on 36 rails. The modules are as follows (top to bottom). Links go the schematics and PCB designs.

Notes:

Next steps:

The assembler

Commands
CommandParametersDescription
NOOPDo nothing
LDAMemory address [0-4095]Load RAM content to register A
STAMemory address [0-4095]Store Register A to RAM
LDABUpper 4 bits of memory address [0-15]Load lower 8 bits of memory address from register B and load RAM content to register A
STABUpper 4 bits of memory address [0-15]Load lower 8 bits of memory address from register B and store register A to RAM
LDIAValue [0-255]Load Value to register A
CALC0Function [0-15]Calculate with low carry in bit
CALC1Function [0-15]Calculate with high carry in bit
JCFunction [0-15], Memory address [0-255]Jump to program line if calculation with low carry in bit yields high carry out bit. Use "JC 3" for unconditional jumps
JCCFunction [0-15], Memory address [0-255]Jump to program line if calculation with high carry in bit yields high carry out bit
OUTDisplay content of register A
AtoBCopy register A to register B
IOACTIO device ID [0-15]Activate IO device matching id, deactivate all others
IOREADReads IO data from active IO device into memory address stored in register A and overwrites register A with IO data
IOWRITEWrite data from memory address stored in Register A to active IO device
HALTHalt computer

The ALU functions

ALU functions
IDCALC0 / JCCALC1 / JCC
0AA plus 1
1A + B(A + B) plus 1
2A + B_(A + B_) plus 1
3minus 1Zero
4A plus AB_A plus AB_ plus 1
5(A + B) plus AB_(A + B) plus AB_ plus 1
6A minus B minus 1A minus B
7AB_ minus 1AB_
8A plus ABA plus AB plus 1
9A plus BA plus B plus 1
10(A + B_) plus AB(A + B_) plus AB plus 1
11AB minus 1AB
12A plus AA plus A plus 1
13(A + B) plus A(A + B) plus A plus 1
14(A+ B_) plus A(A + B_) plus A plus 1
15A minus 1A

Where A+B is a bitwise OR, AB is a bitwise AND and A_ is the complement of A. Taken from the HCF40181B datasheet.

Try it for yourself

An editor, emulator, and compiler for my assembler that runs right in your browser can be found here.

Watch it on YouTube

A video of the computer loading and executing a program calculating the 13th Fibbonacci number and dividing it by 3 at 500Hz can be found here.

What you see:
First, you see the computer counting up to 94 while the left blue LED on the control monitor is on. This indicates the BIOS is loading the program from the cartridge to ram. As the BIOS itself has 22 lines, the counter starts at 22 and loads 72 lines of code into RAM. after that the BIOS LED turns off and the program executes, calculating the 13th Fibonacci Number, which is 233, then dividing it by 3,yielding 77. Then the computer halts and I give it a thumbs up.

A video of the computer loading and executing a program calculating the 13th Fibbonacci number and dividing it by 2 at 2.048KHz using the new quarz clock can be found here.

A video of me interacting with the computer through the new keyboard module can be found here: here.

A video of the computer loading and executing a program calculating the Fibbonacci sequence at 40Hz can be found here.

The main rails connecting all modules

Rails
PinNameFunction
1VCC +5V
2CLOCKClock pulse
3BUS0Bus bit 0
4BUS1Bus bit 1
5BUS2Bus bit 2
6BUS3Bus bit 3
7BUS4Bus bit 4
8BUS5Bus bit 5
9BUS6Bus bit 6
10BUS7Bus bit 7
11CTRL0ALU function register in
12CTRL1ALU out
13CTRL2ALU carry bit
14CTRL3Register A in
15CTRL4Register A out
16CTRL5Register B in
17CTRL6Register B out
18CTRL7Instruction register in
19CTRL8Instruction register out
20CTRL9Memory address register 1 in
21CTRL10Memory address register 2 in
22CTRL11RAM in
23CTRL12RAM out
24CTRL13Output in
25CTRL14Counter enable
26CTRL15Counter out
27CTRL16Counter in / Jump
28CTRL17Conditional Jump
29CTRL18Instruction counter reset
30CTRL19I/O device out
31CTRL20I/O device in
32CTRL21BIOS active
33CTRL22Reset
34CTRL23Halt
35CLOCK_IInverted clock pulse
36GNDGround

EEPROM code and assembler definition

I defined my assembler and BIOS within an libreoffice calc sheet. It can be downloaded here

EEPROM writer

I've built my EEPROM writer as described by Ben Eater in this video

The Arduino programs can be downloaded here: