You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
#include "wifi.h"
|
|
|
|
|
|
Wifi::Wifi(WifiSettings const& settings):
|
|
|
m_wifi()
|
|
|
{
|
|
|
for(auto it = settings.networks_cbegin(); it != settings.networks_cend(); it = it->next())
|
|
|
m_wifi.addAP(it->ssid(), it->pass());
|
|
|
Serial.setDebugOutput(true);
|
|
|
}
|
|
|
|
|
|
void Wifi::keep_alive_connection()
|
|
|
{
|
|
|
m_wifi.run();
|
|
|
}
|
|
|
|
|
|
bool Wifi::is_connected() const
|
|
|
{
|
|
|
return WiFi.status() == WL_CONNECTED;
|
|
|
}
|