 /////////////////////////////////////////////////////////////////////////////
 // sensor/actuator stuff ////////////////////////////////////////////////////
 void startPeripherals() {
-  Serial.println("startPeripherals");
+  Serial.println("\nstartPeripherals...");
   mySwitch.enableTransmit(15);   // RC transmitter is connected to Pin 15
 
   tempSensor.begin();     // start the onewire temperature sensor

  }

  if(loopCounter++ == LOOP_ROLLOVER) loopCounter = 0;
}

/////////////////////////////////////////////////////////////////////////////

  dnsServer.processNextRequest();
  webServer.handleClient();

  if(loopCounter == TICK_MONITOR) { // monitor levels, valve logic, push data
    monitor_t* now = &monitorData[monitorCursor];
    if(monitorSize < MONITOR_POINTS)
      monitorSize++;
    now->timestamp = millis();
    if(GOT_TEMP_SENSOR) {
      getTemperature(&now->waterCelsius);               yield();
    }
    if(GOT_HUMID_SENSOR) {
      getHumidity(&now->airCelsius, &now->airHumid);    yield();
    }
    if(GOT_LIGHT_SENSOR) { getLight(&now->lux);         yield(); }
    if(GOT_PH_SENSOR) { getPH(&now->pH);                yield(); }
    if(GOT_LEVEL_SENSOR) {
      getLevel(LEVEL_ECHO_PIN1, &now->waterLevel1);     yield();
      getLevel(LEVEL_ECHO_PIN2, &now->waterLevel2);     yield();
      getLevel(LEVEL_ECHO_PIN3, &now->waterLevel3);     yield();
    }

    doValveLogic(); yield(); // set pumps on and off etc.
// TODO    doValveLogic(now, &flowState); yield(); // set pumps on and off etc.
    if(SEND_DATA) { postSensorData(&monitorData[monitorCursor]); yield(); }
      
    if(++monitorCursor == MONITOR_POINTS)
      monitorCursor = 0;
    // delay(500);
  }

  if(loopCounter == TICK_WIFI_DEBUG) {
    Serial.print("SSID: "); Serial.print(apSSID);
    Serial.print("; IP address(es): local="); Serial.print(WiFi.localIP());
