Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. My Project
  3. Battery-powered irrigation controller

Battery-powered irrigation controller

Scheduled Pinned Locked Moved My Project
47 Posts 13 Posters 17.6k Views 14 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    user2684
    Contest Winner
    wrote on last edited by
    #3

    Using a solar panel can be for sure a good alternative but I wanted something without this requirement since where I have to put this I don't have a good exposure and I'm always afraid the battery cannot recharge in a good way.
    Thanks!

    1 Reply Last reply
    0
    • gohanG Offline
      gohanG Offline
      gohan
      Mod
      wrote on last edited by
      #4

      Is the node going to sleep?

      1 Reply Last reply
      0
      • U Offline
        U Offline
        user2684
        Contest Winner
        wrote on last edited by
        #5

        Absolutely, otherwise cannot survive for long I'm afraid. I'll put it to sleep for e.g. 5-10 minutes and with smart sleep I'll send the on/off command when online, at least this is the plan

        gohanG 1 Reply Last reply
        0
        • scalzS Offline
          scalzS Offline
          scalz
          Hardware Contributor
          wrote on last edited by scalz
          #6

          @user2684
          that's a cool project :+1:
          I have built a device like this, batt operated custom board, but not finished sw and enclosure for the moment (too much projects). I'll use it in my garden soon as seedling has started too here.
          I also have solar charging option on my board.

          1 Reply Last reply
          0
          • U user2684

            Absolutely, otherwise cannot survive for long I'm afraid. I'll put it to sleep for e.g. 5-10 minutes and with smart sleep I'll send the on/off command when online, at least this is the plan

            gohanG Offline
            gohanG Offline
            gohan
            Mod
            wrote on last edited by
            #7

            @user2684 can't you use like 4 relays to supply voltage with different polarity? 2 give pulse for opening and 2 give pulse to close. Maybe not as neat and tidy as the H Bridge but it may do the job without voltage drop.

            U 1 Reply Last reply
            0
            • gohanG gohan

              @user2684 can't you use like 4 relays to supply voltage with different polarity? 2 give pulse for opening and 2 give pulse to close. Maybe not as neat and tidy as the H Bridge but it may do the job without voltage drop.

              U Offline
              U Offline
              user2684
              Contest Winner
              wrote on last edited by
              #8

              @gohan you're right, a set of relays could definitely do the job, good alternative thanks for the advice!

              1 Reply Last reply
              0
              • S Offline
                S Offline
                Samuel235
                Hardware Contributor
                wrote on last edited by
                #9

                @gohan - I'm struggling to determine why you would prefer to use 4 relays rather than a H-Bridge. If the device is a simple pulse activated device then i don't see any reason to use a relay over a H-Bridge. Is there a specific reason why you would and i'm not aware of that characteristic?

                Or am I not following your project plans properly?

                MySensors 2.1.1
                Controller - OpenHAB (Virtual Machine)
                Gateway - Arduino Mega MQTT Gateway W5100

                1 Reply Last reply
                0
                • U user2684

                  Hi, this is still a work in progress but I wanted to share the approach I'm aiming to for a battery-powered irrigation controller in case can be useful to somebody else.

                  Since I have no way to power a device in my garden, I cannot use neither an electrovalve nor a traditional relay controlling a valve (would drain the battery while staying on).

                  I then found the following solenoid valves which works at a low voltage (3.6V) and requires just a pulse to switch (you may find the same also on amazon):

                  • http://www.ebay.com/itm/Plastic-Toilet-Closestool-20mm-Male-Thread-Bi-stable-Pulse-Solenoid-Valve-/162277805621?hash=item25c882ce35:g:DCcAAOSw3ihXTc9L
                  • http://www.ebay.com/itm/Toilet-Closestool-20mm-Male-Thread-Bi-stable-Pulse-Solenoid-Valve-DC-3-6-/332118670306?hash=item4d53d0bbe2:g:ll8AAOSwA3dYlHDN

                  The principle behind is to switch with positive/negative pulses which I've discovered means simply connecting the two wires to vcc and gnd to open and reverse the wires to close.

                  All good but when I tried to control this with two arduino pins, there was no way to have it working and the reason simply is the solenoid requires a LOT of current (I've measured between 0.6 and 1A) which is of course way more than what the board the provide.

                  After some googling I've discovered I needed a H-bridge (http://www.instructables.com/id/H-Bridge-on-a-Breadboard/?ALLSTEPS) to control programmatically the valve. I've tried building mine on a breadboard with different transistors/resistor but the valve didn't switch due to a massive voltage drop. Once gain due to the current draw.

                  I then bought the following and everything looks working just fine:

                  • https://www.aliexpress.com/item/2-DC-motor-drive-module-reversing-PWM-speed-dual-H-bridge-stepper-motor-Mini-victory-L298N/32648692160.html?spm=2114.13010608.0.0.lvAQ6C

                  I still need to build the rest but this looks like the easy part since I just need to connect the arduino board to IN1 and IN2 and use simple HIGH pulse to open or close.

                  Thanks

                  gohanG Offline
                  gohanG Offline
                  gohan
                  Mod
                  wrote on last edited by
                  #10

                  @Samuel235 it is in the first post where he is saying the H bridge didn't work
                  @user2684 said in Battery-powered irrigation controller:

                  After some googling I've discovered I needed a H-bridge (http://www.instructables.com/id/H-Bridge-on-a-Breadboard/?ALLSTEPS) to control programmatically the valve. I've tried building mine on a breadboard with different transistors/resistor but the valve didn't switch due to a massive voltage drop. Once gain due to the current draw.

                  1 Reply Last reply
                  0
                  • scalzS Offline
                    scalzS Offline
                    scalz
                    Hardware Contributor
                    wrote on last edited by scalz
                    #11

                    In my circuit, I'm not using h-bridge nor relays and i can also control higher voltage solenoid valves like rainbird.. (i'll post my project later),
                    but imho, I think the H-bridge should work, that depends on resistors values or the circuit was not optimized. 4 relays is a bit gorgeous maybe, but if it works, then it's the most important :)

                    gohanG 1 Reply Last reply
                    0
                    • scalzS scalz

                      In my circuit, I'm not using h-bridge nor relays and i can also control higher voltage solenoid valves like rainbird.. (i'll post my project later),
                      but imho, I think the H-bridge should work, that depends on resistors values or the circuit was not optimized. 4 relays is a bit gorgeous maybe, but if it works, then it's the most important :)

                      gohanG Offline
                      gohanG Offline
                      gohan
                      Mod
                      wrote on last edited by gohan
                      #12

                      @scalz sometimes you've got to use what is available and 4 relays usually are laying around somewhere :D

                      1 Reply Last reply
                      0
                      • S Offline
                        S Offline
                        Samuel235
                        Hardware Contributor
                        wrote on last edited by
                        #13

                        Well I brushed over that because i don't see how a H-Bridge wouldn't work due to high voltage drops. They use these ICs for motors and are fine with that and hence why I kind of brushed over that first point.

                        I was thinking more in terms of a new product being made for people, relays wouldn't be the best option for a few reasons, one being cost. However, if its just a few products for yourself then its fine obviously :)

                        MySensors 2.1.1
                        Controller - OpenHAB (Virtual Machine)
                        Gateway - Arduino Mega MQTT Gateway W5100

                        1 Reply Last reply
                        0
                        • U Offline
                          U Offline
                          user2684
                          Contest Winner
                          wrote on last edited by
                          #14

                          Just to share how the finished project looks like in the picture below. I'm powering it with 3 AA batteries (4.5v) since the solenoid valve would not trigger when below 3v. In the picture you can see on the right side the pro mini and the RFM69 radio, on the left the H-bridge module in red and a mini board with a voltage regulator to provide 3.3v to the arduino and the radio and a 1M/300K voltage divider to feed an arduino's analog pin. I have two valves connected to the H-bridge so I'm using 4 pins to control them (pulse on/pulse off for valve 1, pulse on/pulse off for valve 2). On the code side, with NodeManager (https://www.mysensors.org/download/node-manager) I have the following configuration:

                            nodeManager.setBatteryMin(3.2);
                            nodeManager.setBatteryMax(4.6);
                            nodeManager.setBatteryInternalVcc(false);
                            nodeManager.setBatteryPin(A1);
                            nodeManager.setBatteryVoltsPerBit(0.00459433);
                            
                            nodeManager.setSleep(SLEEP,1,MINUTES);
                          
                            // open valve 1
                            nodeManager.registerSensor(SENSOR_LATCHING_RELAY,6);
                            // close valve 1
                            nodeManager.registerSensor(SENSOR_LATCHING_RELAY,7);
                            // open valve 2
                            nodeManager.registerSensor(SENSOR_LATCHING_RELAY,8);
                            // close valve 2
                            nodeManager.registerSensor(SENSOR_LATCHING_RELAY,9);  
                          

                          The board sleeps for one minute, then reports back (with smart sleep of course) and the controller sends a SET message with payload 1 to the relevant child id to control the valves when instructed. On this side with myHouse (https://www.mysensors.org/controller/myhouse) I can activate it manually or schedule the duration of the irrigation for each zone.

                          Here's the pictures (as you can clearly see I'm really bad with hardware so I tend to wire everything up without soldering so I can reuse all the components if needed or, more likely, if the project fails :P):

                          0_1495272963282_Untitled.png

                          0_1495273153423_Untitled1.png

                          1 Reply Last reply
                          0
                          • gohanG Offline
                            gohanG Offline
                            gohan
                            Mod
                            wrote on last edited by
                            #15

                            Don't worry about the wire mess, it is normal when building a prototype (breadboards and jumper wires exist for a reason :) )
                            So the node every minute checks if any commands have been sent to switch on or off the valves, right? How much battery life are you getting? I guess it will depends on how much time the valves are on. In theory you could swap the AA batteries with a 18650 to save some space, right?

                            U 1 Reply Last reply
                            0
                            • gohanG gohan

                              Don't worry about the wire mess, it is normal when building a prototype (breadboards and jumper wires exist for a reason :) )
                              So the node every minute checks if any commands have been sent to switch on or off the valves, right? How much battery life are you getting? I guess it will depends on how much time the valves are on. In theory you could swap the AA batteries with a 18650 to save some space, right?

                              U Offline
                              U Offline
                              user2684
                              Contest Winner
                              wrote on last edited by user2684
                              #16

                              @gohan that's correct, I'm using exactly the same principle in my boiler controller with the sensor checking in periodically for new commands since battery powered. I do expect a decent battery life since the valves I'm using are pulse-based so it doesn't matter for how long they stay on (as in my boiler controller I'm using a latching relay and since January moved from 3v to 2.75 now.). And yes, 18650 would be ideal for this project. Only concern with that battery is that when the solenoid triggers, it draws a lot of current and I'm not 100% sure a rechargeable battery is as good as a standard one to handle it.

                              1 Reply Last reply
                              0
                              • gohanG Offline
                                gohanG Offline
                                gohan
                                Mod
                                wrote on last edited by
                                #17

                                as rule of thumb 18650 can deliver continuous 2C, so they could take a higher load for a brief moment (depends how long those valves take to open or close)

                                U 1 Reply Last reply
                                0
                                • gohanG gohan

                                  as rule of thumb 18650 can deliver continuous 2C, so they could take a higher load for a brief moment (depends how long those valves take to open or close)

                                  U Offline
                                  U Offline
                                  user2684
                                  Contest Winner
                                  wrote on last edited by
                                  #18

                                  @gohan thanks good to know, I will give it a try, a 3 AA pack is actually using too much space!

                                  1 Reply Last reply
                                  0
                                  • gohanG Offline
                                    gohanG Offline
                                    gohan
                                    Mod
                                    wrote on last edited by
                                    #19

                                    Remember that lithium batteries suffer heat, so put the box in shade :)

                                    U 1 Reply Last reply
                                    0
                                    • gohanG gohan

                                      Remember that lithium batteries suffer heat, so put the box in shade :)

                                      U Offline
                                      U Offline
                                      user2684
                                      Contest Winner
                                      wrote on last edited by
                                      #20

                                      Oh didn't know that, I'll stay with the 3 AA batteries then for now since the box is in full sunshine and can become pretty hot during summer time at this latitude ;-) Thanks

                                      1 Reply Last reply
                                      0
                                      • TmasterT Offline
                                        TmasterT Offline
                                        Tmaster
                                        wrote on last edited by Tmaster
                                        #21

                                        That's an interesting project!
                                        how are these valve working after almost a month of work?some bi-state valves have reputation of get stuck opened or closed. They are cheap enough to i like them if the don't get stuck :)

                                        And what about time to control the valvs. Are you requesting from gateway?
                                        For power you can use a 4v or 5 v solar panel to charge 1 li-io cell with this charge regulators((https://cdn.instructables.com/FSH/L5F0/IO0G95Y5/FSHL5F0IO0G95Y5.MEDIUM.jpg?width=614)) if regular batteries have poor life, and of course you can hide battery box under a flat rock or a tile because sun heat.

                                        There are common 9v valves that are bi-state as well ,like the ones used on rain bird 9v programmers

                                        my irrigation controller (24v Ac controlled by 5v Dc) its about to be presented here as well soon :) i'm finishing tests on attached sensors and stability tests and upload on emoncms.com

                                        i'm a arduino fan .Even sometimes don't undestanding how to use it :P

                                        U 1 Reply Last reply
                                        0
                                        • TmasterT Offline
                                          TmasterT Offline
                                          Tmaster
                                          wrote on last edited by Tmaster
                                          #22

                                          And about selenoids ,this is how i control them:
                                          0_1495452921961_upload-d313d700-aca7-4ad8-8a3d-94079bc0972a

                                          on arduino pwm pins you can define how much voltage you send to solenoid with "analogwrite" .
                                          You can use any mosfet or transistor that can handle the 3.5v 1a(buy double or triple value of curente for safe)

                                          i'm a arduino fan .Even sometimes don't undestanding how to use it :P

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          20

                                          Online

                                          11.7k

                                          Users

                                          11.2k

                                          Topics

                                          113.1k

                                          Posts


                                          Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • MySensors
                                          • OpenHardware.io
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular