#pragma once #include namespace WiFiManagerHelpers { constexpr const char* WiFiManagerName = "MicroRadar-Setup"; static void ConfigureWiFiManager(WiFiManager& wm, LGFX& tft) { wm.setTitle("Micro Radar - Setup WiFi"); wm.setCustomHeadElement(""); wm.setAPCallback([&tft](WiFiManager* wifiManager) { tft.fillScreen(lgfx::color888(0, 0, 0)); tft.setTextColor(lgfx::color888(0, 255, 0)); const int lineHeight = tft.fontHeight() + 10; const int screenSize = 240; tft.drawCenterString("- SETUP -", screenSize / 2, screenSize / 2 - lineHeight); tft.drawCentreString("Connect to this WiFi hotspot:", screenSize / 2, screenSize / 2); tft.drawCenterString(WiFiManagerName, screenSize / 2, screenSize / 2 + lineHeight); } ); } }