Connect up to 10 buttons using a single interrupt.
Project tutorial by Svizel_pritula
This exoskeleton was designed to help a patient suffering from paralysis to rehabilitate faster.
We use an Arduino to build an autonomous "follow me" cooler that connects to a smartphone via Bluetooth and uses GPS to navigate.
Project tutorial by Hacker Shack
Replacing the old and expensive mechanical system with the much reliable and cheap electrical system!
Project showcase by PuranSingh and PiaraSingh
Hi, I don't know what else you are doing in your loop, but generaly it shouldn't take too long to use polling. If you're doing time sensitive operations, basicaly any solution you might use to detect button presses will distupt it. This solution won't work correctly if you press multiple "buttons" at once anyway. Perhaps you can try change interrupts on multiple ports?
While there is no way to figure out for sure which one it was, but we assume it's the one that's currently pressed. In my code, I just use a for loop to go over all pins and check if they're being pulled low.
It's not the debounce, the problem is that having one button pressed will stop the interrupt from being triggered at all. You can get around that by either doing the checking in the loop once you detect a press, or by putting a pin to INPUT once its button is pressed. Both options have flaws, through. In this case, pin change interrupts are probably the best. (See link in the introduction)
Or connect with your social account:
New here? Create an account