 
     if(inViolationForExactDuration(lowThreshExceededCounter, numLowTempViolations)) {
       Serial.println(" lowTempViolation");
-      publishViolationEvent(numLowTempViolations, "lowTempViolation");
+      publishTempEvent("lowTempViolation", fahrenheitTemp);
+      Particle.publish("fahrenheitTempLog", "lowTempViolation");
       lowThreshExceededCounter = 0; // now reset notification sequence
     }
   }
   else {
     lowThreshExceededCounter = 0;
   }
-}
-
-float getCelsiusTemp() {
-  return celsiusTemp;
 }
 
 void loop(void) {

  return counter == numAllowedViolations;
}

void publishViolationEvent(int numViolations, char* eventName) {
  sprintf(publishString,"%.2f", fahrenheitTemp);
  Particle.publish(eventName, publishString);
}


    if(inViolationForExactDuration(highThreshExceededCounter, numHighTempViolations_level1)) {
      Serial.println(" highTempViolation_level1");
      publishTempEvent("highTempViolation_level1", fahrenheitTemp);
      Particle.publish("fahrenheitTempLog", "highTempViolation_level1");
    }
    if(inViolationForExactDuration(highThreshExceededCounter, numHighTempViolations_level2)) {
      Serial.println(" highTempViolation_level2");
      publishTempEvent("highTempViolation_level2", fahrenheitTemp);
      Particle.publish("fahrenheitTempLog", "highTempViolation_level2");
    }
    if(inViolationForExactDuration(highThreshExceededCounter, numHighTempViolations_level3)) {
      Serial.println(" highTempViolation_level3");
      publishTempEvent("highTempViolation_level3", fahrenheitTemp);
      Particle.publish("fahrenheitTempLog", "highTempViolation_level3");
      highThreshExceededCounter = 0; // now reset notification sequence
    }
  }
