Browse Source

0.6.1

* potential fix of WiFi hostname during boot up #752
pull/854/head
lumapu 2 years ago
parent
commit
521c7ca307
  1. 1
      src/CHANGES.md
  2. 7
      src/wifi/ahoywifi.cpp

1
src/CHANGES.md

@ -3,3 +3,4 @@
## 0.6.1 - 2023-04-01 ## 0.6.1 - 2023-04-01
* merge LED fix - LED1 shows MqTT state, LED configureable active high/low #839 * merge LED fix - LED1 shows MqTT state, LED configureable active high/low #839
* only publish new inverter data #826 * only publish new inverter data #826
* potential fix of WiFi hostname during boot up #752

7
src/wifi/ahoywifi.cpp

@ -1,6 +1,6 @@
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// 2023 Ahoy, https://www.mikrocontroller.net/topic/525778 // 2023 Ahoy, https://ahoydtu.de
// Creative Commons - http://creativecommons.org/licenses/by-nc-sa/3.0/de/ // Creative Commons - https://creativecommons.org/licenses/by-nc-sa/4.0/deed
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
#if defined(ESP32) && defined(F) #if defined(ESP32) && defined(F)
@ -160,6 +160,9 @@ void ahoywifi::setupAp(void) {
DBGPRINTLN(mApIp.toString()); DBGPRINTLN(mApIp.toString());
DBGPRINTLN(F("---------\n")); DBGPRINTLN(F("---------\n"));
if(String(mConfig->sys.deviceName) != "")
WiFi.hostname(mConfig->sys.deviceName);
WiFi.mode(WIFI_AP_STA); WiFi.mode(WIFI_AP_STA);
WiFi.softAPConfig(mApIp, mApIp, IPAddress(255, 255, 255, 0)); WiFi.softAPConfig(mApIp, mApIp, IPAddress(255, 255, 255, 0));
WiFi.softAP(WIFI_AP_SSID, WIFI_AP_PWD); WiFi.softAP(WIFI_AP_SSID, WIFI_AP_PWD);

Loading…
Cancel
Save