I’m having some trouble with the encoder on my Daisy Patch. It doesn’t respond to presses reliably. I have code to check for a press-and-release like this:
int risingEdge = 0;
int fallingEdge = 0;
while(!(risingEdge && fallingEdge))
{
hw.ProcessDigitalControls();
risingEdge |= hw.encoder.RisingEdge();
fallingEdge |= hw.encoder.FallingEdge();
}
It registers a press maybe half the time. Sometimes it will not register a press at all until I rotate the encoder. Is there a fault with my module?