ESP-01 + DHT22 + Blynk, system halts after few days

Hi,

my ESP-01 sends temperature and humidity info at 5 second interval to Blynk server (not local).
System works OK for few days but then the Blynk app only shows 0 values for both temperature and
humidity. When I reboot (power off/on cycle) the ESP-01, it starts to work again and shows the correct values,
but after another few days this same happens again and again it recovers after ESP-01 reboot. All the electronics
are in room temperature and power supply for the ESP-01 should be sufficient.

Before digging any deeper the fault, does this sound like any known issue with ESP-01 and the Arduino IDE library for example? I think I don’t have the latest library installed at Arduino IDE… I’ll upload the code later on if needed.

Thanks already for the help!

Hello. You have 2 options to localize issue.

  1. Install local server, set logging to trace level and check logs when you get 0, to see where this 0 is coming from.
  2. Make some debug output on hardware.

Can you post some code if possible? Also I’ve seen the ESP-01 supports a sleep mode, though I think you need to activate it.

What is the firmware version on your ESP?
Can you modify your code to reconnect if it gets disconnected? It’s always good to be as robust as possible if your system is meant to run for days.

Also, like Dmitriy said, try using a local server to help isolate the problem.

First of all, thanks to both for your comments and ideas. I’m starting to suspect that our home WiFi router would have something to do with the trouble, it’s been working really poorly lately and I can see that my ESP-01 keeps disconnecting from the network really often.

However, now the system has worked just fine for the last 5 days without any trouble like I described before.

I don’t have access to the computer where the code lies at the moment, but I’ll try to remember to send it later on, if someone would be keen on checking it.

Thanks!

Hi! Just a small note, I just resolved some of my major problems with ESP latency. Basically, other wifi networks were causing massive ping spikes (up to 1000 ms). I could only solve the problem by making the ESP host its own AP with a channel that was different from all the other wifi networks around me.