• Try:

    setWatch(function() {
      console.log("Pressed");
    }, NOdeMCU:D5, { edge: "rising", debounce: 50, repeat: true });
    
  • No dice.

    I was able to make your code work by changing it to D3 (one of the exposed IO), and touching the pin off to ground; so your code is good; but the on-board switch seems bad.

    Edit: I changed the edge to "falling" and they now work once per boot...very odd

About

Avatar for CMSpooner @CMSpooner started