Logic Gates – OR Gate vs Connecting Two Wires

logic-gates

I am not much of an electrical person but I'm trying to get an idea about it, so keep in mind I have very little background outside of college level electrical physics with calculus, and a strong basis in mathematical logic. I was learning about things you can make with logic gates and came across an adder. I like to give things a try before I look at the answer, so I came up with my own adder. The only difference between my adder and the one in the book I'm reading is that there's an OR gate at the end of their adder for the carry out wire, whereas I just put two wires together. It seems to me that putting two wires together is identical to an OR gate, as there is no electricity out of the node if there's no electricity in, and there is some electricity out of the node if there is some in from either or both sources.

My question is: What is the difference between putting two wires together and making a proper OR gate?

My guess is that it has something to do with the amount of electricity (current?) on the output wire from the 3-node/OR gate, but my understanding of circuits is a bit rusty. Thanks for your help!

schematic

simulate this circuit – Schematic created using CircuitLab

Best Answer

What you have to understand is how logic level H and L are represented. Both logic levels H and L are represented by two voltages, i.e. L does NOT mean floating potential or "not connected".

L means the voltage is (close to) 0V, i.e. connection to GND.

And of course H is indicated by a higher voltage, e.g. 5V, i.e. connection to positive supply voltage.

So if two digital outputs have different values (H and L) connecting them would cause a short circuit, not an OR gate.

In very most cases in digital logic connecting two outputs together is wrong.

Exceptions are

  • so-called tri-state outputs which can be in a third state "Z". Z actually means high impedance, i.e. "no connection" and
  • so-called open collector (or open drain) outputs which can be AND-wired (similar to what you wanted to do for OR). But then you need an additional pull-up resistor.