macro definition #ifdef ENABLE_SOFTAP (#1698)

* macro definition #ifdef ENABLE_SOFTAP

* Update platformio.ini

* softap define in define.h

* Update platformio.ini

* #define WLAN_CONFIG_FILE "/sdcard/wlan.ini"

Co-authored-by: jomjol <30766535+jomjol@users.noreply.github.com>
This commit is contained in:
Nicolas Liaudat
2022-12-27 19:04:29 +01:00
committed by GitHub
parent 39a02c6d6d
commit fca37ee699
6 changed files with 28 additions and 15 deletions

View File

@@ -39,7 +39,9 @@
#include "../../include/defines.h"
//#include "server_GPIO.h"
#ifdef ENABLE_SOFTAP
#include "softAP.h"
#endif //ENABLE_SOFTAP
extern const char* GIT_TAG;
extern const char* GIT_REV;
@@ -182,7 +184,7 @@ extern "C" void app_main(void)
#endif
char *ssid = NULL, *passwd = NULL, *hostname = NULL, *ip = NULL, *gateway = NULL, *netmask = NULL, *dns = NULL; int rssithreashold = 0;
LoadWlanFromFile("/sdcard/wlan.ini", ssid, passwd, hostname, ip, gateway, netmask, dns, rssithreashold);
LoadWlanFromFile(WLAN_CONFIG_FILE, ssid, passwd, hostname, ip, gateway, netmask, dns, rssithreashold);
LogFile.WriteToFile(ESP_LOG_INFO, TAG, "WLAN-Settings - RSSI-Threashold: " + to_string(rssithreashold));