Electrical – Home automation: Adding relays in series vs parallel

arduinohome-automation

Recently I bought an Arduino Uno to discover electronics. I am a computer science student, hence the programming part is not a problem, however, I lack some knowledge about electronics.

Now I want to do some simple home automation, mainly to control the lights in my house. I was thinking about adding an Arduino controlled relay (in the central electrical box of my house) for each light I want to control.

However, for each light in my house I have a switch. Suppose, I'd add Arduino controlled relays in series with the switch (as in the figure below):

enter image description here

The problem is that with the relays being in series, I can only switch on and off the light if the switch is closed. Hence, like above, the switch is open and my Arduino controlled relay will have no effect.

Now, suppose I'd add the Arduino controlled relays in parallel:

enter image description here

In parallel, we observe the inverse problem. If the switch is open, we are able to control the light using the Arduino controlled relay. However, if the switch is closed (like above), the current will flow through it anyway, i.e. the light will glow without the Arduino controlled relay having any effect.

How does one tackle this problem in home automation systems, without the need to rewire my entire house?


PS : Excuse me if the diagrams are wrong in some way. I absolutely have no electronics background.

Best Answer

How does one tackle this problem in home automation systems, without the need to rewire my entire house?

Well, you can't avoid a bit of rewiring. The circuit you need is this: -

enter image description here

Either switch (relay or manual switch) can reverse the situation and fully control the light. I might also add that you cannot know whether your relay has activated the light or deactivated it. However, if you sensed current you could determine if the lamp had turned on providing the lamp is working. Call it extra functionality if you want.

An alternative way of wiring it is like this: -

enter image description here

Functionally it behaves as an exclusive-or gate.

If you want to add a relay to an existing installation that already does this you need a 2 pole changeover like this one shown in the middle: -

enter image description here

In fact you can continue to add 2 pole changeover switches to your heart's content to give you the same functionality but controlled from multiple positions.

Related Topic