Checkout the schema diagram, Code and full list of Parts in the related article: github.com/SmartThingsDIY/arduino-uno-aws-irrigation-system Also, I'm moving all my electronics related video to their own channel for more focus, join me here and say Hi kzbin.info/door/PLAcnOvckpVvFvzqWvUakw
@tedharrelson38693 жыл бұрын
Thank you for this video, the instructions and code are great and it worked perfectly once set up properly! One thing to note for others trying this is the Arduino itself also needs a power supply (not indicated in the wiring diagram). I thought I had set it up wrong when it wasn't working until I realised that was the issue. Trying it out on a couple of plants before expanding the system. Have you tried setting this up outdoors or only indoors? Definitely want to try the WiFi version once I'm comfortable with this set up. To power the pumps I'm using a power bank. To connect it, I took an old USB phone charging cable, cut the wires and wired positive and negative as indicated on the wiring diagram (using cable connectors where needed, not tape). You then connect the USB cable to the power bank. works like a charm and there's likely enough juice to last a good long while. If others looking to do this are complete newbies to programming for Arduino (like I was before starting this), I recommend watching Paul McWhorter's tutorials (search Arduino Tutorial on youtube). You only need to go up to tutorial 15 I think to understand enough of the basics to set this up.
@WinTheCloud3 жыл бұрын
I'm humbled by your comment. I've indeed forgotten about including the power supply for the Arduino and I'm glad you caught it. I'll pin your comment for visibility for others.
@Presso993 жыл бұрын
Yes, Paul McWhorter's tutorials !!!! I had just started learning Arduino, I am watching his videos...
@keanutype08963 жыл бұрын
@@WinTheCloud Hi! i wonder why did you use Relay? sorry i never use relay on my project before
@WinTheCloud3 жыл бұрын
@@keanutype0896 The relay is there to open/close a water pump's circuit: When readings find that a plan soil is dry, the corresponding water pump needs to pump water, and that's achieved through the relay. It's like a switch you control with the Arduino code
@dreacleoson16093 жыл бұрын
@@WinTheCloud hello im same as him. but i dont know about the pump. do i really need to use Relay? is there other alternative? sorry i havent done any water pump related project and project related to relay as well
@top10s9903 жыл бұрын
Great Video. I need some help. In every video people have been using the usb cable to power up the arduino. I have a 5V-1 amp adapter. When i am using the 5v adapter, the relay's led is working but solenoid valve doesn't close or open. but when i use usb cable, it works. so i used 12 v 500mA adapter to power arduino and it works again. I have a question, why it is;t working with 5v adapter?
@daily_socialcredits2 жыл бұрын
the simplest and cheapest out there on youtube. Great work!
@WinTheCloud2 жыл бұрын
Wow, thank you for your support!!
@alyaaahmed44623 жыл бұрын
Which simulator did you use for the diagram?
@juneltuazon75842 жыл бұрын
Is it possible to have 4 soil moisture sensors and a single pump?
@WinTheCloud2 жыл бұрын
I don't see why not, you just need to find a way to redirect the water flow to your plant
@marcinrylko24992 жыл бұрын
How long do you expect it to work until corrosion decays the sensor in the soil?
@WinTheCloud2 жыл бұрын
Mine been working for nearly a year
@deepinside94772 жыл бұрын
He's using the capacitive sensors. They last much longer than the traditional ones.
@mohamadiqmalhakimbinmohdes94083 жыл бұрын
thanks for doing this video. for info, i did the same project as for my final year project and your video really helped me a lot. thanks
@WinTheCloud3 жыл бұрын
Great to hear! Thanks Mohamad!
@sonnyscavuzzo43973 жыл бұрын
Hi Great Video, if i wanted only one water pump can i do that? Thanks
@WinTheCloud3 жыл бұрын
Yes, absolutely. In this case, one relay would be enough, no need to get the 4 channel relay I included
@azeansaufie96783 жыл бұрын
can i know how to download the capacitive soil moisture to the protues library ? i couldnt get the library link for capacitve soil moisure sensor V2
@looool-x5h2 жыл бұрын
hi bro can i have a closer look of the battery holder at 5:15? Please reply sir. Tyvm
@looool-x5h2 жыл бұрын
closer look of where the wires are connected to, thanks
@WinTheCloud2 жыл бұрын
I don't have this project running anymore, unfortunately, but this is the switch I used for power: amzn.to/3zAtoFk and this is the wiring diagram github.com/SmartThingsDIY/arduino-uno-aws-irrigation-system hope this helps
@looool-x5h2 жыл бұрын
Ahh ok thanks for the reply anyway
@looool-x5h2 жыл бұрын
Hi, at 1:01 i see that there are 4 wires connected to one, may I know how does that work? also the battery holder 1 wire separated to 4.
@ssdsdsds90352 жыл бұрын
can i use the chirp plant watering alarm for this tutorial pls help
@WinTheCloud2 жыл бұрын
Hi, I actually never used Chirp, so I'm not sure
@DJMovit3 жыл бұрын
I like the layout, If I can figure out how to add an LCD display to show what the four plants are doing...Dry, Wet or pump on or off. I am curious that as you water the pot and the probe gets a flow of water then turns off the pump are you really watering the plant enough? or is it over time that the soild will be come moist enough that the plant won't need water for longer periods of time? Just asking as to me it seems the plants not getting enough water. Again I like your layout and thanks for sharing it, greatly appreciate it.
@WinTheCloud3 жыл бұрын
It's true this device helps automate the process but it's a home DIY not tested nor calibrated for different temperatures, plants, seasons... So I add some water manually every now and then when I feel like it became a bit dry, just as a precaution...
@genebathan25173 жыл бұрын
Hello, may I ask if what batteries you will recommend for it to last long especially when I want to leave it open always.
@WinTheCloud3 жыл бұрын
I mean you can definitely use a LiPo rechargeable battery. This one for example, but it has only 600 mAh : www.amazon.ca/gp/product/B0795F139D I'm sure you can find higher capacity ones
@NikoService2873 жыл бұрын
You can use an external battery. Like those used for charging phones, in combination with a small sollar panel and u will never need to recharge. Fully automated sysetm
@laurentiujinga55583 жыл бұрын
Be aware of the end delay... it may set your relay ON and 5 seconds later will read the sensor again... it may be to much water, if you have a small pot. And another thing. Find a way to power your sensors ONLY when you read sensorValue. Keeping your sensor powered all the time will destroy your sensor through electrolysis. Try some transistors, 2n2222 or alike, to power the probes when you're reading the value. Then you can check once a hour.
@WinTheCloud3 жыл бұрын
Thanks for the advise. I was thinking of connecting the sensor to a digital output pin rather than a power pin, then only send power to that pin when I want to read sensor data
@laurentiujinga55583 жыл бұрын
@@WinTheCloud actually the advice is for those sensors with 2 elements. This kind of sensor it is better, still you can protect it's sides with some nail polish and electronics with some shrink tube. There's a video about this. I think Analog is better. I didn't got the kit for it yet, but I start on the code. I will put it up on github. It will also have qled display 128/64 ssd1306.
@WinTheCloud3 жыл бұрын
@@laurentiujinga5558 Sounds good. Please share with me the link to the repo once it's up
@laurentiujinga55583 жыл бұрын
@@WinTheCloud I have some questions about your approach and data types you use. String eats up a lot of memory, char array fits better, in my opinion. And I couldn't figure it out why {"sensor1Value"=380.00,"sensor2Value"=400.00,...} and not simply {"380.00","400.00",...} You already know the first entry is sensor1Value and then follows sensor2Value and 3 and 4 is the latest one. Serial communication it is very Ssslllooowww, so you do better with shorter commands. 😉 Drop me a line so we can improve this code.
@alaingoyette71032 жыл бұрын
@@WinTheCloud I will do the same. Need to insert some ohms resistance to lower the 5V down to 3.3V, right?
@porty83043 жыл бұрын
I'm currently trying to wire this up myself. I'm a complete beginner and I'm stuck. I've got a 8-Channel Relay and am not able to figure out where to connect the COM connection point. Help would be very appreciated.
@healman113 жыл бұрын
what application did you use for the wiring?
@WinTheCloud3 жыл бұрын
Fritzing
@IamOkayWK2 жыл бұрын
very good vdo. how big of water pump can it control?
@creationsmv62012 жыл бұрын
It is possible to use 18650 3.7v Battery?
@WinTheCloud2 жыл бұрын
Sure, I don't see why not
@calseynez2 жыл бұрын
Ok what is the difference between AO and DO and which one is prefered. either analog or digital if that's what it meant. I'm still new to electrical robotics.
@WinTheCloud2 жыл бұрын
You got it. The Arduino board has Analogs pins and Digital pins. You will use digital pin modes when dealing with signals that are either "on" or "off", such as an LED, a switch. Analog inputs are used when you want to read the voltage potential of something. This is typically used to read analog sensors.
@jameszilch78653 жыл бұрын
Nice video, one question about the code you wrote for this program. Are there any concerns with having all 4 pumps turn on at the same time? Thinking of a scenario where all plants need to get watered if power would be an issue or it would cause strain on the system. Thank you
@WinTheCloud3 жыл бұрын
Great question. Not that I load tested this, but I've run 4 of them at the same time without an issue
@Evilslayer733 жыл бұрын
do i need to put the water container lower than the pot???
@WinTheCloud3 жыл бұрын
No need, the water pump will push the water in the tube regardless of its position
@callmerel28093 жыл бұрын
What does the 4 channel relay used for ?
@WinTheCloud3 жыл бұрын
Switch on/off the water pumps
@callmerel28093 жыл бұрын
@@WinTheCloud I read that due to the electric flow, the sensor will break because of electrolysis. How does one prevent this ?
@fatmahalzahmi85712 жыл бұрын
Hello what if I didn’t want to add the battery will that have an effect on the code?
@IsmaelDiall03 жыл бұрын
what tubes are those??
@WinTheCloud2 жыл бұрын
All parts are linked in the description
@marthalesayo21053 жыл бұрын
Which type of irrigation is this
@WinTheCloud3 жыл бұрын
a DIY one? :D
@rafhanahishamil11833 жыл бұрын
Thank you for this video, the wiring and coding are clear but may i know what i should do with the coding if i'm planning to use only 1 sensor? Is there a difference in number of relay and what i should change in the coding? Thank you very much.
@igortomic15252 жыл бұрын
Hi ! Nice video ! Can you tell me what simulation software is used?
@WinTheCloud2 жыл бұрын
I use Fritzing
@dancoulson65792 жыл бұрын
Having the system continually pump until saturation level is reached isn't a good way of doing it. By the time the sensor reads an acceptable water level, the other side of the plant pot could be water logged. A better way would be to take a self adjusting system: Let's say we want a moisture level of 20% and we'll start with a water pump time period of 4 seconds. The variable for pump seconds is X. 1. Wait an hour, and then take a reading. 2. If it's too dry, pump water for X seconds, go to step 3. If it's too wet, go back to step 1. 3. After a 10 minute wait time, another check is performed. Goto step 4. 4. (a) If the water level has not increased, increase pump time by 1 seconds and go back to step 2. (b) If water level is too high, decrease pump time by 1 seconds and go back to step 1. (c) If water level increased, but is still not sufficient, go back to step 3. Something like this would start off with rough controls. But after a few hours it would settle into a more efficient pattern.
@WinTheCloud2 жыл бұрын
I love your idea! Would you be open to pushing a PR explaining your solution and suggesting the code changes? I would love to have you as a contributor to the project: github.com/SmartThingsDIY/arduino-uno-aws-irrigation-system
@dancoulson65792 жыл бұрын
@@WinTheCloud I'm a little rusty these days. I have not done much programming in a while - I'm still using VB6 :D I have no knowledge of more modern programming languages. However, I'd be happy to help in any way that I can. I'll give it a look. Thanks for the response.
@fatinariessa323 жыл бұрын
May i know is the amount of relay affect the accuracy of reading
@WinTheCloud3 жыл бұрын
I haven't accounted for that. The sensors are connected directly to the Arduino board, do you think the relay would affect the reading nonetheless?
@expressmoonenjoyer36672 жыл бұрын
Hi ! I want to do this for our research as a way to navigate plant's growth. I checked the codes and based on it, it has a delay of 500. Now im only a beginner in terms of coding and i would like to ask if there is a way to code the system to check the moisture of the soil only once an hour (other than extending the number for delay) so the moisture sensor will collect data only after 1hr has passed to maximize the efficiency of it to have a longer lifespan because ive seen some videos about moisture sensors being unusable due to being overused? I really appreciate if you took time to read this and reply to my message thank you. also really great video!!
@WinTheCloud2 жыл бұрын
First of all, old moisture sensors get worn easily, but the model I've included is the new version that provide better resistance to moisture. I have one on my basement for example running for nearly a year without an issue. Now to extend the reading period, rather than running a loop, you can put the whole board to sleep and wake it up after a set interval, do the reading, send it over WiFi then put it back to sleep, which has the benefit of tremendously extending the battery life. I've built that exact same thing in this video: kzbin.info/www/bejne/qp_Ln41jjcpmb6c to which you can find all code and explanation here: github.com/SmartThingsDIY/esp32-talking-plant
@expressmoonenjoyer36672 жыл бұрын
@@WinTheCloud thanks for the clarification and also i really like the suggestion of yours but it needs a wifi and the thing is, we are trying to keep it an offline system as much as possible so that it can be used by people with no internet. thank you so much again for responding, i understand the things you meant and i appreciate it also. p.s ( the system is for our research so adding a wifi in the system would lead to adding more variables for our research and we only have limited time, so we built it as offline.)
@robbbie953 жыл бұрын
Hi there! Nice project. I have a question: Why not ok to just send the 5 volt directly from the Arduino towards the pump? Is the relais really necessary in this case? Cheers!
@WinTheCloud3 жыл бұрын
You can, but the relay give you more control. Think of it as a switch that turns on/off the pump throughout whatever logic you've put in your Arduino code
@mohammadusmani80432 жыл бұрын
Can someone please share the wire diagram with breadboard connections.Thanks
@WinTheCloud2 жыл бұрын
Check description
@outre54162 жыл бұрын
could you post a photo of the wiring irl please? thank you
@WinTheCloud2 жыл бұрын
I'm afraid I don't have this specific project running anymore as I repurposed the parts working on a V2
@mdwasimbishal21002 жыл бұрын
did you use 9v battery? can i use 5v AC mobile charger in here ?
@WinTheCloud2 жыл бұрын
Yes, I used a 9v. I didn't test with an AC mobile charger, but give it a try, what's the worst that can happen
@fan_dan_go15453 жыл бұрын
Bro if I wanted to get the moisture values as a percentage and I wanted that data on my laptop what do I do 🤔 because I want to get the moisture of the soil throughout the day as raw data to analyse
@WinTheCloud3 жыл бұрын
Yeah dude happy to help. For sensor 1 for example, the moisture level is read from Pin1 and stored in the variable "sensor1Value" github.com/MecaHumArduino/arduino-uno-aws-irrigation-system/blob/master/src/main.cpp#L134 For storing the value in the computer, I'd suggest adding an ESP8266 to the setup, which will allow your setup to connect to WiFi, then use the code from my other repo on it: github.com/MecaHumArduino/esp8266-01-aws-mqtt this code connects to WiFi and then sends whatever you want to an MQTT topic of your choice, which can be run on your computer
@fan_dan_go15453 жыл бұрын
@@WinTheCloud thank you for your reply bro 🙏🏻🙌
@WinTheCloud3 жыл бұрын
My pleasure!
@anveesharma79833 жыл бұрын
This is super late, but when you connect the water pump to the relay, do you need to attach the wires from the water pump to the metal tip of the jumper wire, or do you have to strip the jumper wire?
@WinTheCloud3 жыл бұрын
You'd have to strip it :)
@anveesharma79833 жыл бұрын
Thank you so much!
@HermannHering3 жыл бұрын
Can I use a esp8266 instead of the Arduino with the same code?
@WinTheCloud3 жыл бұрын
I haven't tried it, but theoretically yes, you can. Just make sure that you're using Arduino libraries
@HermannHering3 жыл бұрын
@@WinTheCloud So I have to program the ESP over the Arduino tool? Im really new to coding and stuff
@wasimbishal92192 жыл бұрын
hey man i like your works its very good,but i had a question did you use 2 AA 1.2v battry to power up the motors? and did you use 9v battery to powerup your aurduino?
@kapilchhabria17272 жыл бұрын
Hey Ilyas, could you demonstrate how to add the ArduinoJson header file to the library?
@raoe78333 жыл бұрын
How can i calculate how many plants there are?
@WinTheCloud3 жыл бұрын
I'm not sure I understand the question
@somyarathee2 жыл бұрын
Hey! First of all, nice tutorial! I have a question: How did you connect the motors to the relay? Which cables did you use?
@WinTheCloud2 жыл бұрын
Thanks Somya! You can find a full list of parts + Code + Diagrams in the attached article github.com/SmartThingsDIY/arduino-uno-aws-irrigation-system (I always include the article in such videos, just make sure to check the description)
@shilpa...2 жыл бұрын
can i order this project?
@WinTheCloud2 жыл бұрын
All items are linked in the description. The code is linked as well
@PrettyGirl-pu9rz3 жыл бұрын
Hi! may i know what are you using app? so i can download it. i hope you notice my comment. thankyou
@WinTheCloud3 жыл бұрын
Hi, please check the description, I have put a link to the Github article with all librairies and links
@garciamelaiza53342 жыл бұрын
how to download the main arduino code??? please reply asap🥺
@WinTheCloud2 жыл бұрын
There is a link in the description that takes you to Github where the code is
@AlexSouthwell3 жыл бұрын
Can you push your code from VSCode to the ardunio in app?
@WinTheCloud3 жыл бұрын
Totally possible because I use PlatformIO extension on VSCode
@lol123inthehouse62 жыл бұрын
Hello! I have configured and set up everything according to the diagram but my water pump is not pumping out water. What can I possibly change?
@WinTheCloud2 жыл бұрын
Have you checked if the water pump works by itself?
@LeviAckerman-bd3gl3 жыл бұрын
Is it okay if i use some ordinary soil moisture sensor?
@WinTheCloud3 жыл бұрын
It should be ok indeed. You probably would just have to calibrate the readings in your code
@fan_dan_go15453 жыл бұрын
I have another question yet again bro 😅 so basically I followed this exact guide same code and equipment, but it not working how it suppose to, the pump not coming on when I remove the sensor from the soil and when the pump do come on, it does not stop pumping water. I have the same code as you, Arduino works fine, relay works, the pumps all work( I even hooked up pump directly to the power source and all 4 pumps came on ) . The only difference is that you use a 9V to power your Arduino but I use a usb cable connected to my laptop. Do you think that causing the problem ?
@WinTheCloud3 жыл бұрын
Hum, my guess is the sensors need to be calibrated to your own numbers. You see the number "450" here github.com/MecaHumArduino/arduino-uno-aws-irrigation-system/blob/master/src/main.cpp#L137 ? This works for me but maybe you're using a newer version of the sensor that is calibrated differently - So put the sensor in water, note the number it output, pull it out of water and note that number again. Then use both of the number to detect when the sensor is wet and when it's dry
@fan_dan_go15453 жыл бұрын
@@WinTheCloud the average highest value for when the sensor was dry was 581, the lowest average was 302 for wet. (I use average values because the 4 sensors gave slightly different readings) . So 450 is about 53 percent soil water moisture content which is perfect. Funny thing is that it works fine like how you demonstrated without the pumps connected. I would hear the relay turn on when sensor out of the soil, then I put it back in and relay turns off. But then I hook up the pumps to relay, it doesn't work like it supposed to( some pumps won't turn on and the ones that do would just keep pumping continuously). Even though the power supply could run all pumps at the same time. This thing giving me a headache.
@WinTheCloud3 жыл бұрын
That's definitely weird. I know it won't be easy but at this point, I'd go a few steps back: try to make it work with one sensor, one relay and one pump, this way you can try with different pumps, maybe the issue is a couple of pumps themselves... Let me know how it goes
@fan_dan_go15453 жыл бұрын
@@WinTheCloud it works now bro, I tested everything one by one, put it back and now it finally works 😪 thanks for your help
@WinTheCloud3 жыл бұрын
@@fan_dan_go1545 Glad to hear it. It was my pleasure!
@doitallYT3 жыл бұрын
What USB 3.0 adapter is that on your iMac? Looks epic :O
@WinTheCloud3 жыл бұрын
HAHA it's this dodocool www.amazon.ca/gp/product/B0776R6VCT (the name is epic!)
@Shinishiniiii3 жыл бұрын
Can you suggest me a app that i can use for this project? I will be using the wifi module ESP8266 D1 VER2015-08
@taufiqzakaria29623 жыл бұрын
Blynk
@laurentiujinga55583 жыл бұрын
Nice. It can be easier with arrays and for loops byte pSensor[] = {14, 15, 16, 17}; byte pRelay[] = {2, 3, 4, 5}; float sensorValue = 0; void setup(){ Serial.begin(115200); for (int i = 0; i < 4; i++) { pinMode(pSensor[i], INPUT); pinMode(pRelay[i], OUTPUT); } } void loop(){ for (int x = 0; x < 4; x++){ sensorValue = analogRead(pSensor[x]); Serial.println(sensorValue); if (sensorValue > 450) { digitalWrite(pRelay[x], HIGH); } else { digitalWrite(pRelay[x], LOW); } } }
@WinTheCloud3 жыл бұрын
Great! Feel free to create PR on the repo: github.com/MecaHumArduino/arduino-uno-aws-irrigation-system All contribution is welcome :)
@leoserban3 жыл бұрын
Hi, I have 0 skills in coding and using Arduino. But I want to create this DIY project for my home plants so they'll be ok when I go away on vacation. My question is: I notice that at the wiring diagram, there's no breadboard, but when you test the thing, there's a breadboard connected there. Why didn't you put it on the diagram? Also, do you have a complete diagram with everything I'll need to get this project going? Thank you in advance!
@WinTheCloud3 жыл бұрын
Hi, great question. The breadboard is there to make things easier for when building your prototype, it offers a way to connect your components in a solderless way, but once the final schema is established, most tinkerers will chose to solder the components together, putting the breadboard aside to be used for another project. But sometimes I chose to keep the breadboard like in this little project instagram.com/p/CIrR6RBBCa-/
@leoserban3 жыл бұрын
@@WinTheCloud Hei, thanks for the reply! So that means that I can follow your wiring diagram and will be good to go! That's great! I will proceed in buying the required components for this. Thank you very much!
@WinTheCloud3 жыл бұрын
My pleasure!
@healman113 жыл бұрын
i'm assuming this language is c++, but I just want to make sure it is, am I right?
@WinTheCloud3 жыл бұрын
You got it. Arduino uses C++ as the it's main language. BTW checkout the Github article link in the description that contains a line by line code explanation
@rakeshp87913 жыл бұрын
Thaaaaaaaaaaaaaaaaaaaaaaaaaank yoooooooooooooooooooooooooooou Soooooooooooooooooooooooooooo much dude bro
@WinTheCloud3 жыл бұрын
You're welcome, my friend :) I published sort of an update and used Amazon Alexa this time, make sure to give it a watch as well ;) kzbin.info/www/bejne/a4mZqKRvjbyfZ5I
@nano75863 жыл бұрын
Damn this is more expensive than I expected
@truflisko3 жыл бұрын
Cool!
@WinTheCloud3 жыл бұрын
Thank you :)
@mohammedchawki11392 жыл бұрын
hi can you explain the wiring more becuase it is not enough clear @iLyas BK