Files
firmware/src/mesh/wifi/WiFiAPClient.h

32 lines
566 B
C
Raw Normal View History

#pragma once
2022-12-21 13:36:38 +01:00
#include "concurrency/Periodic.h"
2023-01-21 14:34:29 +01:00
#include "configuration.h"
#include <Arduino.h>
#include <functional>
#if HAS_WIFI && !defined(ARCH_PORTDUINO)
#include <WiFi.h>
#endif
2025-03-15 14:15:35 +01:00
#if HAS_ETHERNET && defined(USE_WS5500)
#include <ETHClass2.h>
#define ETH ETH2
#endif // HAS_ETHERNET
2022-12-21 13:36:38 +01:00
extern bool needReconnect;
extern concurrency::Periodic *wifiReconnect;
/// @return true if wifi is now in use
2022-10-25 11:53:22 +02:00
bool initWifi();
2020-09-14 20:27:49 -07:00
void deinitWifi();
2020-09-18 18:02:56 -07:00
bool isWifiAvailable();
2020-09-14 20:27:49 -07:00
2025-03-15 14:15:35 +01:00
uint8_t getWifiDisconnectReason();
#ifdef USE_WS5500
// Startup Ethernet
bool initEthernet();
#endif