### Elements of Computing Systems - Chapter 3 - Understandings

Great book and I am proud to own one!

These are my understandings and summary from Chapter - 3.

Sequential Logic
• All the Chips we have built so far were: Combinational Chips
• Combinational Chips can not maintain state.
• Sequential Chips can maintain state.
The Clock
• In computers, time is represented by a master clock
• The current clock phase is represented by a binary signal.
• Using the hardware circuitry, the signal is broadcast to every sequential chip in the platform.
DFF: Data Flip Flop
• DFF consists of a single - bit data input and a single - bit data output.
• DFF has a clock input, that continuously changes according to the Master Clock 's signal.
• DFF outputs the input value from the previous time unit!
Registers
• A Register is a device that can store (or remember..) a value over time.
• Here is my 1 - Bit Register implementation in my own hand drawing:

• The "select bit" of the Multiplexor becomes the "load bit".
• If load = 1, muxOut = b = in.
• If load = 0, muxOut = a.
w - Bit Registers
• 1 - Bit Register is hardly useful for us.
• Lets pack 16 register into one chip, either load 16 of them at once or read 16 of them at once.

• w - Bit Register is has a w-bit bus as input (in[w]) and w-bit but as output (out[w]).
• It only has 1 load bit. Either 16 bits are loaded at once, or read at once.
• We lost the ability to load or read a 1 - Bit Register
• The Multi - Bit Contents of Registers are referred to as: words

#### Memory

• Once we have the ability to represent words, we can build memory banks, by stacking up w - Bit Register.
• Here is a nice sketch that shows a Memory unit:

I was also nice enough to draw a sketch of a 32 - Bit Memory module, that consists of 2 16 - Bit Registers.

And finally, my implementations for the Chips that will be used for the Heck Computer:
```CHIP Bit {
OUT out;

PARTS:
DFF(in=muxOut, out=out, out=a);
}

CHIP Register {
OUT out;

PARTS:
}

CHIP RAM8 {
OUT out;

PARTS:
Mux8Way16(a=aa, b=bb, c=cc, d=dd, e=ee, f=ff, g=gg, h=hh, sel=address, out=out);
}

CHIP RAM64 {
OUT out;

PARTS:
Mux8Way16(out=out, a=o1, b=o2, c=o3, d=o4, e=o5, f=o6, g=o7, h=o8, sel=address[3..5]);
}

CHIP RAM4K {
OUT out;

PARTS:
Mux8Way16(a=outa, b=outb, c=outc, d=outd, e=oute, f=outf, g=outg, h=outh, sel=address[9..11], out=out);
}

CHIP RAM512 {
OUT out;

PARTS:
Mux8Way16(a=outa, b=outb, c=outc, d=outd, e=oute, f=outf, g=outg, h=outh, sel=address[6..8], out=out);
}

CHIP RAM16K {