       break;
     }
   }
+  
+	Serial.println(F("Waiting 1 min... - sleep time"));
+  delay(60000); // wait
+  
+}
 
-  // close the TCP connection 
-  network.send_command("AT+CIPCLOSE", "OK", 2, 1500);
-  // disconnect from the AP to conserve energy
-  network.send_command("AT+CWQAP", "OK", 2, 1500);
-
-  // turn off the module
-  digitalWrite(12, LOW);
-
-	Serial.println(F("Waiting 5 min... - sleep time"));
-  delay(10); // necessary in order to get the text out the serial 
-
-  // stop the led
-  Heartbeat::stop();
-
-  // sleep for 5 min = 10 sec * 30 
-  for(int i = 0; i < 1; i++){
-    EnableWatchDog(0b100001); // sleep for 8 seconds
-    digitalWrite(13, HIGH);
-    EnableWatchDog(0b000110); // sleep for 1 second
-    digitalWrite(13, LOW);
-    EnableWatchDog(0b000110); // sleep for 1 second
-  }
-}
 
 // disable watchdog interrupt
 ISR(WDT_vect){

	for(int i = 0; i < 3; i++)
		Serial.print(F("==============="));

	
	// Startup a heartbeat LED.
	Heartbeat::start();


    Serial.println(i);
    
    if(!network.send_packet(sensor_data)){
      if(i == 2){   
        // start panic mode
        Heartbeat::panic();
      }
