 
 void printTemperature(DallasTemperature sensors, DeviceAddress deviceAddress, char const * topic, float calibration, int ctr)
 {
-  sensors.requestTemperatures();
-  delay(1000);
-
   float tempC = sensors.getTempC(deviceAddress);
   if (tempC == -127.00 or tempC < -15 or tempC > 59) {
     if (ctr < 3) {
       printTemperature(sensors, deviceAddress, topic, calibration, ++ctr);
-    }
-    else
-    {
-      Serial.println(String("Error reading:").concat(topic));
     }
   }
   else {

    client.publish("domogik/buttonan3", "0");
  }

  if (count == 1 * intervalReading) {
    printTemperature(sensors, thermometer7, "domogik/berging", 0.5, 0);
  }
  if (count == 2 * intervalReading) {
    printTemperature(sensors, thermometerT, "domogik/tempT", 0, 0);
    //second bus
  }
  if (count == 3 * intervalReading) {
    printTemperature(sensors2, thermometer5, "domogik/traponder", -0.4, 0);
  }
  if (count == 4 * intervalReading) {
    printTemperature(sensors2, thermometer10, "domogik/inkom", 0, 0); //inkom
  }
  if (count == 5 * intervalReading) {
    printTemperature(sensors2, thermometer11, "domogik/wconder", 0.3, 0); //wc onder
  }
  if (count == 6 * intervalReading) {
    printTemperature(sensors2, thermometer9, "domogik/paulien", 0, 0);//paulien
  }
  if (count == 7 * intervalReading) {
    printTemperature(sensors2, thermometer3, "domogik/wcboven", 0.3, 0); //wc boven
  }
  if (count == 8 * intervalReading) {
    printTemperature(sensors2, thermometer4, "domogik/keuken", -0.8, 0);
  }
  if (count == 9 * intervalReading) {
    printTemperature(sensors2, thermometer12, "domogik/living", 0.2, 0);
  }
  if (count == 10 * intervalReading) {
    printTemperature(sensors2, thermometer6, "domogik/trapboven", 0.4, 0);
  }
  if (count == 11 * intervalReading) {
    printTemperature(sensors2, thermometer13, "domogik/slpkberg", 0, 0);
  }
  if (count == 12 * intervalReading) {
    printTemperature(sensors2, thermometer15, "domogik/badk", 0.8, 0);
  }
  if (count == 13 * intervalReading) {
    printTemperature(sensors2, thermometer16, "domogik/vide", 0, 0);
  }
  if (count == 14 * intervalReading) {
    printTemperature(sensors2, thermometer14, "domogik/masterslpk", 0.3, 0);
    count = 0;
  }

  count = count + 1;
  client.loop();
}


DallasTemperature sensors2(&oneWire2);

#define DEUR_OPEN_TOPIC "domogik/in/deur"
bool isNextReadSensors = true;
bool isNextReadSensors2 = false;

// Assign the unique addresses of your 1-Wire temp sensors.
// See the tutorial on how to obtain these addresses:
