     //   digitalWrite(hvClock, LOW); 
     PORTF = PORTF & B01111111;
     //   digitalWrite(hvClock, HIGH);
-    PORTF = PORTF | B10000000;
-  }
+//    PORTF = PORTF | B10000000;
+  }
+  PORTF = PORTF | B10000000;
 
   
 }

int smoothedSampleTemp[smoothedSenseSize - smoothedTouchWindow];

int channelMean[] = {0, 0, 0, 0};
int chanThreshold[] = {1,1,1,1};

void loop() {
    senseResults = senseAll(1500, true);

    }

    for (int channel = 0; channel < channelCount; channel++) { 
      channelMean[channel] = (channelMean[channel] * 3 + 
                              smoothedSenseHistory[channel][(smoothedSenseIter + 1 + smoothedSenseSize) % smoothedSenseSize]) / 4;
      Serial.print(", ");
      Serial.print(smoothedSenseHistory[channel][smoothedSenseIter] - channelMean[channel]);
      Serial.print(", ");

//      if (channelMean[channel] - smoothedSenseHistory[channel][smoothedSenseIter] > 25) { 
//        chanThreshold[channel] = 3;
//      }

      if (switchedCount == 0 && 
          channelMean[channel] - smoothedSenseHistory[channel][smoothedSenseIter] > chanThreshold[channel] && 
