I'm struggling with the following 'problem': I have made an IoT device with an esp8266 as microcontroller and I have made an dedicated webserver, hosted offsite. The site is almost done, but now I need an realtime link to the esp via the website. I need to upload 'programs' (temp1 = 50 deg, time1 = 20 min, temp2 = 67 deg, time2 = 15min etc. etc.) and just regular temp/time combinations. I have 2 approaches:
1. http(s)
2. websocket
I know how to do it with http, but it is really, really slow and hardly realtime. The websocket is a different story. All I can find is how to do it with the esp8266 acting as webserver. I only need a polling speed of 1 hz. The link has to be bi-directional, since the esp8266 will upload the time and temp to the server, and the server has to send the set time and set temp (which is technically ok to do with http).
Could someone point me to a tutorial for a websocket with an offsite server? Or do you guys think it can be done with http?
Thanks in advance,
Rens van Breukelen