void InterruptServiceRoutine() { if (digitalRead(TouchPadPin) == HIGH) { //Nothing to see here. Move along. } if (digitalRead(TouchPadPin) == LOW) { TouchPadEventFlag = 1; EventCounter++; } }