Indoor Irrigation System with ESP32 Relay and 12V Peristaltic Pumps - Tips and Advice?

Hi everyone,

I’m working on building an indoor irrigation system for my plants using the Kincony KC868-A6 ESP32 relay and peristaltic pumps. I’ve worked with ESP32 and ESPHome before, but only for small projects where a simple 5V phone charger was enough to power everything. Now, I’m stepping up to a larger project and could use some advice on the wiring and power supply setup to ensure everything runs smoothly and to make sure I’ve got things right! As I have no experience with relays, I want to make sure if this setup is right and if anyone could provide any tips or recommendations?

Project Details:

  1. Hardware:

  • Power Supply: 1x 12V, 2A (shared between the relay and pumps)
  • Wiring: AWG 20 wire for connecting everything
  1. Goals:
    • I need to run 3 pumps simultaneously and potentially expand to 4 pumps later. If my calculations are correct (with 3/4 pumps: 15W/20W, 1.25A/1.67A at 12V), it should be fine. However, since electronics is not my strong suit, i wanted to check it with you guys.
    • I am unsure about the feasible length of the wires and tubing. Ideally, I would have about 3m tubing per pump and short (<=20cm) electrical wiring. Since I am not entirely confident in this setup, I have listed more detailed questions below.

Questions and Issues:

  1. Can someone check my wiring setup?
    • I’ve attached a diagram of my wiring setup below. I’m connecting the DC power supply (12V, 2A) to the KC868-A6 relays 1-3 (+ to power the board itself), and from there, I’m wiring the pumps using the relay outputs (NO terminals). All components share the same GND from the power supply. I want to confirm that my connections and wire placements are correct. Any feedback would be appreciated!

  1. Is the power supply sufficient?

    • With the current setup (3 pumps), the total power draw is 15W at 12V (1.25A). This seems safe within the 2A limit of my power supply. However, if I add a fourth pump, it will bring the total to around 1.67A. Is this too close to the 2A limit, considering factors like surge currents? Should I upgrade to a higher current power supply for stability?
  2. Connecting Multiple Inputs to One DC Power Supply:

    • My 12V DC power supply has only two output wires (VCC, GND), but I need to connect it to the KC868-A6 relay board and all the pumps. What is the best way to split these connections? I’m considering using a bus bar, terminal block, or a Wago connector (like this). Has anyone had better luck with one method over the other, or is there a recommended product for this?
  3. Wire Length Considerations:

    • How long can the VCC and GND wires be without significant voltage drop? I understand that the wires connecting the power supply VCC to the relay common terminals don’t need to be long, as these connections will be grouped together near the relay.
    • Similarly, the wires to power the relay itself will be short and close to the power supply.
    • However, how long can the GND to the pumps and the Relay NO to pumps wires be? The pumps could be located up to 2 meters away, depending on the feasible length of the pump tubing. Is this distance acceptable, or would I encounter issues with voltage drop or current limitations?
  4. Tubing Length for Peristaltic Pumps:

    • On the off-chance that anyone has experience with this: how long can the tubing of a 50ml/min flowrate pump with 3mm inner / 5mm outer diameter be while still maintaining stable water delivery? I am planning for a total tubing length of 3 meters, but I want to ensure this is feasible.

Thanks in advance for any insights or tips you can offer. I’d love to hear from anyone who has experience with similar setups! :smiley:

Forgot to mention the Pump is advertised as 5W, 0.25A and 12V. I don’t really understand how that fits together so i just took the 5W 12V Specification as that is what it says on the Pump itself and ignored the 0.25A.

I wouldn’t choose 2A power supply. Calculate 1A just for that relay board. Every relay takes 0.5-1W and all 3.3V electronics have to be regulated down from 12V (lost in heat).
Also, when pumps start they draw more than nominal current.
So 3A minimum, but higher would be better. Or even better, separate PSU for Esp32 board.
You need flyback diodes for your pumps.
Wiring looks correct, and if you wire every component with separate 20AWG wire like in you scheme, you don’t have to worry about voltage drop etc.

1 Like

This entirely depends on the wire size.

I think this board is overkill, but if you can integrate it into Home Assistant or flash ESPHome to it, OK.

Thanks for the advice :smiley: I’ll use a seperate PSU for the Relay Board then!

Great never head of them before but seems sensible to use them after a quick Google check :smiley:

They would be needed directly at the pumps like in this image right?

Any chance you have a prefered solution for this? As a total noob it seems the linked clamp connector would be easiest :smiley:

Easiest is the one in photo. I don’t know how you are connecting wires to your motor…
Anyway, just make sure the diode is from negative to positive.

I would just solder them like in the picture yeah :smiley:

The clamp connector would just be to “split” the wires from the PSU to the relay and pumps :smiley:

Thanks for your help! Greatly appreciated!

Ah, ok. For low currents it should be fine. For higher I would use just common screw connectors.

1 Like

Yeah the board is a little overkill :smiley: But i liked the LoRa Option for the future and that it already had a case :smiley: And yeah it’s ESPHome-flashable.

Ok i think I am fine with the AWG 20 wire that if a voltage drop of about 2% is ok. At least thats what the voltage drop calculator said and i read everything under 3% should be ok :smiley:

Thanks for your help!

Yep, you could have done it with Esp devboard and 4ch motor driver module. :wink:

Do they provide an API for the LoRa? And GPIO ports used for the ESPHome integration?

Note- No matter what you do now, six months on it will be completely different.

No not currently but one can hope :smiley: But yeah i get it’s an overkill solution and i will keep that in mind for following relay projects :smiley: