Hello,
I have created kind of smart irrigation system with Arduino Mega and sensors like described in high level schema picture attached.
Now I would like to extend my project with introducing ESP8266 as WiFi adapter and target is to finally connect to Cayenne (green marked in the picture)
Does anyone has experience with:
- How to connect Arduino Mega with ESP8266 NodeMCU using it as WiFi
- Working code example for ESP8266 would be appreciated
Many thanks.
Br,
Petar.
P.S. If someone is interested for already working part of project I am glad to share it.
Not sure did I post it picture correctlly so jus tin case here is URL:
https://imgur.com/a/bUrboqz
Hi Petar.
I can see your image just fine.
There are different ways to send data to the ESP8266. If you can wire the ESP8266 to the Arduino, I would recommend using Serial communication. You connect TX–>RX, RX–>TX and then, you read the data on the ESP8266 serial port.
Unfortunately, at the moment, we don’t have any tutorial about Serial communication between both boards. But, there are some information available online for that, search for “Arduino send data to ESP8266 via Serial” or something similar.
I haven’t tried Cayenne with the ESP8266, but I guess you should need to make an HTTP POST or GET request. You can take a look at this tutorial: https://randomnerdtutorials.com/esp8266-nodemcu-http-get-post-arduino/
I hope this helps.
Regards,
Sara