Electronic – memory for the simplest possible computer (Pi0K)

componentscpudigital-logicmemorytransistors

I'd like to build the simplest possible computer. I don't care about speed or storage, indeed having slow speed and low storage is a huge advantage as I want to build it out of transistors (ideally relays!) and I want an LED for each state. It'll be programmed via a Raspberry Pi which will host a camera so that you can see each clock cycle executing (yes, it's going to run at Hz not GHz). It'll be an open design with the intention that schools can buy the parts, understand and improve on the design. So the total budget must be well under £400, preferably about £100.

I have researched this over many years and have good ideas for the CPU (minimal registers, microcode in DIP switches and bit serial logic/arithmetic operations to reduce the transistor count). What I can't figure out is how to get the memory, I'd like 1024 to 8096 bits.

The best I can come up with is two 6 bit one-of-n decoders giving access to 64 x 64 grid of capacitors. Either they have a charge in them or they don't, and reading would reinforce that state. There would be no LEDs on the capacitors as the refresh of this 'DRAM' would be in the order or minutes (which is a shame as this would be the only part not to show state).

Other ideas include some form of tape drive (compact cassette mechanism: great storage, too complex, no seek), drum memory (tape around a bean can: too hard to get the mechanics working), mechanical memory (bike wheel and ball bearings: too many bit errors), core memory (large hard ferrite cores: still very tricky to get right at the scale required), tape/card (can we still buy the tape readers), rotating disk with punched holes in binary order and some magnetic memory for storage (too complex to build).

Ultimately the aim is to publish a design that can be build in a school year where all parts of a CPU and memory are 'visible' and so you can see the instruction fetch, decode to microcode, and address decoding/register access/logic all happening over the course of minutes.

If anyone has ideas for really cheap memory (<<£100) where it's clear exactly how it works then please do let me know.

Tony

P.S. current state of play is at http://www.blinkingcomputer.org/

Best Answer

There are many people who have built computers out of discrete transistors, ICs, relays, and even vacuum tubes. They range from 4-bit machines all the way up to 32-bit. The 4-bitters of course will be the simplest you can build and do anything. The very first microprocessor was Intel's 4-bit 4004.

I would start by searching Google for "home-brew 4-bit computers" (without the quotes).

Here's a board from a transistorized 4-bit computer:

enter image description here

As far as memory goes, some of these projects which otherwise are using discrete transistors "cheat" and use SRAM chips. They are incredibly cheap for moderate amounts of memory, 32KB is $3.28 and requires no clocks and no refresh.

Even if the rest of your computer uses relays, using them for memory will be prohibitively expensive.

If you can get by with 1K bits, you could build one with transistorized flip-flops; 2048 2N3904's will cost 3¢ apiece ($60 altogether, plus the other components which will be even cheaper -- resisters for 1/2 a cent etc). You can get PCB's made for $10 apiece, then hire a kid to stuff them.

Relay computers date all the way back to the late 1930's, and one of the first was the Harvard Mark I. It's where the name Harvard architecture comes from (separate program space and data, compared to von Neumann architecture that combines the two).

The most famous home-brew relay computer is one built by Harry Porter.

enter image description here

Check out the videos of the computer running. Reminds me of an old electromechanical telephone exchange.

Here's a portion of another home-brew relay computer called Zusie:

enter image description here

Lots of blinking lights.

And finally, here's a link to a video of a 4-bit adder, made up of 24 relays. Adders like this are the heart of the ALU (arithmetic logic unit) in a computer.

Related Topic