| ▲ | PunchyHamster an hour ago | |
Doesn't matter, their way is terrible one that adds latency for no reason. There are 2 things here worth paying attention * first "bounce" is user action * last "bounce" is stop of user action. You can run action on first bounce then just ignore the button for whatver debounce period you deem satisfactory. But adding delay to start action is always wrong answer for debouncing. Now the harder problem is the off of the button, especially if hold is also an action but "be off for at least few ms" usually handles it well and off time is not lag user feels | ||