Classroom Public page

Week 1: Boolean Logic

515 words

The course begins with one bit. By the end of the week you have built a 4-bit ripple adder out of NAND gates on a breadboard and understood why a NAND gate is enough to build any logic circuit ever made.


Reading

Lecture

lectures/ch1-boolean-logic-lecture.md. 3 hours. Key arc:

  • Why one bit. Why Boolean values. The flashlight as the smallest circuit
  • AND, OR, NOT as switch arrangements. Truth tables as the contract
  • NAND universality. Any circuit can be built from NAND alone
  • De Morgan's laws as electrical equivalences (Petzold weave anchor)
  • Forward pointer to Ch 2: adding two bits is the first useful circuit

Lab exercises

Five labs in worksheets/ch1/. Pick the ones that match your equipment access (full breadboard kit; or browser-only via the workbench).

Plan for ~5 hours of lab. Browser-path students do labs 1.3 + 1.4 in the workbench; bench-path students do the full discrete-logic build-up.

Independent practice

  • Read the three Petzold weave anchors carefully. Note the page numbers and theses; they recur throughout the course
  • Start your Toolchain Diary at ~/student-repo/toolchain-diary.md per worksheets/TEMPLATE-toolchain-diary.md. Week 1 introduces: breadboard, multimeter, logic probe (or workbench equivalents)
  • Optional: read nand2tetris Ch 1 if you have a copy. Same structural arc; different idiom

Architecture comparison sidebar

Why NAND is universal in every silicon family ever shipped. Every transistor-level CMOS gate the planet manufactures inherits the same universality theorem you just demonstrated on the breadboard. Patterson-Hennessy and Petzold both anchor here for the same reason: it is the smallest reusable claim in computing.

Reflection prompts

  1. The flashlight has one switch and one light. The 4-bit ripple adder has dozens of gates. What stayed the same about the engineering across the scale-up?
  2. If NAND is universal, why did your kit include AND and OR chips? What pressure decides which gates the silicon vendor packages?
  3. Petzold spent Ch 4 to Ch 11 building toward gates. We arrived at the same place in one week. What did Petzold's slow climb give the reader that our compressed version did not?

What's next

Week 2 takes the 4-bit ripple adder you just built and grows it to a 32-bit ALU. Same engineering ideas; one order of magnitude bigger.