La gente de India es bien inteligente... Gracias por compartir el conocimiento. Muchas gracias.
@NizarMohideen2 жыл бұрын
Thanks
@theblitz1687 Жыл бұрын
As far as i understood, for a falling edge detector button, this method only prevents debounce during falling edge. But debouncing still can happen while on rising edge. Edit: Figured the rising edge problem by making the button fall/rise and writing the code accordingly
@mckryall2 жыл бұрын
Great video, thank you! Good idea using the tweezers' cap as a nonconductive rod to poke things with.
@muzaffersemihturan99442 жыл бұрын
very good explanation thank u
@NizarMohideen2 жыл бұрын
Glad you liked it
@ДмитрийТисов-ж6я7 ай бұрын
Спасибо
@shambhusingh50942 жыл бұрын
Very good 👍
@NizarMohideen2 жыл бұрын
Thank you 👍
@paraskhosla96222 жыл бұрын
but you set the led pin to output like this "GPIOA->ODR |= GPIO_ODR_6;" or you created some function for led to toggle?
@Red_Fang. Жыл бұрын
i want to make long pressed push button, how can i improve debouncing button to make long pressed one ? thank you
@KaiMusic003 ай бұрын
Hi there I am using sensor as an input which will turn on the buzzer, and also using EXTERNAL interupt Buthon the to turn off the buzzer and turn on the LED but the code is not working. It is like when I siply power it only do one tast only butten not buzzer and also sensor stop working need help with example
@charnelmane24612 жыл бұрын
thank you for this good tutorial can you please do the same thing with an STM32L432KC and three LED?
@NizarMohideen2 жыл бұрын
Hi Charnel, I don’t have STM32L432 but it is simple. You can set three interrupts and three GPIO_Output. Good luck
@charnelmane24612 жыл бұрын
@@NizarMohideen I've already tried this a few times but it doesn't work properly
@NizarMohideen2 жыл бұрын
Is it working with only one button Click NVIC → EXTI line1 interrupt → Enabled (Tick) You need to tick correct line interrupt for the pin you are using
@charnelmane24612 жыл бұрын
@@NizarMohideen ok Thank you verry much i will try it
@AMBOKMUHAMMADFIRDAUSBINIMRAN6 күн бұрын
can the ground be connected at the same place
@NizarMohideen6 күн бұрын
Yes. You can
@KaiMusic004 ай бұрын
Can you creat vedio on LIFO and FIFO using GPS DATA
@ruanpotgieter25962 жыл бұрын
How does the code look in the main loop? One only calls the function with the pin name as argument?
@NizarMohideen2 жыл бұрын
We don't check the button condition in the main loop. Instead, the button interrupts and HAL_GPIO_EXTI_Callback is called whenever pressed. For a simple button example, please see video no 14 in my channel
@NizarMohideen2 жыл бұрын
kzbin.info/www/bejne/j4fFi4VpYqqiga8
@njan1242 Жыл бұрын
I want to make keyboard using push button that use arrow keys, space key, enter key, back space key, shift key
@shambhusingh50942 жыл бұрын
Please explain below condition - What is 10? if (GPIO_Pin == GPIO_PIN_1 && (currentMillis - previousMillis > 10))
@NizarMohideen2 жыл бұрын
Push button debounces multiple times due to its mechanical nature. For single push, it can send several interrupts. In this video, I have avoided any interrupts within 10 milliseconds from the original interrupt. Depending on the sensitivity of your push button, you can adjust this timing. Thank you
@shambhusingh50942 жыл бұрын
@@NizarMohideen Thank you 😊
@talhadeveci92982 жыл бұрын
@@NizarMohideen is this 10 milisecond delay or timer interrupt ? I mean is the code waiting at 10 milisecond line ?
@NizarMohideen2 жыл бұрын
10 milisecond is not timer 10 milisecond is not delay 10 milisecond is a counter using HAL_GetTick() We use this counter to check whether the interrupt happened within 10 milisecond from the last interrupt. If it is within 10 milisecond, the interrupt is from the same push of the button, Otherwise it is a another push of the button HAL_GetTick() is similar to millis function in arduino
@mz9zn4 ай бұрын
Works very bad and unstable. Sometimes it's ok, sometimes the LED returns to the previous state after button release.
@NizarMohideen3 ай бұрын
I have used 10 milli seconds to ignore debounce interrupts If the push button is not smooth, you may need to increase the time if (GPIO_Pin == GPIO_PIN_1 && (currentMillis - previousMillis > 10)) ^^^
@mz9zn3 ай бұрын
@@NizarMohideen I've already tried to set 50ms, but it doesn't help. Also, it's not a button problem. The same button works flawlessly with 50ms debouncing delay in my PIC code. But I'm new to STM32 and can't make it work yet.
@NizarMohideen3 ай бұрын
I will search for better way of doing with interrupt service routine. If anything better, I will let you know. In the mean time, you can also search for isr documents in the net. Thanks
@olegdemkiv5612 жыл бұрын
Іomeone has the problem this example? I thing, this method work only on the first moment, when you press the button, but if you release the button this method can detect second press.
@atpTUBE Жыл бұрын
You should check falling or rising edge of trigger of clock