// Set to true to define Relay as Normally Open (NO) #define RELAY_NO false // Set number of relays #define NUM_RELAYS 1 // Assign each GPIO to a relay int relayGPIOs[NUM_RELAYS] = {15}; // Replace with your network credentials const char* ssid = "xxxxxxxxxxxxxxxx"; const char* password = "xxxxxxxxxxxxxxxxxxxx"; void Wifi_connected(WiFiEvent_t event, WiFiEventInfo_t info){ Serial.println("Successfully connected to Access Point"); } void Get_IPAddress(WiFiEvent_t event, WiFiEventInfo_t info){ Serial.println("WIFI is connected!"); Serial.println("IP address: "); Serial.println(WiFi.localIP()); } void Wifi_disconnected(WiFiEvent_t event, WiFiEventInfo_t info){ Serial.println("Disconnected from WIFI access point"); Serial.print("WiFi lost connection. Reason: "); Serial.println(info.disconnected.reason); Serial.println("Reconnecting..."); WiFi.begin(ssid, password); } const char* PARAM_INPUT_1 = "relay"; const char* PARAM_INPUT_2 = "state";