Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
I Designed My Own 16-Bit CPU [video] (youtube.com)
149 points by peter_d_sherman on July 28, 2022 | hide | past | favorite | 23 comments


If you think this is cool and would like to follow these steps yourself, here are my recommendations:

* Turing Complete on Steam (if you're into video games): https://store.steampowered.com/app/1444480/Turing_Complete/ * The Elements of Computing Systems (if you'd rather follow along step by step in a book):https://www.amazon.com/Elements-Computing-Systems-second-Pri...


The Elements of Computing Systems is the book behind nand2tetris. I’ve done the course a few times on Coursera. The astro-8 (the computer in the video from this post) uses microcode in the CPU but nand2tetris just uses instructions whose bits directly drive the cpu. Although I do like how nand2tetris shows how layers of abstractions can be arbitrary, and even simpler than they are usually done in the real world, and you can still build on top of them using additional layers of abstractions. Even in the first step, instead of using different gates you only use nand and then create the needed logic gates from that. And the machine language it uses is at a microcode level and you build a stack language on top of that. (And then build an Java like language on top of that.)


Check this one out: https://store.steampowered.com/app/1885690/Virtual_Circuit_B...

It focuses on performance, and looks quite beautiful.


Turing Complete is maybe more a tutorial in digital logic coming with its own simulator than a game.

It is designed to feel like a puzzle game and is distributed on Steam but that's only the surface...

Building your own CPU and programming it in your own assembly language is exactly what TC promises on the tin.

The "game" discord server may be worth checking also.


I forgot to say that TC simulator aims to high performance. That makes it more fun to use than Logicsim even if the feature set is more limited for now.


Turing Complete looks great! I've been looking for games that fit the "Edu-tainment" niche for a while and haven't found many good ones for adults.


Try Zachtronics games (Shenzhen I/O, Exapunks, TIS-100) and https://www.nandgame.com/ too!


Amazing!!


Also consider MHRD[0], which is similar to nandgame, except you write your designs out in a (primitive) HDL starting with just NAND gates and working up to a functional CPU. Like the zachtronics games, it blurs the line between "game" and "work" just the right amount.

[0](https://store.steampowered.com/app/576030/MHRD/)


Very nice, and 16 years old, that person will go places.


One bit per year!


Oh to be 0b10000 again!


I watched this yesterday. I had no idea he was just 16. Fantastic!


Yup.


More like "I designed my own 16-bit computer system".


That's nice. What tool is he using for the gate-level simulation?



I used logisim in my digital logic class and enjoyed it quite a bit. I love that it’s still getting attention and upkeep


Well logisim is dead, but evolution is a fork and then there's Digital https://github.com/hneemann/Digital which is I think a reimplementation of Logism's concepts?

I also hand designed a custom 16 bit CPU in logisim, because I was struggling to understand Nand2Tetris's HDL as well as I liked, and also because I stopped following the curriculum to go my own way. Logisim has a few hang ups, starting with a rather low upper bound on clock speed, completely single threaded simulation, and no process for PLL or similar clock multiplying strategies so if you want to do internal processor management or microcode based implementations, you will be stuck with an even lower fraction of that clock speed. The UI is slightly clunky by modern standards, debugging complicated circuits is less than fun, and the file format is less than great if you want to do anything more than no version control and only touching it with logisim



related series on building a bread board computer: https://www.youtube.com/playlist?list=PLowKtXNTBypGqImE405J2...



This is very impressive!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: