 #ifdef DEBUG
   #define DEBUG_PRINT(n) Serial.print(n);
   #define DEBUG_PRINTLN(n) {Serial.println(n); delay(100); }
+  #define DEBUG_PRINTTIME(n) printTime(n);
 #else
   #define DEBUG_PRINT(n) {}
   #define DEBUG_PRINTLN(n) {}
+  #define DEBUG_PRINTTIME
 #endif
 
 void printTime( DateTime &dt )

  pinMode(MODE_SWITCH_PIN,INPUT_PULLUP);

  EEPROM.get(MODE_INDEX,mode);
  Serial.print(F("Got mode from eeprom ") );
  Serial.println(mode);
  if ( mode < 0 )
    mode = 0;

  int32_t wakeUnixTime;
  EEPROM.get(WAKE_INDEX,wakeUnixTime);

//#define DEBUG
#include <EEPROM.h>

// RTC
