Electronic – Understanding the working of a NAND GATE using NMOS Transistors

circuit analysisdigital-logicnmosresistorstransistors

I'm having incredible difficulties understanding how the "Switching Behaviour" (not sure if that's the correct English translation- in German it is "Schaltverhalten") for NMOS and PMOS transistors actually work. I understand the theoretical part of both of them but now how to take boolean expressions and turning them into transistor logic circuits. Here is the NMOS for a NAND GATE, where Z indicates that it's in a floating state, the bold blue line indicates that the source-drain is set to High, the bold black line indicates that the source-drain is set to Low:

NMOS NAND GATE

I'll explain my understanding using the first image, with both gates set to Low. The current for NMOS flows from the source to the drain. You have two "inputs" i.e. two NMOS transistors that are connected to each other with the original drain gate of the bottom transistor connected to the source of the upper transistor. When both the inputs are set to Low, the NMOS is turned off which means that there is no current flowing through the circuit. Since there is no current flowing through the circuit, the "connection line" between the two transistors is in a floating state . However, what I don't understand is why there is a resistor at the top (and why its input is set to High) and how this results in a High output for the entire circuit.

Best Answer

The resistor you see there is called a "pull-up" resistor. The circuit you show can provide a low level at the output, when the NMOS are ON (in the first circuit). But when they are OFF, the pull-up resistor will provide the high level. The transistors by themselves in that circuit, can't provide a high level, only a low one.

Now, as shown no current flows through the pull-up resistor, and that is why the output node stays high. In practice, if you were to connect something to that output, then some current will flow through the pull-up resistor and may drop the high level accordingly, but in most cases probably not enough to cause the output node to be considerably lower than the high level.

When dealing with CMOS logic, you need a pull-up and a pull-down network such that you can get highs and lows. In this case, the pull-down network has been implemented with NMOS transistors while the pull-up has been implemented with a resistor. More typically you will see a PMOS in the pull-up network rather than a resistor.