mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-21 18:22:32 +00:00
immediately reconnect to mqtt server on wifi reconnect
This commit is contained in:
10
src/main.cpp
10
src/main.cpp
@@ -338,7 +338,7 @@ void setup()
|
||||
#endif
|
||||
|
||||
bool forceSoftAP = 0;
|
||||
|
||||
|
||||
#ifdef BUTTON_PIN
|
||||
#ifndef NO_ESP32
|
||||
|
||||
@@ -537,6 +537,10 @@ void setup()
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(PORTDUINO) || defined(HAS_WIFI)
|
||||
mqttInit();
|
||||
#endif
|
||||
|
||||
// Initialize Wifi
|
||||
initWifi(forceSoftAP);
|
||||
|
||||
@@ -549,10 +553,6 @@ void setup()
|
||||
initApiServer();
|
||||
#endif
|
||||
|
||||
#if defined(PORTDUINO) || defined(HAS_WIFI)
|
||||
mqttInit();
|
||||
#endif
|
||||
|
||||
// Start airtime logger thread.
|
||||
airTime = new AirTime();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user