ESP8266 stability issues

Hi all,

I'm planning a project that involves a number of ESP8266 controllers that talk back to a central Uno which manages them all through another 8266 and finally serves a remote control facility. The only thing is that the connectivity and each controller needs to be robust and reliable. I have little margin for them to go offline and need human intervention.

I coded a proof of concept and noticed the one ESP8266 with a simple webserver seems to a bit unstable. Before you ask, the code logic is not the issue. It seems likely that even though it's still wifi connected, it doesn't receive the request or doesn't process it for a while.

Here are some of the issues:

  • Inconsistently takes up to 15-20 seconds to respond. Sometimes right away.
  • One request gets no response, but a second (different client) GET request kicks it off and it responds back to both requests.
  • It just doesn't respond till it times out, connection closed, etc. but the very next request works.
  • Worst case, at some point it just stops responding all together and only a hard reset gets it back online. Meantime I can still see it's IP and ping it

Are there a list of best practice or tips and tricks you can suggest that generally improve it's and other controller's stability? Are there commands that are known to be flaky? etc.?

it is caused by power saving and/or antenna. I could not solve it in my project. But as client they are stable.

Are you using a Wi-fi hub or is the control ESP working in AP mode as the hub for all the other ESP's.

How many ESP's are you looking to use?

Are you using TCP or UDP and how much data passes between each node?

Power supply for the device is important - google that , I think a capacitor across the Vcc/gnd helps .

I use one of these to control an outside light - it did drop out , but cured by restarting it if the connection was not available . Haven’t the code for that at hand , but found by googling problems with this chip

restarting the router always helps

Have same system described running.

Central uno with esp8266 as a shield acting as dhcp and web server for other uno-esp modules.

Wiring was the major issue till improved with oscilliscope to smooth out all ripples and corrected schematic.

Code is the second issue. Esps with esp8266 library were unreliable which forced me to switched to at command option.

Thanks all. I've taken some pointers to implement.

Most of all I've decided to simplify the 8266 code to the absolute bare minimum with the highest efficiency. So just making very simple HTTP requests with JSON response. Minimal code, minimal libraries, etc. and any hard work other to be done by a secondary server. That makes the architecture more complicated but each device is a lot simpler.