From 4ed7ca948261aeb1cb1dc3484d15d5456cdbad89 Mon Sep 17 00:00:00 2001 From: Siwat Sirichai Date: Tue, 7 Nov 2023 19:28:21 +0700 Subject: [PATCH] adjust mqtt socket timeout --- src/espmega_iot_core.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/espmega_iot_core.cpp b/src/espmega_iot_core.cpp index 47e09f7..839b08e 100644 --- a/src/espmega_iot_core.cpp +++ b/src/espmega_iot_core.cpp @@ -138,6 +138,8 @@ void setup() lcd_send_command("boot_state.txt=\"Network Initializing . . .\""); network_begin(); lcd_send_command("boot_state.txt=\"IoT Core Initializing . . .\""); + mqtt_client.setSocketTimeout(1000); + eth.setTimeout(1); mqtt_connect(); lcd_send_command("boot_state.txt=\"Threads Initializing . . .\""); thread_initialization();