Remote Irrigation

Hey, I wanna build a system for monitoring and watering my plants while I'm out of home. So I bought these sensors for knowing the statue of my plants 1) Moisture Sensor 2) Light Sensor 3) Humidity&Temperature Sensor , and I managed to read and send data from them to my channel on ThingSpeak Using ESP-8266-01, BUT now I don't know what I should do?! I need to use an Android application to monitor the data on ThingSpeak and also make an event to open or close the valve! Any Suggestions. Thanks in advance!

Scenario 1: using the ESP8266 as a server, and the Android app as a client.
This works as long as the phone and the ESP are on the same local network. However, the server is behind NAT, so you can't access it from the internet without port forwarding, and you would have to know it's public IP. So that's not really an option. (Some ISPs allow port forwarding and static IP addresses, but this is generally not very safe, and it might be difficult to set up.)

Scenario 2: the ESP and the app are both clients, using the ThingSpeak server.
The ESP can post data to the server, and the app can get the data from the server.
The app can post a valve state to the server, and the ESP can dowload that state and act accordingly.
The downside is that you can't connect from the app to the ESP8266 directly, and more importantly, the server can't push the new state to the ESP: the ESP has to ask the server every x seconds if the valve state has changed.

I'm assuming that a delay of a couple of seconds between pressing a button in the app, and the actual closing of the valve is not really an issue?

Pieter

I'm assuming that a delay of a couple of seconds between pressing a button in the app, and the actual closing of the valve is not really an issue?

Yes, sir. It won't make any issues!

So do I need to build an Android app to get data from ThingSpeak server?!

precagriculture:
So do I need to build an Android app to get data from ThingSpeak server?!

In your OP, you said that you wanted to use an Android app, so yes, you could write your own app. You just need to make some HTTP requests, and maybe some data visualization, so it's definitely not that hard.

Getting used to Java might take some time, but there's loads of documentation online, and Android Studio makes it really easy to build, debug, and test apps.

Pieter

In your OP, you said that you wanted to use an Android app, so yes, you could write your own app. You just need to make some HTTP requests, and maybe some data visualization, so it's definitely not that hard.

So can you tell me where I should start? or any links? articles?
Regards :slight_smile:

Would Blynk be of any use? - Scotty

or... rather than an an Android app, you could run it as a web server, and use (any) browser to operate the pages on local or NATted public IP ?