   // function definition further below.
   MQTT_connect();
 
-  while (mqtt.readSubscription(10000)) {
+  while (mqtt.readSubscription(1000)) {
 
     // Turn the strip on
     if (strcmp((char *)onoffsw.lastread, "{\"On\":1}") == 0 && !led_on) {

#define SERVERPORT  1883 // The port of the MQTT broker

#define LED         4   // Pin controlling to the LED strip.
#define DS18B20     5   // Pin of Dallas DS18B20 digital thermometer

#define TMP_INTER   5  // Update interval of temperature given in minutes


unsigned int i = 0;

Adafruit_MQTT_Subscribe onoffsw = Adafruit_MQTT_Subscribe(&mqtt, "/light/1");
Adafruit_MQTT_Publish status_mqtt = Adafruit_MQTT_Publish(&mqtt, "/light/1/status");

void setup() {
  // Initialization
  pinMode(LED, OUTPUT);
  
  Serial.begin(115200);
  Serial.println();
  Serial.println();

  // We start by connecting to a WiFi network
  Serial.print("Connecting to ");
  Serial.println(ssid);
  WiFi.begin(ssid, pass);
  
  while (WiFi.status() != WL_CONNECTED) {
    delay(500);
    Serial.print(".");
  }
  Serial.println("");
  
  Serial.println("WiFi connected");
  Serial.println("IP address: ");
  Serial.println(WiFi.localIP());

  // Setup MQTT subscription for onoff feed.
