• Hi! Since you're using a Puck, the pin names are a bit different (starting with D... and not Ax/Bx/etc) but yes what you're suggesting is fine apart from that.

    I'd say just connect a button between maybe pin D1 and the 3v pin (this means you don't need digitalWrite(A6, 1);/similar because the pin is already at a voltage).

    Then it's just:

    pinMode(D1, 'input_pulldown');
    setWatch(function(e) {
      controls.playpause(); // or whatever else you want to do
    }, D1, { repeat: true, edge: 'rising', debounce: 50 });
    
    // your other HID code here...
    
About

Avatar for Gordon @Gordon started