Logic circuits form the very basis of digital electronics. Circuits including the AND, NAND, OR, NOR and exclusive OR gates or circuits form the building blocks on which much of digital electronics is based.
The various types of electronic logic gates that can be used have outputs that depend upon the states of the two (or more) inputs to the logic gate. The two main types are AND and OR gates, although there are logic gates such as exclusive OR gates and simple inverters.
For the explanations below, the logic gates have been assumed to have two inputs. While two input gates are the most common, many gates that possess more than two inputs are used. The logic in the explanations below can be expanded to cover these multiple input gates, although for simplicity the explanations have been simplified to cover two input cases.
AND and NAND gates
An AND gate has an output that is a logical "1" or high when a "1" is present at both inputs. In other words if a logic gate has inputs A and B, then the output to the circuit will be a logical "1" when A AND B are at level "1". For all other combinations of input the output will be at "0".
A NAND gate is simply an AND gate with its output inverted. In other words the output is at level "0" when A AND B are at "1". For all other states the output is at level "1".
OR and NOR gates
For an electronic OR gates the output is at "1" when the input at either A or B is at logical "1". In other words only one of the inputs has to be at "1" for the output to be set to "1". The output remains at "1" even if both inputs are at "1". The output only goes to "0" if no inputs are at "1".
In just the same way that a NAND gate is an AND gate with the output inverted, so too the NOR gate is an OR gate with its output inverted. Its output goes to "0" when either A OR B is at logical "1". For all other input states the output of the NOR gate goes to "1".
One other form of OR gate that is often used is known as an exclusive OR gate. As the name suggests it is a form of OR gate, but rather than providing a "1" at the output for a variety of input conditions as in the case of a normal OR gate, the exclusive OR gate only provides a "1" when one of its inputs is at "1", and not both (or more than one in the case of a gate with more than two inputs).
The final form of gate, if indeed it could be categorised as a gate is the inverter. As the name suggests this circuit simply inverts the state of the input signal. For an input of "0" it provides an output of "1" and for an input of "1", it provides an output of "0". Although very simple in its operation, these circuits are often of great use, and accordingly they are quite widely used.
|Logic Truth Table|