Go Down

Topic: Arduino lighting system with backup board (Read 3940 times) previous topic - next topic


Hi everyone,

I'm starting the design of a home lighting system controlled by an Arduino board. We'll see if UNO is enough or I'll have to move to the Mega. Since the Arduino is going to be the heart of the system, a failure in the board would drive the whole system down and leave the house with no lights available until replaced. So I'm thinking that it might be interesting putting two boards to work together. One would be the working board, and the other one would be a hot backup that would catch up the control in case the main one died. Has anyone have experience with this? Any project that uses this kind of configuration you might have heard of? Any suggestions as kickstar?

Thanks in advance.


Why not a manual override for the lights?


Hi there,

Thanks for the reply. I missed something in my previous message. The wire layout is already done, and there's no 220V wiring reaching the switches, only DC Cat-5 wire. To activate the power circuits manually I would need to set up another system with would be much more difficult to build than having two Arduinos working together. I have thought something like using logic gates at the exit of the Arduino's or using a three state buffer that in that case would be controlled manually. Is something like that what you suggest?



How about a schematic?
Would the 2 arduinos be seperately powered? Battery backup or something?
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.


I'll try to upload an schematic ASAP (that means a couple of days), but the layout is very simple. In the mean time, think of a set of n DC switches wired to the Arduino inputs, a set of k outputs from the Arduino that control a board of relays/dimmers wired to 220V light circuits in accordance with the inputs. If a relay fails, no problem. One light circuit goes down but I still have lights in the house. If a swith fails, no problem neither. But, if the Arduino fails the whole system goes down having no connection between the DC switches and the AC 220V power lines. In that case I could go to the box where the Arduino is going to be housed and replace it with a new one, but that can take maybe hours to do (housing will be under a false ceiling and you need to get a ladder, open the access panels and so). I want something faster and easy to do. If I put two Arduino boards integrated in the system, having the same inputs, outputs and software, I can easily switch from one to the other with a manual override (as previously said) or on automatic. Anything doable in a matter of minutes will be fine.

No need for battery backup since if mains are down there's no need for light control. Power supply for the boards have to be independent, since the failure could come from the supply, too.


The arduino will not fail if you are not overloading any of the output pins. Its a  pretty durable chip.
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.


Ok, you might be right in that, but not all threats need to come from within of the Arduino. Let's imagine the inconceivable, an external damage (a mouse bites the supply cord, a water leakage gets through or, why no, there's a flaw in one of the components of the board, etc.)

The thing is, the cost of the board is negligible compared to the cost of the whole electrical installation, so if there's a way of doing something easy putting two boards, one as hot and the other as backup, why not do it. I have done some research and I know now more than I did yesterday. The option of having a set of three state buffers controlled by an external switch that changes from one Arduino to the other (even switching power supply too) is so far the one that fits best.


I would suggest both part's outputs be buffered then, so the outputs can fail Hi or Lo  and not make it thru the buffer to impact the other board's output.
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.


how about making the logic of the arduino so that in case it fails, output is LOW, then all the relays are DEACTIVATED and this closes the 220Vac circuit so all light will turn on.

I believe it is safer to fail with light so you can continue with your normal life, than all in darkness.

Also, you could prepare a manual switch board that could replace the arduino board by unpluggin the arduino and plugging this board and then you have manual control of each light. of course, a good recomendation would also be as you say, to have an identicall arduino ready in case the one working fails.


I hadn't thought about that but seems not a bad idea. Not for the whole of the lines but a estrategic light circuit that gives surviving light to the kitchen, for example, can be wired that way and be a signal of something going wrong. You don't wanna have 1000 watts of light flooding your house at 4am if that's the time of the failure, especially if you have kids or visitors! :) I'll leave that for a "panic mode" lighting released with a rapid keying of any switch. Thanx any way, to you and the rest of contributors so far.

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131