 }
 
 
-bool alarmButtonPushed()
-{
-  return (digitalRead(AlarmButton) == LOW && debounceDigitalRead(AlarmButton) == LOW);
-}
-
-bool timeButtonPushed()
-{
-  return (digitalRead(TimeButton) == LOW && debounceDigitalRead(TimeButton) == LOW);
-}
-bool offButtonPushed()
-{
-  return (digitalRead(OffButton) == HIGH && debounceDigitalRead(OffButton) == HIGH);
-}
-
-bool rotaryButtonPushed()
-{
-  return (digitalRead(RotaryButton) == LOW && debounceDigitalRead(RotaryButton) == LOW);
-}
 
 void turnOffLightsDueToOffButton()
 {

  return lastResult;
}

uint8_t computeMinRGBLevel(uint8_t* RGB)
{
  uint8_t myRGB[3] = {255, 255, 255};

    int16_t encoderDelta = encoder->getValue();
    if (encoderDelta != 0)
    {
      sunsetDimLevel += encoderDelta;
      sunsetDimLevel = min(100,max(0, sunsetDimLevel));
      matrix.print(sunsetDimLevel);
      if (sunsetDimLevel == 0) matrix.writeDigitNum(4, 0);
      matrix.writeDisplay();
      setColorForSunset();
      turnLightOn();
      modeActive = millis();
    }
