 #include "neopixel.h"
 
 //photon has 2048 bytes of emulated EEPROM
-#define EEPROM_ADDR_T0 0 //400 bytes per tap
-#define EEPROM_ADDR_T1 400
-#define EEPROM_ADDR_T2 800
+#define EEPROM_ADDR_T0 0 //600 bytes per tap
+#define EEPROM_ADDR_T1 600
+#define EEPROM_ADDR_T2 1200
 
 #define PIXEL_TYPE WS2812B
 #define PIXEL_COUNT 14
+
+#define FLOW_PIN_T0 D6
+#define FLOW_PIN_T1 D5
+#define FLOW_PIN_T2 D4
+#define LED_PIN_T0 D3
+#define LED_PIN_T1 D2
+#define LED_PIN_T2 D1
 
 struct TapObject
 {
   int pulseCount;
   int maxPulseCount;
   int instantPulseCount;
+  int flowStartPulseCount;
   int previousPulseCount;
   int flowing;
   int previousFlowing;

    else
    {
      //publish a stop event
      Particle.publish("stop-flow-T1", String(T1.maxPulseCount) + 
                       "," + String(T1.pulseCount) + "," + String(T1.percentFull));
    }
  }


  {
    if(T2.flowing)
    {
      T2.flowStartPulseCount = T2.pulseCount;
      //publish a start event
      Particle.publish("start-flow-T2", String(T2.maxPulseCount) + 
                       "," + String(T2.pulseCount) + "," + String(T2.percentFull));
    }
    else
    {
      String data = String(T2.maxPulseCount) + 
                       "," + String(T2.pulseCount) + "," + String(T2.percentFull) +
                       "," + String(T2.flowStartPulseCount - T2.pulseCount);
      Serial.println("stop-flow-T2 Data: " + data);
      Particle.publish("stop-flow-T2", data);
    }
  }
}
