Electronic – Add a relay to an existing switch

relayswitchestransistors

I want to add a relay or transistor, what fits the need best, to a simple switch, so I can control the switch by a micro computer but also keep the already installed switch so I can still operate the mechanism by hand.

Here a little sketch of what I thought of (sorry, I'm new to electronics so forgive me if this is a dumb question :D)

sketch

(on the left side is the current situation and on the right side is what I thought of, the blue box is the "electronic switch" (transistor, relay, ..), I didn't add its control wires to keep the sketch simple.

As long as the "box" can handle the load this should work, right? Am I missing something here or is it safe to start building?

Edit:
I'm thinking of 2 scenarios here:

1st: Add a remote controlled power button to my pc (since it's a small DC a small transistor would be enough). Of course I would have to turn it off again after a few milliseconds.

2nd: Add a relay to a light switch (230V AC), but here I could have the problem winny mentioned (if one switch is on, the other one cant turn it off), so this wouldn't be the first application to start

Best Answer

Your proposed solution works for half the problems. The additional relay (that's what I recommend given the scant information about the load) is logically ORed with the switch. If either is on, then the overall switch is on. For the overall switch to be off, both the original switch and the relay need to be off.

Wiring the relay in series with the switch flips this around. Now the on-states of the two are ANDed instead of ORed. Both have to be on for the overall switch to be on.

If you are OK with one of the two above, then yes, just wire the contacts of a relay as you show (logical OR), or in series (logical AND) with the existing switch.