 
 double currHLT = 150;
 double currRIMS = 151;
+double prevHLT = 0;
+double prevRIMS = 0;
 
 boolean paused = true;
 int mode = 0;
 int prevmode = 0;
 
 const int window = 5000; //Time in milliseconds to calculate duty cycle
+const int tempInterval = 500; //Time in milliseconds to check temps
 long previousMillis = 0;
+long tempPrevMillis = 0;
 boolean BKon = false;
  
 #define Neutral 0

  {
    case 0:
      //firing the HLT only
      if ((!paused) && (currHLT < setHLT))
      {
        elementOn(0);
      }

  
  //read in temps here and set value on screen if changed
  
  if (currentMillis - tempPrevMillis  > (long)tempInterval)
  {
    currHLT = HLTthermocouple.readFarenheit();
    if (isnan(currHLT))
    {
      currHLT = 0;
    }
    if (currHLT != prevHLT)
    {
      setValue(0, 1, currHLT);
      prevHLT = currHLT;
    }
    
    currRIMS = RIMSthermocouple.readFarenheit();
    if (isnan(currRIMS))
    {
      currRIMS = 0;
    }
    if (currRIMS != prevRIMS)
    {
      setValue(1, 1, currRIMS);
      prevRIMS = currRIMS;
    }
    tempPrevMillis = currentMillis;
  }

  
  //actual element control goes here
