Transistor Logic Gates

In a previous post you learned about the operation of basic logic gates. But how do we actually translate those diagrams into something that we can manufacture?

Inverter

The Inverter uses a single transistor to act as a switch between a voltage source and a ground. If the input is high, the output is zero. If the input is low, then no current flows through the transistor and the output is at the high voltage.

AND Gate

The AND gate is a little more complicated but still easy to understand. Each of the transistors act as switches. The way that they are arranged only allows current to flow from the voltage source to the output if both of the transistor “switches” are on, that is if both A and B are high. When either A or B are low current doesn’t flow to the output which remains at zero.

NAND Gate

This is one way to represent a NAND gate, as an AND gate with an inverter attached on the end. This is a good conceptual way to visualize a NAND gate but there is a better layout that we could use.

This layout is functionally equivalent but uses fewer transistors. If you remember a NAND gate outputs a high signal at all times unless both inputs are also high. In this layout the only way to get the output signal to be low is to turn on both of the transistor “switches”. It’s always good to try to minimize the number of transistors used in an implementation.

OR Gate

This OR gate has two transistors connected in parallel. The output of one transistor doesn’t affect the output of the other one. Therefore if either A or B is high, then the output will be high.

NOR Gate

This is another implementation of a NOR gate that consists of a combination of an OR gate and an Inverter but we can improve this one too.

This is a cleaner implementation of the NOR gate. It takes fewer transistors and therefore uses less power and space.

XOR Gate

This implementation of an XOR gate is a more complicated design. The two transistors Q1 and Q2 each implement an inverter. The transistor pairs Q3,4 and Q5,6 both implement AND gates, and the last pair(Q7, Q8) implement an OR gate. This shows how different logic gates can be chained together to create more complicated logic.

XNOR Gate

This gate implementation takes the NOR gate and then adds an Inverter to the output to form an XNOR gate. Can you find a better layout for this?

Combinatorial Circuits.

What we just did was make a combinatorial logic circuit. These are circuits that are comprised of a number of logic gates that are arranged to produce a specific output. These form the basic building blocks for digital computers. In further posts we will go into the design methods on how to take an arbitrary desired behavior and encode it in an arrangement of logic gates.