I am working on a garage door opener with a sparkfun capacitive touchpad as a button. I am trying to use an interrupt to call the opendoor/closedoor function if the button was touched. Every time I touch the button the photon panics and restarts. The touchpad is connected to D2.
here’s the code
const int TOUCH_BUTTON_PIN = D2;
attachInterrupt(TOUCH_BUTTON_PIN, doorButton, RISING);
What am I doing wrong panicking the photon?