I’ve done a bit more investigation into my Blynk connection problem here in China, firstly my Internet provider tell me that they cannot increase the service and I have the best they they can do.
I’ve also done some diagnostic work on my project to see if there is a reason to the continued heartbeat timeout with some interesting results. I inserted a small bit of code (from @Gunner I think) to measure the loop cycles per second and MCU up time (millis) and send the data to Blynk every 1 second.
The first noticeable thing is that now my project remains connected for many hours before any timeout issues, the original main sketch sends data to Blynk every 15 seconds but now I send MCU data (3 vPins) every 1 second it is very much more stable. In the past 9 hours I’ve only had 2 re-connection events which is good, usually I’m lucky to go 30 minutes without a timeout event! The only conclusion I can think of, because nothing else has changed (ping value still typically 1000+ ms), is that by pushing data to Blynk every 1 second a good connection is being maintained.
The other interesting event that can be seen in the screen shot is that I had an MCU reset, or at least the millis reset back to zero after about 330 minutes (not 49 days!), there were 2 Blynk connection events one either side but 23 minutes apart and the millis reset did not affect the connection status. If the MCU had of gone through a reset routine I would have expected a longer disconnected period that coincided with the reset. Can the millis counter reset back to zero without an actual MCU reset? Not a Blynk question I know but Blynk has helped me great deal to diagnose these events.