 // Macros for debugging
 #ifdef DEBUG_TELNET
   #define     DEBUG_PRINT(x)    telnetClient.print(x)
+  #define     DEBUG_PRINT_WITH_FMT(x, fmt)    telnetClient.print(x, fmt)
   #define     DEBUG_PRINTLN(x)  telnetClient.println(x)
+  #define     DEBUG_PRINTLN_WITH_FMT(x, fmt)  telnetClient.println(x, fmt)
 #else
   #define     DEBUG_PRINT(x)    Serial.print(x)
+  #define     DEBUG_PRINT_WITH_FMT(x, fmt)    Serial.print(x, fmt)
   #define     DEBUG_PRINTLN(x)  Serial.println(x)
-#endif
-
-// Wi-Fi
-const char*   WIFI_SSID     = "Netgear";
-const char*   WIFI_PASSWORD = "0stem4dder";
+  #define     DEBUG_PRINTLN_WITH_FMT(x, fmt)  Serial.println(x, fmt)
+#endif
+
 #define HOST "ARILUX%s"
 char chipid[12];
+
+char          MQTT_CLIENT_ID[32];
 
 // MQTT topics
 char   ARILUX_MQTT_STATE_STATE_TOPIC[44];

char   ARILUX_MQTT_COLOR_COMMAND_TOPIC[44];
char   ARILUX_MQTT_WHITE_STATE_TOPIC[44];
char   ARILUX_MQTT_WHITE_COMMAND_TOPIC[44];

#define DEFARILUX_MQTT_STATE_STATE_TOPIC "%s/%s/state/state"
#define DEFARILUX_MQTT_STATE_COMMAND_TOPIC  "%s/%s/state/set"
#define DEFARILUX_MQTT_BRIGHTNESS_STATE_TOPIC "%s/%s/brightness/state"
#define DEFARILUX_MQTT_BRIGHTNESS_COMMAND_TOPIC "%s/%s/brightness/set"
#define DEFARILUX_MQTT_COLOR_STATE_TOPIC  "%s/%s/color/state"
#define DEFARILUX_MQTT_COLOR_COMMAND_TOPIC  "%s/%s/color/set"
#define DEFARILUX_MQTT_WHITE_STATE_TOPIC  "%s/%s/white/state"
#define DEFARILUX_MQTT_WHITE_COMMAND_TOPIC  "%s/%s/white/set"
const char*   TOPICPING =  "ping";
const char*   TOPICPONG = "pong";


// MQTT payloads
const char*   ARILUX_MQTT_STATE_WHITE015_PAYLOAD         = "4";
const char*   ARILUX_MQTT_STATE_WHITE001_PAYLOAD         = "3";
const char*   ARILUX_MQTT_STATE_WHITEFULLON_PAYLOAD         = "2";
const char*   ARILUX_MQTT_STATE_ON_PAYLOAD          = "1";
const char*   ARILUX_MQTT_STATE_OFF_PAYLOAD         = "0";

// MQTT buffer
char msgBuffer[32];

// MQTT
char          MQTT_CLIENT_ID[32];
const char*   MQTT_SERVER_IP                        = "192.168.1.200";
const int     MQTT_SERVER_PORT                      = 1883;
const char*   MQTT_USER                             = "";
const char*   MQTT_PASSWORD                         = "";

volatile uint8_t cmd = ARILUX_CMD_NOT_DEFINED;


        DEBUG_PRINTLN(F("INFO: IR_CODE_KEY_SMOOTH"));
        break;
      default:
        DEBUG_PRINT(F("ERROR: IR code not defined: "));
        DEBUG_PRINTLN_WITH_FMT(results.value, HEX);
        break;
    }
    irRecv.resume();
