Building a computer, using only nand gates. My quest to learn computer architecture! Below are my short notes. Please note my up-to-date learnings can be tracked on Twitter: https://x.com/shreybirmiwal/status/1832816031355580427
We put together the PC, ALU and registers together. Control bits coming from instruction enable/disable inputs, outputs, and saving of outputs. This is getting really interesting and exciting!

First, let's make the memory unit. We already created the individual chips - just need to combine RAM16k, a Screen Map section, and a register for keyboard input.
We can use the same DMUX/MUX 'fanning out' method as earlier to achieve this:

Now that we have sufficient prerequest chips, let's start planning and putting together the full computer architecture. See the attached picture for plan
Instead of making an assembler first, I jumped to making machine language programs to understand where we are heading.
In assembly, wrote programs to make the screen black on key press, multiply numbers & flip variables. My Notes:

Starting with flip flops and dmux/mux chips made previously, we created a bit that retained memory across time!
8 bits -> 1 register -> ram8 -> ram64 -> ram256 -> ram4k -> ram16k by scaling multiple previous chips
Using the XOR and AND chips from p1, I created a half adder (bit1 + bit2 = sum, carry bit)
Then, using multiple half adders, created a full adder (bit1 + bit2 + carry bit = sum, carry bit)
Addition -> multiply, divide, subtract (full ALU!)

I created elementary logic gates from the original NAND gate. Ei: NOT was created by NAND(input, input) and AND was created by NOT NAND. Now, we had gates like XOR, AND, OR, DMUX, MUX16, etc ready for use in future chips!

