Hello, I’m working on an application that uses a button to control LEDs. Every time I hold the button, the counter goes up by more than 1.
Sandeep kumar
Asked: August 2, 20222022-08-02T19:30:32+05:30 2022-08-02T19:30:32+05:30In: LEDs & Optoelectronics
LED Light
Share
Perhaps you should debounce the button since mechanical buttons can produce many pulses when pressed. One of the simplest methods is to connect a tiny capacitor in parallel to the button, which, along with the pull resistor, creates a low pass filter. To press that button, the time constant of thatRead more
Perhaps you should debounce the button since mechanical buttons can produce many pulses when pressed.
One of the simplest methods is to connect a tiny capacitor in parallel to the button, which, along with the pull resistor, creates a low pass filter. To press that button, the time constant of that filter needs to be a little bit less than the duration of the maximum speed (e.g. 100..200ms).
See less