I'm generally a pretty smart person, but for some reason I can't get my head wrapped around this one.
A little background - I have performed this function before using two diodes and two SPDT relays. It works fine, but is bulky and wastes some money. I did it with logic gates and one SPST relay. That was super fun and a learning experience. It worked, but didn't last long.
I have seen it written that the same thing can be done with either: A - a rectifier bridge, or; B - a rectifier and a some resistors
If I am using the correct specs for the components, either option would be smaller and cheaper and just as robust as the relay and diode method. And, if I am reading the specs on the components right the relay isn't even needed.
I have no problem spending a few bucks to build something and letting the magic smoke out of some components and finding out it won't work. What I do have a problem with is the fact that I just do not see how this works?
Which of these is correct? Can you please help me understand how this would work? Am I right that the components can be spec'd heavy enough to leave the relay out? Are the resistors necessary, and if so how do you calculate the required values?
If this can really be done with a $1.28 rectifier rated at 100V, 20A that would save a lot of hassle and space. But, I really just want to understand why and how?!
It's easy to see how you would get power to the LED when either input high, but how does the output circuit get back to ground? What causes it to not get power when both inputs are high?
I have spent quite a bit of time researching this and just can't manage to explain it to myself...
(BTW - please ignore the fact that the LED doesn't have a protective resistor, this is just for the purpose of me understanding how this works, not an actual design.
EDITS made as suggested...