   _controller.run();
 }
 
-SensorThread tempSensor = SensorThread();
+SensorThread _tempSensor = SensorThread();
 
 void setup(void) {
+  delay(1000);
   Serial.begin(9600);
+  delay(1000);
+  _sensors.begin();
   pinMode(RELAY_PIN, OUTPUT);
-  tempSensor.pin = SENSOR_PIN;
-  tempSensor.setInterval(10000);
-  _controller.add(&tempSensor);
+  _tempSensor.pin = SENSOR_PIN;
+  _tempSensor.setInterval(10000);
+  _controller.add(&_tempSensor);
   Timer1.initialize(10000000);
   Timer1.attachInterrupt(timerCallback);
   Timer1.start();

Logger Log = Logger();

float getTemp() {
  byte i;
  byte present = 0;
  byte data[12];
  byte addr[8];
  unsigned long startTime;

  _ow.reset_search();
  if ( !_ow.search(addr)) {
    _ow.reset_search();
    startTime = millis();
    while (millis() - startTime < 3000);
    return ERROR_NO_MORE_ADDRESSES;
  }
  if (OneWire::crc8(addr, 7) != addr[7]) {
    return ERROR_CRC_IS_NOT_VALID;
  }
  // the first ROM byte indicates which chip
  int type_s = getChipType(addr[0]);
  if (!_ow.reset()) {
    return ERROR_FAILED_TO_RESET;
  }
  _ow.select(addr);
  _ow.write(0x44, 1);        // start conversion, with parasite power on at the end
  startTime = millis();
  while (millis() - startTime < 1000); // maybe 750ms is enough, maybe not
  // we might do a _ow.depower() here, but the reset will take care of it.
  present = _ow.reset();
  if (!present) {
    Log.info("Failed to reset");
  }
  _ow.select(addr);
  _ow.write(0xBE);         // Read Scratchpad
  for ( i = 0; i < 9; i++) {           // we need 9 bytes
    data[i] = _ow.read();
  }
  return convertTemp(data, type_s);
}

class SensorThread: public Thread {

#include <Thread.h>
#include <ThreadController.h>
#include <TimerOne.h>
#include <DallasTemperature.h>

#define RELAY_PIN 8   // Connect Digital Pin 8 on Arduino to ? on Relay Module
#define SENSOR_PIN 10
