#include "theSecrets.h" #ifdef ESP32 #include #elif defined(ESP8266) #include #endif #include "API.hpp" firewall::API *firewall_api; void setup_wifi() { Serial.begin(115200); WiFi.mode(WIFI_STA); WiFi.begin(ssid, psk); Serial.printf("Attempting to connect to WPA SSID: %s\n", ssid); while (WiFi.status() != WL_CONNECTED) { Serial.print('.'); delay(1000); } Serial.println(); Serial.print("IP Address: "); Serial.println(WiFi.localIP()); } void setup() { setup_wifi(); firewall_api = new firewall::API(api_username, api_password); } void loop() { firewall_api->handle_client(); }