Relay node hangs sometimes when toggling a fan
-
Hi,
I have a sensor node driving a fan and sometimes when toggling the relay the node locks up. I am using a nano board and when it locks up the TX led stays solid.
The relay board is opto isolated. I have done some research about the interference that can be caused by a relay switching a motor, but I don't understand the solutions and given its 240v I don't want to make changes to the 240 side unless I fully understand them.
I have tried swapping out the radio, the nano and the relay.
I have not been able to reproduce the fault when the fan is disconnected.
My skills are quite basic so any simple advice would be very much appreciated!
Chris021
-
Do you feed the relay from your arduino?
-
I have D3 signal low to trigger the relay. The same 5V source powers the relay, but this works fine if no load is connected.
-
-
I've the same problem with a 4 relay board. After a few times switching on and off, the Atmega hangs.
Especially if more than one relay on the board is switched.I'm currently swithing the power source.
-
@BulldogLowell im using one of these onto the 5v pin of the board:
I have also tried feeding it via USB of a 2.1 amp supply with the same results.
-
So you are powering both the relays and the arduino in parallel from the transformer?
have you tried isolating the arduino's power from the transformer with a capacitor?
the power surge of the relays (even though you have an opto-isolator from arduino to relays) may cause issues for the arduino.
perhaps start with a regular 4.7ยตF across the Vin and ground of the arduino
-
its worth a try, however this works 100% fine when there is not a fan connected I might try a different AC device to see if that is just as reliable as no AC device connected.
-
@chris021 said:
however this works 100% fine when there is not a fan connected
motors draw a tremendous amount of current when they start... Try isolating the arduino's power from the transformer, or using the capacitor.
-
@BulldogLowell I have powered it off an external battery pack. Same story!