XOR Gate – Logic Gates Tutorial

The XOR gate is a logic gate the place the output goes HIGH (or “1”) if one – and just one – of its inputs are HIGH. XOR stands for Unique-OR. Take a look at its image and fact desk under.

XOR gate truth table and symbol

The logic or Boolean expression for an XOR gate is A oplus B = Q which implies that:

If A and B are totally different from one another, then Q is true

Fact Desk

XOR gates are often discovered with simply two inputs. If both of the 2 inputs is 1, whereas the opposite is 0, then the output turns into 1.

Stated otherwise, the output is HIGH solely when its two inputs aren’t the identical.

XOR Gate Fact Desk

XOR gate symbol
Enter A Enter B Output Q
0 0 0
0 1 1
1 0 1
1 1 0

IC Alternate options with XOR Gates

CD4070 Pinout

If you wish to experiment and construct circuits with XOR gates, you’ll discover them in each the 4000 IC collection and the 7400 IC collection:

  • 4030: 4 XOR gates
  • 4070: 4 XOR gates
  • 74HC86: 4 XOR gates (HC is the household, can be LS/HCT/…)

These ought to all be obtainable as hobbyist-friendly through-hole chips. Simply be sure you purchase the DIP bundle model.

XOR Gate Instance Circuit: Toggle Flip flop

You should utilize the XOR for plenty of issues. Beneath is an instance circuit with an XOR and a D flip flop to create a Toggle flip flop.

As an alternative of setting the flip flop to 1 or 0, which is what you’d usually do with a d flip flop, you’ll toggle the flip flop at any time when the enter is HIGH. So if Q was HIGH, it will likely be LOW. If it was LOW, it will likely be HIGH.

Toggle flip flop circuit

Subsequent Step within the Logic Gates Tutorial

Take a look at the opposite articles on this logic gates tutorial:

NOT Gate/Inverter
AND Gate
OR Gate
NOR Gate
XOR Gate – (You’re right here)

Again to the Logic Gates Overview


Leave a Reply

Your email address will not be published.