Hi, I am building a project for microgreens grown using an Arduino UNO R3, the code is finished and working, right now I am having problems with the hardware, the system consists of:
two-channel relay module 5V 10A-250VAC
AC/DC power adaptor 12V - 5A
12V water pump that will spray water three times a day (90mA)
12V LED light strip one and a half meter-60W that will illuminate 15 hours a day
Float water level switch to indicate the water tank level LOW with a 220ohm resistor
LCD 4x20
The Serial Monitor shows the steps with only the relay connected, like LED ON-OFF and PUMP ON-OFF at the correct times.
When I connect the LED lights and the Pump to the relay, the UNO crashes in less than two minutes; when the LED and Pump are ON the LCD dims and blinks fast.
I am using a 2 meters wire to connect the pump, LED lights, and the water level individually.
I already change the UNO board, the relay, and the wires to check if they were defective; also tried to use one AC/DC adaptor for the LED strips and another one for the pump, but UNO still crashes.
Post a schematic, a few project images, the full sketch in code tags, a few images of your project all wired up and NOT working, and any error messages the serial monitor may be showing, please.
What does "crashes" mean?
--- when using the FAN the system runs as expected. but when I put the Water pump at the first action to ON, the Arduino does not accepts any inputs in the LCD, and the LCD Blinks with all stranger characters rolling.
---I already change the pump as well I have three here all the same.
What do you mean running from the breadboard? The relay is connected to the arduino by 5V and the current to run the pump and light is from a power supply that is not connected to the breadboard neither the arduino.
If you can run with the fan and not the pump, I agree with @Idahowalker that you have a power problem.
How is the Arduino being powered? Put as large a capacitor as you have across the supply.
It does not look like the relay is in the opto isolated configuration where the primary side is driven from separate 5v supply. See this tutorial on the JD-Vcc jumper removal.
Hi cattledog, thanks for the tutorial, I did not isolated the 5V yet I will try as soon as I return home in three days. That is a good idea. Can I use a like iPhone charger to power the Relay?
I change Arduinos and still does not work, right now I am using Arduino UNO.
I already tried the capacitor (picture zoomed below) I have at home larger capacitor if you think necessary.
I change the relay connection to this one to troubleshoot (picture zoomed below)
I see the power rails of the bread board connected to 5v and ground pins on the Arduino. All the other 5v devices are also connected to those rails. Where is all that power coming from?
Also, can you get the relays and the 12V lines further away from that rats nest of Dupont connectors? I wonder if you're picking up interference when the pump is turned off.
I will get rid of this connections, and the breadboard as well...
I will be back home on the 16th.
I will let you know after I make all changes and try again.
Thanks