15 lines
400 B
C++
15 lines
400 B
C++
#include "wifi.h"
|
|
#include "tools.h"
|
|
|
|
void wifi_setup() {
|
|
Serial.printf("Connecting to WiFi %s...", WIFI_SSID);
|
|
WiFi.mode(WIFI_STA);
|
|
WiFi.begin(WIFI_SSID, WIFI_PASS);
|
|
while (WiFi.status() != WL_CONNECTED) {
|
|
Serial.print(".");
|
|
delay(300);
|
|
}
|
|
Serial.println();
|
|
LOGln("Connected as %s", WiFi.localIP().toString().c_str());
|
|
random16_add_entropy(micros());
|
|
} |