WiFi portal
This commit is contained in:
@@ -4,7 +4,6 @@
|
||||
#include <NetworkClientSecure.h>
|
||||
#include <Preferences.h>
|
||||
#include "NetworkDevice.h"
|
||||
#include "WiFiManager.h"
|
||||
#include "IPConfiguration.h"
|
||||
|
||||
class WifiDevice : public NetworkDevice
|
||||
@@ -16,25 +15,32 @@ public:
|
||||
|
||||
virtual void initialize();
|
||||
virtual void reconfigure();
|
||||
virtual ReconnectStatus reconnect(bool force = false);
|
||||
virtual void scan(bool passive = false, bool async = true);
|
||||
|
||||
virtual bool isConnected();
|
||||
virtual bool isApOpen();
|
||||
|
||||
int8_t signalStrength() override;
|
||||
|
||||
String localIP() override;
|
||||
String BSSIDstr() override;
|
||||
|
||||
private:
|
||||
static void clearRtcInitVar(WiFiManager*);
|
||||
|
||||
void openAP();
|
||||
void onDisconnected();
|
||||
void onConnected();
|
||||
bool connect();
|
||||
|
||||
WiFiManager _wm;
|
||||
Preferences* _preferences = nullptr;
|
||||
|
||||
bool _startAp = false;
|
||||
bool _isReconnecting = false;
|
||||
int _foundNetworks = 0;
|
||||
int _disconnectCount = 0;
|
||||
bool _connectOnScanDone = false;
|
||||
bool _connecting = false;
|
||||
bool _openAP = false;
|
||||
bool _startAP = true;
|
||||
bool _convertOldWiFi = false;
|
||||
bool _connected = false;
|
||||
uint8_t _connectedChannel = 0;
|
||||
uint8_t* _connectedBSSID;
|
||||
int64_t _disconnectTs = 0;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user