Is it clearly stated in the debug serial when your flooding the server?

I get disconnections 1 or twice a day, looking at the debug below I cannot see any obvious reason why it’s disconnecting, my code is huge so no point posting … i’ve used timers to ensure no mass writes to the Blynk server but can’t work out the cause from the log below.

Does blynk make it clear when you flood the server?

[17718360] <vw[00]19[00]16.56
[17718428] <[14]v:[00|07]
[17718429] <vw[00]0[00]36
[17718497] <[14]v;[00|0A]
[17718498] <vw[00]27[00]6.89
[17718566] <[14]v<[00|06]
[17718567] <vw[00]1[00]3
[17718635] <[14]v=[00|06]
[17718636] <vw[00]2[00]2
[17718704] <[14]v>[00|06]
[17718705] <vw[00]3[00]3
[17718773] <[14]v?[00|06]
[17718774] <vw[00]7[00]0
[17718842] <[14]v@[00|06]
[17718843] <vw[00]8[00]0
[17718912] <[14]vA[00|06]
[17718913] <vw[00]9[00]0
[17718981] <[14]vB[00|0B]
[17718982] <vw[00]16[00]0.000
[17719050] <[14]vC[00|0B]
[17719051] <vw[00]17[00]0.000
[17719119] <[14]vD[00|0B]
[17719120] <vw[00]18[00]0.000
[17719188] <[14]vE[00|07]
[17719189] <vw[00]20[00]0
[17719257] <[14]vF[00|07]
[17719258] <vw[00]28[00]0
[17719326] <[14]vG[00|07]
[17719327] <vw[00]29[00]0
[17719395] <[14]vH[00|0F]
[17719396] <vw[00]65[00]Fresh Air
[17719464] <[14]vI[00|08]
[17719465] <vw[00]64[00]60
[17722963] <[14]vJ[00|10]
[17722964] <vw[00]60[00]19:38 15/1
[17723034] <[14]vK[00|07]
[17723035] <vw[00]63[00]1
[17723103] <[14]vL[00|09]
[17723103] <vw[00]99[00]OK!
[17723104] Sent 0/14
[17728061] Connecting to blynk-cloud.com:80
[17728135] <[02|00|01|00] 
[17728136] <402e9884dea94ba2a79e654eb8f7c2a6
[17728157] >[00|00|01|00|C8]
[17728157] Ready (ping: 19ms).
[17728158] Free RAM: 2210
[17728224] <[11|00|02|00]f
[17728225] <ver[00]0.5.4[00]h-beat[00]10[00]buff-in[00]1024[00]dev[00]Arduino Mega[00]cpu[00]ATmega2560[00]con[00]W5100[00]build[00]Jan 15 2019 14:42:58[00]
[17728264] >[00|00|02|00|C8]
[17728312] <[14|00|03|00|07]

There used to be a flood error message in the App, but Blynk has long since made some changes that include an anti-flooding "governor’ in the library, so that is probably not your issue.

You appear to be using an Arduino Mega with ESP as WiFi Shield, so there can be many issues there due to the slower hardware and the inherent shield issues.

Without further detail, there is nothing we can do but guess.

1 Like

Thanks Gunner, I’m running the code on a Mega 2560 using a Wiznet 5100 LAN adapter. It’s connected via ethernet.

I’ve ran pings from my pc to the WAN and receive no packet loss at the time of disconnection so im pretty certain my internet is not dropping out

Each function is running thousdands of times without any disconnection and then suddenly it drops, i would have thought this would drop out sooner if it was the coding but I’m first to admit I’m no expert.

When the connection drops it reconnects fine, the Arduino continue running functions in the background as well.

I’m tempted to run serial prints at the start and end of each function just to see if it’s getting stuck on the same area, however as the Arduino is still running functions I’m not sure this is going to get me any closer to the cause :frowning:

Are there any other suggestions that can help debug blynk disconnecton issues?

Odds are high this is your issue. I had one ages ago and it was generally unreliable over time. Others have commented throughout this forum about similar reliability issues.

Thanks, i must admit this i’ve found the W5100 the most reliable LAN adaptor out of the 3 i’ve been able to source

I’ve tried the Wiznet W5500 however this suffered really badly with disconnecting from blynk and not reconnecting at all when using solenoids (even with a diode between the solenoid and relay)

I’ve also used the enc28j60 LAN adaptor but this uses so much arduino memory and also suffers with disconnections (not as severe as the W5500)

Is there another LAN adapted that i’ve not come across that you can recommend?