   Console.begin();    
 
   while (!Console);
-  Console.print("\nPlantStation is warming up.\nYun Console is warming up.\nKeen is warming up.\n\n");
+  Console.print("\n PlantStation is warming up.\n\n 60 seconds to first event recording.\n\n");
 
   // Because we need initial moisture and water level readings
   digitalWrite(hygroPower, HIGH);

//===== For water pump ===========================
const byte waterPumpPin = A5;
// todo - find right value for this
const int waterLevelThreshold = 20; // <- made this up    
boolean waterPumpIsOn = false;
unsigned long wateringSeconds = 30000;
unsigned long prevWatering = 0;
int waterMaxVal = 450;
int waterMinVal = 325;   

//===== For timed events =========================
// todo - timed events use regule marers for 1 min 1 hour etc and divide blah
unsigned long prevMinOneMillis = 0;    
unsigned long minOneInterval = 60000;
unsigned long prevMinFiveMillis = 0;
unsigned long minFiveInterval = 300000;
unsigned long prevHourTwelveMillis = 0;
unsigned long hourTwelveInterval = 43200000;

void setup() {
  pinMode(lightSwitchPin, OUTPUT);

  myKeen.addEvent("arduino_board_test", my_output);
  myKeen.printRequest();

  Console.println("");

  while (myKeen.available()) {
    char c = myKeen.read();
    Console.print(c);
  }

  Console.print("\t\t\t\t|");
//  Console.flush();
  Console.print("\n-------------------------------------------------\n");
}

void outputEvent() {  

  String newLine = "|\t\t\t\t\t\t|\n";
  String endline = "\t\t\t|\n";

  String my_output = "\n ";
  my_output += millis();
//  my_output += "\t\t\t\t\t|";
  my_output += "\n-------------------------------------------------\n"; 
//  my_output += "\n";
  my_output += "| App Id\t\t";          my_output += appId;               my_output += endline;
  my_output += "| Location\t\t";        my_output += location;            my_output += "\t|\n";
  my_output += newLine;
  my_output += "| Temp Air, C\t\t";     my_output += am.tempAirC;         my_output += endline;
  my_output += "| Temp Soil, C\t\t";    my_output += sm.tempSoilC;        my_output += endline;
  my_output += "| Temp Air, F\t\t";     my_output += am.tempAirF;         my_output += endline;
  my_output += "| Temp Soil, F\t\t";    my_output += sm.tempSoilF;        my_output += endline;
  my_output += newLine;
  my_output += "| Heat Index\t\t";      my_output += am.heatIndex;        my_output += endline;
  my_output += "| Humidity %\t\t";      my_output += am.humidityAir;      my_output += endline;
  my_output += newLine;
  my_output += "| Light %\t\t";         my_output += lightPercent;        my_output += endline;
  my_output += "| Light Val\t\t";       my_output += lightResistorVal;    my_output += endline;
  my_output += "| Light Is On\t\t";     my_output += lightIsOn;           my_output += endline;
  my_output += newLine;
  my_output += "| Moisture\t\t";        my_output += moistureStatus;      my_output += endline;
  my_output += "| Moisture %\t\t";      my_output += moisturePercent;     my_output += endline;
  my_output += "| Moisture\t\t";        my_output += moistureSensorVal;   my_output += endline;
  my_output += newLine;
  my_output += "| Water Level\t\t";     my_output += waterLevelStatus;    my_output += endline;
  my_output += "| Water Level %\t\t";   my_output += waterLevelPercent;   my_output += endline;
  my_output += "| Water Level Val\t";   my_output += waterLevelVal;       my_output += endline;
  my_output += "| Water Pump Is On\t";  my_output += waterPumpIsOn;       my_output += endline;
  my_output += newLine;
      
  Console.println();
  Console.print(my_output);
}

