Show HN: I made a game where you build a CPU from logic gates
Posted by laurentiurad 2 days ago
I built ChipBuilder to make computer architecture more approachable through interactive puzzles.
You start with basic logic gates like AND, OR, and NOT, then gradually combine them into adders, multiplexers, memory, an ALU, and eventually a complete CPU. Once you've built the hardware, you can write assembly programs that run on the processor you created.
The game is inspired by courses like Nand2Tetris, but everything runs directly in the browser with a visual circuit editor, simulations, and progressively harder challenges.
Comments
Comment by ura_yukimitsu 2 days ago
- You should be able to drag/drop elements from the sidebar onto the canvas
- Wiring shouldn't be a separate tool, and you should be able to drag/drop wires instead of having to click on the two endpoints separately
- You should be able to delete the currently selected gate with the delete key, and the "delete" button in the toolbar should delete the currently selected gate instead of it being a separate tool
- There's not enough contrast between the grid pattern and the background of the canvas
- There seems to be some problems with moving overlapping components
- There's no way to move around the canvas
- The progress doesn't seem to save and there's no way to skip levels
Comment by laurentiurad 2 days ago
Comment by Sohcahtoa82 2 days ago
I'd also like the ability to skip levels. I already know how gates and full adders work. It's just drudgery to get through them.
Comment by Joker_vD 2 days ago
But do you know how an 8-bit Kogge-Stone adder works? Most of the sources I've read are quite unhelpful. I particularly "like" the ones (e.g. Wikipedia) that use some random pictures/diagrams from who knows where that either 1) have completely different symbols from each other and from what the text claims the symbols on the pictures are (e.g. the text talks about black and grey boxes, the pictures have red and yellow triangles); 2) shows a different kind of adder — the article about Brent-Kung adder has a Kogge-Stone diagram instead; 3) very obviously doesn't work the way the text claims it works/does what the text claims it does.
Comment by laurentiurad 2 days ago
Comment by danbruc 2 days ago
- allow drawing wires backwards from sink to source
- allow connecting inputs
Also there is a problem with the tests and the simulator that showed up in the SR latch level. Despite having the correct circuit, the tests failed until I swapped the two NOR gates. I can not reproduce it, but I would guess it has something to do with the component placement order, the update order of the simulator, and how the tests are executed. As the NOR feedback loop has no well-defined initial state, it probably settled in a placement order dependent way that made the tests fail. Maybe Q was already 1 and the test looks for a 0 to 1 transition when enabling S?
Comment by artemonster 2 days ago
Comment by 1718627440 12 hours ago
Comment by orphea 2 days ago
It is such a shame that the words "passion" and "well-crafted" are being actively devalued.
Comment by sk1pper 2 days ago
Also, for people interested in this type of thing, look up Ben Eater’s 6502 videos. Wiring up a 6502 (old microprocessor) to ROM and RAM on a breadboard; later he builds a “world’s worst video card” - more like a VGA display output card, still pretty cool.
Comment by octobus2021 2 days ago
FYI the author started publishing updates again; looks like he took 2 years to rebuild the game from the ground up and instead of launching it as "Turing Complete 2" he chose to simply publish it as breaking update, and is now continuing with updates to add features.
Comment by XorNot 2 days ago
Comment by ksdme9 2 days ago
I have gotten my nephew into it with some success as well.
Comment by dahart 2 days ago
My child just informed me that Turing Complete has just released a major redesign and that the engine is even faster than before.
Comment by agent_z 2 days ago
Comment by baron3dl 2 days ago
When I played through this last year it was surprising how much came back to me from the courses I took in college, and haven't touched at all in 20 years.
Comment by vivzkestrel 1 day ago
Comment by dirkc 2 days ago
Comment by falcor84 2 days ago
Comment by ChickeNES 2 days ago
Comment by vivzkestrel 1 day ago
- https://jaso1024.com/mvidia/ same thing but done differently
- https://nandgame.com/ everyone knows this one
- https://radarlaboratory.com/ shows how radar works like your game
Comment by octobus2021 2 days ago
I advise the readers to check out not only Nand2Tetris but also Turing Complete game on Steam (and hopefully back on GOG at some point). The author came back to it and started posting updates a few months ago after almost 2 year silence. He rebuilt the engine with a huge performance boost and is now adding more and more features.
Not affiliated with him in any way, just think the game is great and his dedication to it deserves respect.
Comment by sebastiansm7 2 days ago
Also it would ne nice to have a level zero where you create the gates from transistors.
Comment by jbgrt 2 days ago
Comment by Elorth 2 days ago
Comment by hddambo 6 hours ago
Comment by vitorfblima 2 days ago
Comment by laurentiurad 2 days ago
Comment by tda 2 days ago
Comment by AspisAiantos 2 days ago
1. Please please please apply `user-select: none;` to everything within the circuit canvas. Almost more often than not I would end up dragging text that had been highlighted rather than any of the actual gates or inputs.
2. Having to switch between 'select', 'wire', and 'delete' modes is a bit cumbersome.
3. Absolutely no progress seems to be saved on navigation or page reload. I've completed the first level several times and if I go anywhere else or reload after completing it, the site shows zero levels completed and shows the tutorial again.
Comment by laurentiurad 2 days ago
Comment by anonymousiam 2 days ago
This game seems to have a similar limitation.
Comment by Kirby64 2 days ago
No you don’t. Once you get to memory you no longer have any tests that do anything and it’s impossible to actually progress.
Comment by prologic 2 days ago
Comment by splittydev 2 days ago
Comment by jodacola 2 days ago
One bit of feedback: I'd love to be able to stare at the tests while I'm playing around with the logic gates; every time I switch to the tests tab then click around on the "board," the tabs switch back.
Comment by wateralien 2 days ago
Comment by laurentiurad 2 days ago
Comment by xpct 2 days ago
Comment by 1718627440 2 days ago
Comment by laurentiurad 2 days ago
Comment by rsprinkle 2 days ago
Comment by astaka 1 day ago
Comment by shadab_khan_127 2 days ago
Comment by laurentiurad 2 days ago
Comment by cadeos 1 day ago
Comment by prologic 2 days ago
Comment by prologic 2 days ago
Comment by aappleby 2 days ago
The "Pipelining" level is completely broken - big completely empty grid, no components to place, and you actually think you're going to learn _pipelining_ in a _schematic editor_?
This is a vibe-coded slop project. Not interested.
Comment by aappleby 2 days ago
You didn't test this thing at all, did you?
Comment by laurentiurad 2 days ago
The post is about the game. When clicking on the Browse button and assuming you can read, you will see a collection of well-crafted products. I am not selling those myself. The website does not process payments, does not ask for donations, nothing like that.
Saying that the ALU example does not have tests is just a lie. I am not sure if you are a liar, or just frustrated about something, or maybe you're having a bad day, but for a person bragging about being an ex-employeeID at a big-tech firm and a GH-contribution-green-dots chaser, you should be more humble and think twice before accusing someone of doing illegal stuff.
Comment by azatom 2 days ago
user-select: none;
Comment by rezigned 1 day ago
Comment by rho4 2 days ago
Comment by drob518 2 days ago
Comment by mrkO99 2 days ago
Comment by prologic 2 days ago
Comment by namero999 2 days ago
Comment by Kirby64 2 days ago
Also, the later puzzles (starting with memory) don't have any real tests. Seems like it just doesn't really exist past that point.
Comment by asterisk_man 2 days ago
Comment by Kirby64 2 days ago
Comment by jpl56 1 day ago
Comment by kovacs_x 2 days ago