   }
 }
 
+/*
+ * Possibly change state based on time and light level triggers. 
+ * 
+ * Truth tables are intentionally worked out as long form conditions for the sake of clarity.
+ */
 void handleTriggers() {
 
   updateLight();

      LightThreshTicks = 0;
    }
  } else if ( DoorPosition != DOOR_POSITION_DOWN && (
      ( ! between(ClockThreshDown, Now, ClockThreshUp) && LightCurrent < LightThreshUp ) || 
      ( between(ClockThreshDown, Now, ClockThreshUp) && LightCurrent < LightThreshDown ) 
    )
  ) {

    // See if we could potentially change door position
    // If not, there's nothing else to do here
    if ( DoorPosition == DOOR_POSITION_DOWN ) {
      return;
    }

    LightThreshTicks++;
    updateLCD();

    return;
  }

  // LightCurrent > LightThreshDown
  // LightCurrent > LightThreshUp
  // ClockThreshDown, Now, ClockThreshUp
  // high.totalseconds() < totalseconds(Now) < high.totalseconds();

  // Determine if door should move up or down
  if ( DoorPosition != DOOR_POSITION_UP && (
       ( LightCurrent > LightThreshUp && LightCurrent > LightThreshDown && totalseconds(Now) > ClockThreshUp.totalseconds() && totalseconds(Now) > ClockThreshDown.totalseconds() ) ||
       ( LightCurrent > LightThreshUp && LightCurrent > LightThreshDown && totalseconds(Now) < ClockThreshUp.totalseconds() && totalseconds(Now) > ClockThreshDown.totalseconds() ) ||
       // Ambiguous. Open when clock says to open, but there is not enough light to trigger an open
       ( LightCurrent < LightThreshUp && LightCurrent > LightThreshDown && totalseconds(Now) > ClockThreshUp.totalseconds() && totalseconds(Now) < ClockThreshDown.totalseconds() ) ||
       ( LightCurrent > LightThreshUp && LightCurrent > LightThreshDown && totalseconds(Now) > ClockThreshUp.totalseconds() && totalseconds(Now) < ClockThreshDown.totalseconds() )
     )
  ) {
    
    LightThreshTicks++;
    updateLCD();
    if ( LightThreshTicks > LIGHT_THRESH_TICKS_TO_CHANGE ) {
