Irrigation system
Posted:
Tue Jun 27, 2017 12:17 pm
by RubenFerol
Hi guys,
I'm new here and this would be my first ESP project.
I want to make an irrigation system that can be controlled via internet - simple on/off. I thought of ESP8266 but i'm a total noob and i need help.
So I have most parts for this project (i like to think that all of them: ESP8266, MCP2221, Relay, Electrovalve 12V, powersource ac220V to dc12V and dc5V, buck for 5V to 3.3V).
How do I begin?
Re: Irrigation system
Posted:
Wed Jun 28, 2017 10:37 am
by alex_g
The first thing you have to do is to decide how you are going to program your system.
If you are familiar with C/C++ or with Arduino, you might choose the Arduino IDE.
If not, you might prefer the Lua/NodeMCU approach which I like more as it is more interactive during development. Lua is fairly easy and quick to learn, especially if you already know Javascript.
There are other options too, notably a Python route, but I don't know much about it, you'd have to explore it yourself. There are also specialist and dedicated SDKs, but that's probably for more professional use than what you want.
Once you've decided which one you want to try first, collect everything you need, docs, tutorials etc, fire it up, and try a few standard demo examples, blinking a LED, using a timer, making a basic Web page, that sort of thing...
Finally, you will need to decide how to bridge your Web server to the Internet. This will require some thought, although it's not really an ESP-related matter. I recommend MQTT for ease, but of course, there are many other ways too.
After that you'll be ready to write your own irrigation app.
Re: Irrigation system
Posted:
Wed Jun 28, 2017 11:14 am
by rudy
First take a look at other people's projects. See what they have done and maybe it would be close to what you need.
https://github.com/search?utf8=%E2%9C%9 ... positories
Re: Irrigation system
Posted:
Wed Jun 28, 2017 2:07 pm
by RubenFerol
I worked few times with Arduino, so i am more inclined to walk on this path(although i am curious about the alternatives).
So I made a shield after the schematic and managed to program the ESP (a winner i am). The trick is to hold the S2 Flash pressed and hit the S1 reset button once exactly when Arduino IDE says "Uploading...". After uploading is done you can release the flash button.
At this point I managed to remotely change my relay state from a web browser. This instructable helped:
https://www.instructables.com/id/ESP-12 ... -for-Flas/Next is the control via internet. I will try doing it by using MQTT (thanks alex_g for suggestion) and come back with details.