When I initialize a pin as input_pullup, everything works as expected. When I measure the line, I get 3.3V, and I can pull it to GND, and reading it works perfectly.
However, when I set an attachinterrupt on this pin, it no longer works. The voltage stays at around 0V. The pin then behaves unpredictably. Sometimes the change to 0 is detected, sometimes it’s not.
Both methods of the attachment with the same result. I'm sure it worked fine before the update of the board in the IDE.
I know that I can use en external resistor and this will be my workaround. But - what is wrong?
You read code examples that are supposed to help you, you type them, you run them, it doesn't work.
Why so much hate ?
I thought I had a bad contact in the wires because as soon as I touched the wire of the digital input the LED lights up and as soon as I let it go, everything went out. 0V to the voltmeter in the wire !?! That said, it makes a great free capacitive switch because you just have to touch the wire at the plastic and the LED lights up (if you make it light up in the interruption ISR which unfortunately does not stop triggering as long as you touch the plastic).
2 days spent on it.
Out of masochism I'm going to try arming the same interrupt on the M4.