A breadboard filled with logic chips and wiring

SPAM-1 Is A Well-Documented Discrete CPU With An Impressive Software Library

Here at Hackaday we love projects that are so well-documented that you can spend days reading up on what the designer has achieved. [John Lonergan] didn’t disappoint when he designed the SPAM-1, an 8-bit CPU built from discrete logic gates. His detailed log contains a wealth of information on such things as designing opcodes, optimizing program counter logic, running a digital simulation, as well as his thoughts on microcode design. The sheer volume of it may be a bit off-putting to beginners, so it might be best to start with the video series that describes the architecture and goes into detail on several sub-blocks.

The design has changed a bit since [John] first started on the project, as he decided to add more and more features, but the final result is a well-thought out architecture that keeps the simplicity needed for discrete hardware but still has enough features to keep it interesting for seasoned CPU aficionados. The instruction size is rather large (48 bits) to simplify the instruction decoding at the expense of larger code size. Conditional jump instructions are not present; instead, all instructions have an optional control flag to make them conditional, a feature inspired by the ARM instruction set.

Once the design was mature enough, [John] modelled the entire thing in Verilog and simulated his design to verify correct operation and to check the timings, estimating it to be workable up to 5 MHz or so. A large stack of breadboards and DIP chips from the 74xx series then brought the design to life.

Not content with simply designing, simulating and implementing a custom CPU in hardware, [John] also spent significant effort on the software side of things, writing an assembler and even a C-like compiler for the SPAM-1 platform. And if that wasn’t enough, he also added an emulator for the classic CHIP-8 language, which allows it to run existing programs like Pong and Tetris. Input and output for all this software is mostly through a UART connection to a PC. A VGA interface is still on [John]’s to-do list, but he did build an adapter to connect a classic NES controller to the system.

The SPAM-1 is a worthy addition to the long list of discrete-logic CPUs we’ve seen here, such as this breadboard computer running a UNIX-like OS or this minimalistic one. If you’d like to see one that implements an existing instruction set, try this homebrew RISC-V computer.

Continue reading “SPAM-1 Is A Well-Documented Discrete CPU With An Impressive Software Library”

Incredible Discrete MOSFET Rover Has Maximum Blink

What do you get when you stick 1738 MOSFETs together? If your answer was a ‘4-bit CPU’, you would be totally correct. Available as a product over at Marutsu as the ‘CPU1738’, it seems to target beginners to computer theory, with build instructions that explain how the CPU is built up from individual MOSFETs that are combined into logic gates.

A CPU1738 NAND PCB.

While decidedly more compact in its SMD format than it would have been with pure through-hole parts, the use of countless small PCBs on top of the larger PCBs make for a pretty hefty package. Board after board build up the CPU, and the assembly continues with the addition of sensors, motors, and wheels. In the end, a robot emerges, albeit a somewhat wobbly-looking one.

Check out the video linked after the break, though before starting one up, note the 50,000 Yen (approximately $500) price tag for the CPU block alone. On the other hand, in addition to the 1738 MOSFETs, there are also 1070 LEDs, so you get what you pay for in blinkies.

Continue reading “Incredible Discrete MOSFET Rover Has Maximum Blink”