Wiring – Acceptable “3-way” switch wiring solution

lightingwiring

I would like to use a raspberry PI to turn lights on remotely from a raspberry PI.

Wiring Diagram http://imstarboard.com/grachen.png

In this diagram, I am proposing 2 paths for completing the AC circuit and therefore turning the lights on: 1) the lightswitch, and 2) the relay controlled by the raspberry pi (orange wiring).

I know that this isn't a true 3-way switch, meaning that if you turn the lights on using one method you can't turn them off using the other method, but it does allow me to turn them on using either method when the lights are off.

Are there any concern with doing this?

Best Answer

I'm not sure what type of relay you're using, but most relays have at least five terminals. two coil terminals, used to power the coil. One common (C) terminal, where the circuit to be controlled will connect. One normally closed (NC) terminal; which is as it sounds, the side of the switch that is closed when no power is supplied to the coil. And one normally open (NO) terminal, the side of the switch that is open when no power is supplied to the coil.

When power is supplied to the coil, the relay is toggled. The NC contact will now be open, and the NO contact will be closed. This is fairly similar to how 3-way switches work, except that with a 3-way you are the coil (sort of) and determine which way the switch is.

Because of this, you could wire up a circuit like this...

Raspberry pi connected to 3-way switch

However, this setup isn't going to be very smart, since the Raspberry pi is simply going to be switching the current state of the load. So whether the lights go on or off, will depend on the state of the 3-way.

To make this system smarter, you can add in a current transformer (CT), and connect the leads from the CT back to the pi.

Raspberry pi connected to 3-way switch with CT

With this setup, the pi can use the output of the CT to determine the state of the lights. So the pi could either toggle the relay to turn the lights on/off, or not toggle the relay to leave the lights on/off. In any event, the 3-way switch would still work properly.

I don't know much about the Raspberry pi, so I'm not sure it has the ability to work in this way. I also don't know exactly what equipment you're using. I'm simply suggesting a possible solution.