-
Hello Bert, Maybe you can help me with a problem: Although the reconnect always works reliably, regardless of whether WiFi or the broker fails, I have a problem. I keep noticing that some devices have to reconnect to the broker after a while. The disconnect reason is 7. KeepAlive is set to 30, but I send a status message every 10 seconds (more for testing). Best regards, |
Beta Was this translation helpful? Give feedback.
Replies: 9 comments 16 replies
-
|
Beta Was this translation helpful? Give feedback.
-
Would you be able to get the broker log? Often it logs why it kicks a client. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
@sude22 check the RSSI or wifi disconnect/reconnect, check if you have some guard to handle MQTT disconnect, or set |
Beta Was this translation helpful? Give feedback.
-
not sure if this is related but in one of my projects we had many issues of reconnection issues with MQTT and it turned it to be a problem with espressif32's WiFi connectivity on Mesh networks (specifically FritzBoxes) due to channel roaming. We solved this by using BSSID or fixing IPs in the client code. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Unfortunately, another case has now occurred in which an ESP cannot reconnect to the broker. You can see in the broker that it establishes a new connection, but then the broker times out after 30 seconds. I use the reconnect code from the basic example. |
Beta Was this translation helpful? Give feedback.
-
probably related to #106. That user could switch to the sync version. On esp8266 this isn't always the case. ESPAsyncTCP doesn't seem to be the most stable library... |
Beta Was this translation helpful? Give feedback.
-
Well, i did that yesterday.. |
Beta Was this translation helpful? Give feedback.
After all, I really think it is the problem of my special WiFi setup, that sometimes blocks the traffic, even if the WiFi state is connected.
Anyway, thanks for all your time and help with that. I move on with my project, and in case I find out something new about this I let you know.