/* WIFI MODULE Copyright (C) 2016-2019 by Xose PĂ©rez */ #pragma once #define LWIP_INTERNAL #include #undef LWIP_INTERNAL extern "C" { #include #include #include #include // ip_addr_t #include // ERR_x #include // dns_gethostbyname #include // ip4/ip6 helpers #include // LWIP_VERSION_MAJOR }; #if LWIP_VERSION_MAJOR == 1 #include #else // LWIP_VERSION_MAJOR >= 2 #include #endif #include // ref: https://github.com/me-no-dev/ESPAsyncTCP/pull/115/files#diff-e2e636049095cc1ff920c1bfabf6dcacR8 // This is missing with Core 2.3.0 and is sometimes missing from the build flags. Assume HIGH_BANDWIDTH version. #ifndef TCP_MSS #define TCP_MSS (1460) #endif struct wifi_scan_info_t; using wifi_scan_f = std::function; using wifi_callback_f = std::function; uint8_t wifiState(); void wifiReconnectCheck(); bool wifiConnected(); String getNetwork(); String getIP(); void wifiDebug(); void wifiDebug(WiFiMode_t modes); void wifiStartAP(); void wifiStartSTA(); void wifiDisconnect(); void wifiStartWPS(); void wifiStartSmartConfig(); void wifiRegister(wifi_callback_f callback); void wifiSetup(); void wifiLoop();