 		Particle.publish(eventPrefix + "/waterTankPump/pumpOn", boolToText(pumpOn));
 		(data == "true") ? lastSignal = millis() : Serial.println(data);
 	} else if (event == eventPrefix + "/waterTankSensor/waterHeight") {
+		heardFromSensor = true;
 		waterHeight = data.toFloat();
 	}
 }
unsigned long lastSignal = millis();
unsigned long pumpTimeout = 15*60*1000; // turn off the pump if haven't heard from sensor in 15 mins
unsigned long pumpOffTime = 60*60*1000; // make sure we don't turn on the pump more than once per hour
long pumpOffTimeStart = -pumpOffTime; // so we can turn on pump when we startup if we need to

// PIR motion sensor
int relayPin = 0;

}

void autoPumpControl() {
	if (heardFromSensor) {
		if (pumpOn) {
			if (millis() - lastSignal > pumpTimeout) { // if we haven't heard from the water tanks in a while, turn off the pump
				relayControl("off");
			}
		}
		if (waterHeight < lowerCutoff && millis() - lastPumpTimeOff > pumpOffTime) {
			success = relayControl("on");
		} else if (waterHeight > higherCutoff) {
			success = relayControl("off");
			lastPumpTimeOff = millis();
		} else {
			Serial.println("not doin nothin");
		}
	}
}

