Skip to content

Replica of the Kenbak-1: the first personnal computer. Logic is entirely emulated using an Arduino.

License

Notifications You must be signed in to change notification settings

GilDev/Kenbak-1-Replica

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kenbak-1 Replica

Replica of the Kenbak-1: the first personnal computer.

All the internal TTL logic has been replaced by an Arduino Nano. An MCP23017 handle the inputs. An TLC5940NT handle the LEDs.

Schematic

Differences with the original

  • Useful shortcuts (see below).
  • Memory initialized to 0.
  • Unprecise timing (original Kenbak-1 instructions had an unknown number of cycles).

Publications

If you want to learn more about the computer, here are some publications taken from the Kenbak-1's original website:

Compilation

You will need PlatformIO (first time I use it in a project, amazing tool).

  • To compile: $ pio run.
  • To upload: $ pio run -t upload.

Shortcuts

  • STOP + START: As the original Kenbak-1, executes one instruction.
  • STOP + READ: Load RAM n°X. X is determined by the input number entered on the Kenbak-1 (input register: memory address 0377). Programs 0-3 come from the Arduino's EEPROM, others from the Arduino's Flash (sample programs).
  • STOP + STORE: Store RAM in EEPROM bank n°X. Only numbers 0-3 are allowed.
  • STOP + CLEAR: Clear all RAM (initialized to 0).
  • STOP + DISPLAY: Dump RAM to serial if DEBUG is defined (config.h)[src/config.h] in a C-array friendly manner. I use this so I can enter a program from the Kenbak-1 and then easily save it as a sample program.
  • STOP + B0-B7: Change LEDs' brightness.

Sample programs

0-3. User saved programs (EEPROM)

You can find listing and instructions for the following programs in the Laboratory Exercices completed by myself.

  1. Automatic counter (Laboratory Exercises Exercise 2, page 2-3 and almost Exercise 12, page 12-5)
  2. Step-by-step counter (Laboratory Exercises Exercise 3, page 3-1)
  3. Binary to decimal training (Laboratory Exercises Exercise 4, page 4-3)
  4. Decimal to binary training (Laboratory Exercises Exercise 5, page 5-1)
  5. Adder (Laboratory Exercises Exercise 6, page 6-1)
  6. Combination lock, code is 42 (Laboratory Exercises Exercise 11, page 11-7)
  7. Separate tallies (Laboratory Exercises Exercise 13, page 13-4)
  8. Sum of consecutive values in memory (Laboratory Exercises Exercise 14, page 14-6, preloaded with values given page 14-4)
  9. Substraction (Laboratory Exercises Exercise 15, page 15-4)
  10. Two numbers adder by consecutive increments (Laboratory Exercises Exercise 15, page 15-5)

You can find listing and instructions for the following custom programs in the samplePrograms folder.

  1. K-2000: simple animation of an LED going back and forth.
  2. Multiplier: multiply two numbers.
  3. Pong: very simple Pong game.

TODO

  • Put sample programs in Arduino's flash memory!
  • Update and upload schematics, PCB, 3D model, GCode and everything.
  • Add comments and maybe better format for sample program's listings. Those tabulations aren't the best.
  • Use MCP23017 interrupts.
  • Use internal timer to check battery's voltage every X sec.
  • Uniformize switchs and ifs in exec().
  • Make a test suit for the emulator.

Quirks

Releases

No releases published

Packages

No packages published

Languages