Settings

Theme

I made Ben Eater's 8-bit breadboard computer Emulator in C++

github.com

112 points by 0xhh 5 years ago · 12 comments

Reader

hamandcheese 5 years ago

If you haven’t seen Ben Eater’s YouTube videos, they are top-notch. Even if you “know” the subject material (I thought I did...) they are very well done and worth watching.

  • globular-toast 5 years ago

    Definitely. I made the real thing in hardware. As a complete beginner to electronics it took me quite a long time but it was so worth it. I've always hated having to accept the existence of "magic" in my machines. For me this was the final layer that allowed me to finally understand how electronic computers actually work. Things like building flip flops from scratch were so insightful. And if that's not enough he's got videos on how transistors work at the atomic level. It's like the whole of computer science finally fell into place.

    • ryeguy_24 5 years ago

      100% ditto minus the building it myself. Through ben's videos I finally understood how instructions really work and how a program is executed. Despite being a tech fanatic, I'm have so much more appreciation now for what is actually happening.

JazzXP 5 years ago

I was thinking about doing this myself (but in Javascript, coz that's what I'm using day to day at the moment), and literally implementing each module of the board as a seperate piece of code.

bhhaskin 5 years ago

This is a neat little project. Thanks for sharing!

jgwil2 5 years ago

Should be marked "Show HN," no?

dangrie158 5 years ago

Nice, I built a version in python with curses visualization of all states. It emulates all chips ob the hardware level (chips.py) and does not need any dependencies except py3.7: https://github.com/dangrie158/SAP-1/tree/master/Emulator

  • scaramanga 5 years ago

    Cool!

    I didn't go as far as implementing the CPU, but watching his vids inspired me to write a circuit emulator, also in python:

    https://github.com/giannitedesco/primula

    I used it to emulate all the various flip flops, but I was thinking of building a computer in it.

  • lodovic 5 years ago

    That looks really nice, how is the speed? I did the same in C#, and implemented it up to bus and transistor level. I could execute a Fibionacci program in asm but it was horribly slow (less than 1M instructions/sec)

    • sokoloff 5 years ago

      Worth noting that the Apple ][ and C64 had a 1.023MHz clock rate with a minimum of 2 cycles per instruction, so your “horribly slow” system might be about real-time for the era.

      (Atari 800 had a 1.77 or 1.79MHz clock, but wasn’t regarded as wildly different.)

  • klelatti 5 years ago

    Thanks. This looks like an amazing (teaching / exploratory) resource.

    Just one question - couldn't immediately see a license file?

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection