From 2de24eecec01f81b911ff401e1060b71bd88fcc6 Mon Sep 17 00:00:00 2001 From: Zachary Drew Date: Mon, 18 Mar 2019 21:25:01 -0700 Subject: [PATCH] OTA is broken in AP mode because ESP8266mDNS is checking whether the station is connected before processing. Change the logic to WiFi.isConnected() OR WiFi.softAPgetStationNum()>0 fixes the issue. --- libraries/ESP8266mDNS/src/LEAmDNS_Control.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/libraries/ESP8266mDNS/src/LEAmDNS_Control.cpp b/libraries/ESP8266mDNS/src/LEAmDNS_Control.cpp index c95c8d8234..dff8879ea2 100644 --- a/libraries/ESP8266mDNS/src/LEAmDNS_Control.cpp +++ b/libraries/ESP8266mDNS/src/LEAmDNS_Control.cpp @@ -79,9 +79,10 @@ bool MDNSResponder::_process(bool p_bUserContext) { } } else { - bResult = ((WiFi.isConnected()) && // Has connection? - (_updateProbeStatus()) && // Probing - (_checkServiceQueryCache())); // Service query cache check + bResult = ((WiFi.isConnected() || // Either station is connected + WiFi.softAPgetStationNum()>0) && // Or AP has stations connected + (_updateProbeStatus()) && // Probing + (_checkServiceQueryCache())); // Service query cache check } return bResult; }