Live data from Hacker News

Build an 8-bit computer from scratch (2016)

eater.net

21–30 of 68 posts

Re: Build an 8-bit computer from scratch (2016)

#21
post #13

I did the whole thing, was able to get the Fibonacci numbers appear and learned a lot during the process. However, I would not recommend other people to try this today, because -- * It is not necessarily the best way to spend your time and money. You'll be looking at tens of hours on building it plus over $300 in parts, for a very slow and basic computer that you probably will forget and throw away at some point. Cut…

I’ll play devil’s advocate.

Following Ben’s videos and building the 8-bit CPU is the first thing that ever helped me “get” electronics and circuitry.

Honestly, way more than half of the fun has been in finding the design flaws and designing fixes for them as well as improving and expanding the design itself.

I have learned so much by going down rabbit holes. The original clock design assumes a make-before-break switch but the one shipped with the kit is the opposite, and this can put one of the flip flops into an invalid state. I switched to CMOS chips and learned why you shouldn’t drive loads like LEDs directly from digital outputs, and dove into the easiest way to power 8 LEDs off 8 IC outs without a mess of transistors. I followed another person’s expansion to a full 8-bit instruction register and a more featureful ALU (with my own changes of course). I worked to minimize power consumption. I’ve learned how to use an oscilloscope. I’ve improved upon nearly every module, and built and rebuilt them all a handful of times.

None of this has any real benefit for the CPU. It will never run anything more than toy programs. But that wasn’t ever the point.

All the flaws in the original design have been perfect as launching points for learning more and more.

Re: Build an 8-bit computer from scratch (2016)

#23
If figuring out how computers work starting all the way from logic gates interests you, but you don’t want to start by ordering parts and soldering, check out the ”game” Turing Complete.

Of course it’s not the same thing as actually building the electronics! But it can be a nice introduction.

Re: Build an 8-bit computer from scratch (2016)

#24
post #13

I did the whole thing, was able to get the Fibonacci numbers appear and learned a lot during the process. However, I would not recommend other people to try this today, because -- * It is not necessarily the best way to spend your time and money. You'll be looking at tens of hours on building it plus over $300 in parts, for a very slow and basic computer that you probably will forget and throw away at some point. Cut…

As a side note, reading "But How Do It Know" for a total beginner like me can help to scratch the itch of understanding the basics. I really loved the book and will buy my 3rd copy (lost one and gave away another).

Re: Build an 8-bit computer from scratch (2016)

#25

Note that even the "Update" video is nine years old. Also note that yes it's a computer, but it has 16 bytes of memory to hold both the program and the program's variables. BYTES. Not KB, not MB, not GB. Bytes. The demo Fibonacci program is pretty much the most complex thing you can do with it. But it is in fact a genuine von Neumann computer. And understandable.

It feels almost more useful than BASIC on the Atari 2600, at least.

Re: Build an 8-bit computer from scratch (2016)

#27
The Ben Eater computer is an interesting starting point. With a few modifications, such as an extended program counter / address bus, a combinatorial ALU programmed in flash, and a few more registers, it can be upgraded to a more powerful, if slow, computer.

Further, these circuits can be directly simulated in an FPGA if you want to teach yourself an HDL like VHDL or Verilog. You really want to learn better and faster ways to organize a CPU, but it's a fun way for a beginner to bridge into this kind of work.

At the local hackerspace, we actually taught a class that assembled a hybrid 8-bit / 16-bit variation of this computer with 1MB of RAM, an 8-bit ALU, a 16-bit data bus / registers, and a 20-bit address bus. With this additional capability, we could program it over serial with a very basic bootloader, and it was powerful enough to compute pi to 1000 digits. Granted, this took about 18 hours, but it could have run faster with a printed circuit board and a crystal oscillator. We just never really got to that point.

As for how powerful such a computer with discrete logic can be, consider that the KB-11A CPU for the PDP-11/45 was built using 74-series logic ICs. It wasn't until after this system that DEC moved on to VSLI. So, this is a way to play with technology found in computers in 1972 / 1973.

As a stepping stone to digital logic and FPGA work, Ben Eater's tutorial isn't bad. Just get yourself a copy of Don Lancaster's TTL Cookbook or CMOS Cookbook to bring his tutorial up to best practices.

Re: Build an 8-bit computer from scratch (2016)

#30
post #13

I did the whole thing, was able to get the Fibonacci numbers appear and learned a lot during the process. However, I would not recommend other people to try this today, because -- * It is not necessarily the best way to spend your time and money. You'll be looking at tens of hours on building it plus over $300 in parts, for a very slow and basic computer that you probably will forget and throw away at some point. Cut…

A game such as Turing Complete will give the same sort of understanding of the fundamentals of computing, although not a physical learning experience.
Post reply on HN