Build every gate from NAND
Build it step by step
0 of 7 donePower and decouple
Fit both chips, the power rails and the 100 nF capacitors.
Add the inputs
Wire the two buttons with pull-downs to nodes A and B.
Build NOT and NAND
Wire chip 1 gates 1, 2 and 4 and watch the NOT A and NAND LEDs.
Build OR
Wire chip 1 gate 3 from the two NOT outputs.
Build AND
Wire chip 2 gate 1 after the NAND.
Build XOR
Wire chip 2 gates 2, 3 and 4 as in the table.
Fill in the truth table
Press every combination of A and B, note the five LEDs and compare with the real gates.
How do you build a build every gate from NAND?
Use only 74HC00 NAND gates to make NOT, AND, OR and XOR, and prove they match the real chips. You need 74HC00 quad NAND gate × 2, Tactile push button 6 mm × 2, Resistor 10 kΩ × 2, LED 5 mm red × 5, Resistor 330 Ω × 5, Ceramic Capacitor 100 nF × 2, Breadboard 830 Tie Points, Jumper wires male to male (40 pcs, 20 cm) and Breadboard power supply module (MB102). It takes 7 steps and about 90 minutes.
- Level
- Intermediate
- Time
- About 90 min
- Parts
- 9
Parts list
- Integrated CircuitsBuy
- SwitchesBuy
- PassivesBuyResistor 10 kΩ × 2
- SemiconductorsBuyLED 5 mm red × 5
- PassivesBuyResistor 330 Ω × 5
- PassivesBuy
- PrototypingBuy
- PrototypingBuy
- PowerBuy
Tick what you already own. It saves to My Garage, so “Build with what I have” knows.
Wiring
| From | To | Why |
|---|---|---|
| MB102 module +5 V | + rail | Supply, jumper set to 5 V |
| MB102 module GND | - rail | Ground |
| Chip 1 pin 14 and Chip 2 pin 14 | + rail | Power |
| Chip 1 pin 7 and Chip 2 pin 7 | - rail | Ground |
| 100 nF capacitors | Pins 14 and 7 on each chip | Decoupling |
| Button A and 10 kΩ pull-down | + rail through the button to node A, resistor from node A to - rail | Input A |
| Button B and 10 kΩ pull-down | + rail through the button to node B, resistor from node B to - rail | Input B |
| Chip 1 gate 1: pins 1 and 2 | Node A, output pin 3 | NOT A |
| Chip 1 gate 2: pins 4 and 5 | Node B, output pin 6 | NOT B |
| Chip 1 gate 3: pins 9 and 10 | Pin 3 and pin 6, output pin 8 | OR, by De Morgan's law |
| Chip 1 gate 4: pins 12 and 13 | Node A and node B, output pin 11 | NAND, also called N1 |
| Chip 2 gate 1: pins 1 and 2 | Chip 1 pin 11, output pin 3 | AND, which is NAND followed by NOT |
| Chip 2 gate 2: pins 4 and 5 | Node A and chip 1 pin 11, output pin 6 | N2 |
| Chip 2 gate 3: pins 9 and 10 | Node B and chip 1 pin 11, output pin 8 | N3 |
| Chip 2 gate 4: pins 12 and 13 | Chip 2 pin 6 and pin 8, output pin 11 | XOR |
| LEDs with 330 Ω resistors (five) | From chip 1 pin 3, chip 1 pin 8, chip 1 pin 11, chip 2 pin 3 and chip 2 pin 11 to - rail | Show NOT A, OR, NAND, AND and XOR |
No code needed
No code. Each 74HC00 holds four NAND gates (pins 1 and 2 to 3, 4 and 5 to 6, 9 and 10 to 8, 12 and 13 to 11). Tying both inputs of a NAND together makes a NOT. A NAND followed by a NOT is an AND. NOT A NAND NOT B is A OR B. XOR needs four NANDs: N1 = A NAND B, N2 = A NAND N1, N3 = B NAND N1, XOR = N2 NAND N3. All eight gates are used. Never leave a CMOS input floating: the pull-down resistors keep A and B at a known low when the buttons are released.
Test checklist
What you should see at each check. If a reading is far off, stop and use the troubleshooting list.
| Check | Expected |
|---|---|
| A and B both released | NOT A on, OR off, NAND on, AND off, XOR off |
| A pressed only | NOT A off, OR on, NAND on, AND off, XOR on |
| B pressed only | NOT A on, OR on, NAND on, AND off, XOR on |
| Both pressed | NOT A off, OR on, NAND off, AND on, XOR off |
If it does not work
Nothing lights
Check chip power on pins 14 and 7 and the LED direction.
One output wrong
Check the pin pairs for that gate and the chip 1 pin 11 links.
LEDs flicker
An input is floating; check the pull-downs.
Outputs dim
HC outputs can drive these LEDs, so look for a short or a missing resistor.
Still stuck? Find the fault step by step with your multimeter →
Common questions
What parts do I need for the build every gate from NAND?
74HC00 quad NAND gate × 2, Tactile push button 6 mm × 2, Resistor 10 kΩ × 2, LED 5 mm red × 5, Resistor 330 Ω × 5, Ceramic Capacitor 100 nF × 2, Breadboard 830 Tie Points, Jumper wires male to male (40 pcs, 20 cm) and Breadboard power supply module (MB102).
How long does the build every gate from NAND take to build?
About 90 minutes for a intermediate maker, in 7 steps.
How do I know the build every gate from NAND works?
A and B both released: NOT A on, OR off, NAND on, AND off, XOR off. A pressed only: NOT A off, OR on, NAND on, AND off, XOR on. B pressed only: NOT A on, OR on, NAND on, AND off, XOR on.
Nothing lights: what should I check?
Check chip power on pins 14 and 7 and the LED direction.
One output wrong: what should I check?
Check the pin pairs for that gate and the chip 1 pin 11 links.
LEDs flicker: what should I check?
An input is floating; check the pull-downs.
Outputs dim: what should I check?
HC outputs can drive these LEDs, so look for a short or a missing resistor.
