Hi,
in my project I run into a problem I cant' understand no more.
I've a Arduino Nano driving a standard commercial 4-relais board plus some other devices (PWM-Board, Nanopixel-LED, ...) with a regulated power capable of 1 amp (so I'm running not on the Nanos regulator). The circuit draws 30..40 mA without the relais, these require 70 mA each, so the power supply should be sufficient. Most of it works fine, but...
When the Nano switch a certain Relais (it happens with Ch-2 and Ch-3), it hangs in a way, that the watchdog timer reset can't restart the board, even the manual switch don't restarts the board. A Power OFF-ON cycle however brings it back to live. With the wachdog active, the Pin13-LED starts to flicker, without the watchdog nothing happens at all, its just stopped. Without this failure at the first hand, however the Reset-Button works as expected, also downloading a new schetch is no problem. That' actually the fist thing I don't understand. What kind of failure can create such behaviour, and what is the difference of the Reset (watchdog or button) vs. a power cycle.
The second question is, why it happens at all? It happens every 2nd time or so, and only with 2 out of the 4 relais. Changing the Nanos DO to the relais shows that it is related to the relais and not to the DO, so the same DO gets this problem with relais Ch-2, but not Ch-1. In the cases when the swiching is successfull without a stall, it stays alive infinite, so I don't think that there is a short or something similar.
The scetch itself is quite long, so I dont post it here. I rather think it is an electrical issue than software. Howe
Has anyone observed something like this before? I'm realy looking for some advice.
Thanks a lot, Olaf.
Prove to yourself where the problem is by writing a simple program that operates the relays similar to how it is done in your big program, just remove all the other stuff.
If it does the same in the simple program, swap the relays with the ones that don't give the problem. Does the problem follow the swap?
Weedpharma
Hi,
Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?
What are the relays that cause the problem switching, what is their load?
Thanks.. Tom..... 
Hi,
attached is now a schematic of the circuit. The relais in question have weak 5..15 W 230VAC motors as load. The relais itself are simple 5VDC, 300 Ohm relais suitable for 230VAC and 10A.
I did as proposed and tested a very simple scetch, it worked well -> so it's just software? I removed just the connections to the two critical relais and it worked just as well -> so it's electrical? I'm completely lost.
Any idea why a restart by button don't work?
Thanks, Olaf

An additional remark: in that commercial 4ch-relay-board the free wheeling diodes are of the mini-MELF type as a LL914 or 4148. In my own designs I would use 1A plastic diodes for this purpose. However the transistors are still alive. Should I add some big bypass-C on the Nanos power supply?
By the way, the long scetch works fine with just the two critical relais disconnected.
Best regards, Olaf
Sorry for my some what chaotic posting, however the ideas came while I wrote. I tested the following: Long software, critical relais disconnected -> everything fine. I supplied 5V manually to the relay simply with a wire bridge from the power supply to the transistor base resistor, the relay energizes and with the deenergizing of the relay the board hangs. To me this now realy looks like a power surge (I hope that's the right word in English). Any fix to that? A capacitor and a series resistor for the Nano?
Greetings, Olaf