Minimum possible setup for small watering project

Hi there. I am a software engineer, but I am totally out of my depth as I need to put together a hardware module -- quickly.

Components:

Moisture sensor

This is how you connect it:

Water level detector

image

Solenoid (the 6V version, but apparently it will work fine with 5V too)

I need to hook these up in the simplest possible way so that I can get programming.

The first two (moisture and water level sensors) are quite simple I will take the 5v from the Arduino to a breadboard tail, and power the water level and the sensor with that. That's the easy part

The solenoid... help.I assume I will need a relay module. Something like this. I would hook it up to the 5v from the breadboard, and then switch it on or off as I need to.

The solinoid only needs less than 400ma. The sensors even less (around 30ma) each. So I should be totally within the 800ma for the board. But... am I missing anything here? Am I doing something really stupid?

Bonus question: what's the simplest way to run this using batteries, and small solar panels to recharge them? They will be in sunshine every day. So my idea is to prevent a million cables, and use a battery recharged by the sun for perpetual use.

400mA will certainly burn out the Uno. You will need a separate power supply for the solenoid.
The relay module should also be connected to the separate supply

400mA will certainly burn out the Uno

Bugger... OK, good to know.
Can I take the 6V from the same cable that provides power to the Uno? That is, can I piggyback myself "in parallel" to power the switch?

So the power would look like this:

  • The standard 5V/1A (maybe I need more than 1A?) power supplier to the Arduino Uno, going straight to the power rails on the breadboard (is it crazy to do?)

  • Then power the Arduino with the 5V from breadboard

  • Power the relay module with the 5V from the breadboard

  • Power the sensors also from the 5V from the breadboard

...would that work? Would 1A be enough?

Do you mean 5V?

I do sorry. I think the solenoid will also work with 5V.

Please tell me that my idea is sound and doable :smiley:

Please first read the section on Power under FAQs

Simplest way is to power every thing from 12V and drive the solenoid at about 50% PWM to keep the voltage down. Use a power driver board instead of a relay board.

https://www.amazon.com/Apowery-Monocrystalline-Maintainer-Controller-Extension/dp/B08T9VZDFT/

Please first read the section on Power under FAQs

Please confirm that I understand this correctly:

  • when using an external power source, I MUST supply between 7V and 12V. The power supplier that came with it was 5V... go figure! That's why I was confused

  • At this point I will need to buy a 12V power supply to supply the Arduino, and I CANNOT use the 5V pin to supply the solenoid, since 400ma is too much, right? The specs for the solenoid say <2.5W. Not sure this helps

So... what's my best option here?

Could this work:

  • Buy another solenoid, something that will work with 12V
  • Buy another power supply, 12V
  • Cut the power supply wire, and have in parallel the Arduino cable and the 12V rail of the breadboard
  • Supply the sensors from the 5V from the Arduino (they use zero power)

Sounds like a good idea? (please say yes...!)
I could get a solenoid that needs 12V,

https://www.amazon.com/Apowery-Monocrystalline-Maintainer-Controller-Extension/dp/B08T9VZDFT/

Do I need such a big amount of power for an Arduino board powering two super-light controllers and opening a solenoid maybe once a day for 10 seconds?

I would buy a 9V adapter and a 5V buck regulator. Connect the 9V to the Uno Vin or barrel jack and to the 5V buck. Use the 5V buck output to power the relay and solenoid

Do you know how long the device will take to dry out and tell you the water level is below the end of the sensor? Might be important. Or are you making the assumption the sensor will be able to tell you the exact level of the water the sensor in immersed in?

I haven't gotten that far yet. I will check the water level, and will only open up the solenoid once it's been under a certain level for X hours. To refill, I will let water in and will stop the intake once the water level reaches a certain amount. I will need to check what "certain amounts" means -- I will know once I have the sensors connected...

These items might help with your project

All you need now is a 5V buck converter

No, but this the first time you've mentioned that!

Thank you for your help!

You are welcome

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.