gdsports wrote:After mqttClient.disconnect(), wait for both the mqttClient and the tcpClient to report not connected. Then do an additional 50 ms delay before going to deep sleep. Works for me.Code: Select allif (!mqttClient.connected() && !tcpClient.connected()) {
// Allow time for final FIN ACK
delay(50);
deepsleep_normal();
}