Diode logic (or diode-resistor logic) constructs AND and OR logic gates with diodes and resistors. An active device (vacuum tubes with control grids in early electronic computers, then transistors in diode–transistor logic) is additionally required to provide logical inversion (NOT) for functional completeness and amplification for voltage level restoration, which diode logic alone can't provide. Since voltage levels weaken with each diode logic stage, multiple stages can't easily be cascaded, limiting diode logic's usefulness. However, diode logic has the advantage of utilizing only cheap passive components.
Background
Logic gates Logic gates evaluate Boolean algebra, typically using electronic switches controlled by logical inputs connected in parallel or series. Diode logic can only implement OR and AND, because inverters (NOT gates) require an active device.
Logic voltage levels Main article: Logic level § 2-level logic Binary logic uses two distinct logic levels of voltage signals that may be labeled high and low. In this discussion, voltages close to +5 volts are high, and voltages close to 0 volts (ground) are low. The exact magnitude of the voltage is not critical, provided that inputs are driven by strong enough sources so that output voltages lie within detectably different ranges. For active-high or positive logic, high represents logic 1 (true) and low represents logic 0 (false). However, the assignment of logical 1 and logical 0 to high or low is arbitrary and is reversed in active-low or negative logic, where low is logical 1 while high is logical 0. The following diode logic gates work in both active-high or active-low logic, however the logical function they implement is different depending on what voltage level is considered active. Switching between active-high and active-low is commonly used to achieve a more efficient logic design.
Diode biasing Forward-biased diodes have low impedance approximating a short circuit with a small voltage drop, while reverse-biased diodes have a very high impedance approximating an open circuit. The diode symbol's arrow shows the forward-biased direction of conventional current flow.
Diode AND and OR logic gates Each input of a diode logic gate connects through a diode connected to a shared wired logic output. Depending on the voltage level of each input and direction of the diode, each diode may or may not be forward-biased. If any are forward-biased, the shared output wire will be one small forward voltage drop within the forward-biased diode's input. If no diode is forward-biased then no diode will provide drive current for the output's load (such as a subsequent logic stage). So the output additionally requires a pull-up or pull-down resistor connected to a voltage source, so that the output can transition quickly and provide a strong driving current when no diodes are forward-biased. Note: the following circuits have two inputs for each gate and thus use two diodes, but can be extended with more diodes to allow for more inputs. At least one input of every gate must be connected to a strong-enough high or low voltage source. If all inputs are disconnected from a strong source, the output may not fall within a valid voltage range.
Active-high OR logic gate
Each input connects to the anode of a diode. All cathodes are connected to the output, which has a pull-down resistor. If any input is high, its diode will be forward-biased and conduct current, and thus pull the output voltage high. If all inputs are low, all diodes will be reverse-biased and so none will conduct current. The pull-down resistor will quickly pull the output voltage low. In summary, if any input is high the output will be high, but only if all inputs are low will the output be low:
This corresponds to logical OR in active-high logic, as well as simultaneously to logical AND in active-low logic.
Active-high AND logic gate
This circuit mirrors the previous gate: the diodes are reversed so that each input connects to the cathode of a diode and all anodes are connected together to the output, which has a pull-up resistor. If any input is low, its diode will be forward-biased and will conduct current, and thus pull the output voltage low. If all inputs are high, all diodes will be reverse-biased and so none will conduct current. The pull-up resistor will quickly pull the output voltage high. In summary, if any input is low, the output will be low, but only if all inputs are high will the output be high:
This corresponds to logical AND in active-high logic, as well as simultaneously to logical OR in active-low logic.
Real diode considerations
For simplicity, diodes may sometimes be assumed to have no voltage drop or resistance when forward-biased and infinite resistance when reverse-biased. But real diodes are better approximated by the Shockley diode equation, which has a more complicated exponential current–voltage relationship called the diode law. Designers must rely on a diode's specification sheet, which primarily provides a maximum forward voltage drop at one or more forward currents, a reverse leakage current (or saturation current), and a maximum reverse voltage limited by Zener or avalanche breakdown. Effects of temperature and process variation are usually included. Typical examples:
Germanium diode: Max forward voltage at 10 mA = 1 volt @ 0 to 85 °C Max reverse leakage current at 15 volts = 100 microamps @ 85 °C Silicon diode: Max forward voltage at 10 mA = 1 volt @ 0 to 125 °C Max reverse leakage current at 15 volts = 1 microamp @ 85 °C
Transient response Diodes also have a transient response that might be of concern. The capacitance between anode and cathode is inversely proportional to the reverse voltage, growing as it approaches 0 volts and into forward bias.
… excerpt ends here. Continue reading the full article.




![Diode logic: Cascaded AND-OR gate. High 5V level is reduced twice.[2] The OR diode's VF drops ~0.6 V and the AND's pull-up forms a voltage divider with the OR's pull-down.](https://thumb.wikimedia.org/wikipedia/commons/thumb/9/9c/Cascaded-AND-OR-diode-logic.svg/330px-Cascaded-AND-OR-diode-logic.svg.png?utm_source=en.wikipedia.org&utm_campaign=parser&utm_content=thumbnail)
