Go Down

Topic: Buttons, interrupts and de-bouncing (Read 6069 times) previous topic - next topic


So does it make sense to always use interrupts

No. Nor does it make sense to always use polling.

As a matter of fact, it doesn't make sense to always do anything.


Ok, more confused :smiley-roll:
I found this from Ladyada and she writes:
"To change the pins or number of buttons, just put them in the array called "buttons" and the rest of the code will automatically adjust."
The second sketch uses interrupts. But she is using analog inputs and how can i just ad buttons if i can't just
use every input pin as interrupt??

This sketch also says: "which pin to use for reading the sensor? can use any pin!"

Go Up