STM32CubeIDE basics - 04 EXTI HAL lab

  Рет қаралды 45,287

STMicroelectronics

STMicroelectronics

4 жыл бұрын

Learn how to create your STM32 based application using STM32CubeIDE
STM32CubeIDE can be used to create applications for STM32 devices using STM32Cube libraries (HAL and Low Layer versions).
Benefits you will take away
• Understanding how to create Hardware Abstraction Layer (HAL) based examples on STM32 devices
• Understanding how to create Low Layer based examples on STM32
• Understanding how to manage software components and generated projects within STM32CubeIDE tool
Prerequisites
• NUCLEO-G071RB board
• microUSB cable
• PC with MS Windows OS (in version 7 or higher) with preinstalled the following software:
o STM32CubeIDE with STM32G0 Cube library preinstalled (libraries installation instruction present within “Repository management” video)
Complete set of slides:
drive.google.com/file/d/1qEyO...

Пікірлер: 33
@schmydstify
@schmydstify 2 жыл бұрын
Thank you for this instruction and the detailed explanations!
@peterdvorak802
@peterdvorak802 4 жыл бұрын
Great video. One small typo in "04 EXTI HAL lab.pdf" page 17 "In this example we are going to use one button - blue one (connected to PA5 as seen in the schematic below)"
@Ferreira019760
@Ferreira019760 2 ай бұрын
Very good content, slow paced which is ideal for beginners, it's just a pity that the voice is monotone. At least in me it induces sleep. Aside from that, I have nothing to fault the videos, good work.
@otabektillavayev3309
@otabektillavayev3309 Жыл бұрын
Thanks of millions
@NathanaelB28
@NathanaelB28 4 жыл бұрын
Variables used in Interrupt functions should be declared volatile.
@kavorka8855
@kavorka8855 3 жыл бұрын
Why?!
@jakoblecker6592
@jakoblecker6592 2 жыл бұрын
@@kavorka8855 to not have issues with compiler optimization. (If variables arent changed in the code, compiler doesnt know they are changed from outside).
@hopeithelps342
@hopeithelps342 Жыл бұрын
I had the same issue when following along using the F769IDisco board. The code was getting stuck in an Error handler while loop before I could ever press the blue button. My problem was I initialized the project by the board and not the MCU. Once I initialize using only the MCU, and set up only the LED and Button pins, there was no other mystery code/interrupts trapping the execution.
@luacardoso6825
@luacardoso6825 2 жыл бұрын
Great Video. When i try to employ this resource on stm32f103c8 and stm32f407VE i've got an issue (both uC). I set falling edge trigger on EXTI when i apply 200 Hz signal (0 to 3,3V) to EXTI GPIO, the output should just to toggle, but through osciloscope i've seen this not happen exatly this way. Sometime has toggle on rising edge, sometime has a toggle on falling edge ( i've set only rising) and sometime no has togle in rising edge. Is there any setting that improves the EXTI performance in frequency (even low frequency)?
@annamanaseryan6179
@annamanaseryan6179 Жыл бұрын
thank you!!!
@jesseissorude
@jesseissorude 2 жыл бұрын
Is he filming this while being held hostage?
@renyvincent4406
@renyvincent4406 2 жыл бұрын
lol
@nikoloznadiradze7370
@nikoloznadiradze7370 4 жыл бұрын
Also, whole HW or HAL, LL level measures to be taken to avoid false toggling due to noise when pressing the button...
@hectorfernandezalvarez9637
@hectorfernandezalvarez9637 3 жыл бұрын
To avoid that, you may create some flags that can help you to make the tasks of your project with the transitions, if you are using pull up config, it could be with the 1 to 0 transition, otherwise with the pull down config will be with the 0 to 1 transition
@nikoloznadiradze7370
@nikoloznadiradze7370 4 жыл бұрын
What if IDE doesn't generate separate rising and falling edge callbacks in its hal_gpio.c file and generates one EXTI callback? this is in IDE 1.3 void HAL_GPIO_EXTI_IRQHandler(uint16_t GPIO_Pin) { /* EXTI line interrupt detected */ if (__HAL_GPIO_EXTI_GET_IT(GPIO_Pin) != 0x00u) { __HAL_GPIO_EXTI_CLEAR_IT(GPIO_Pin); HAL_GPIO_EXTI_Callback(GPIO_Pin); } }
@chaaalyy
@chaaalyy 4 жыл бұрын
It´s not difficult to check the actual pin state and decide, how to continue... if (GPIOA->IDR & GPIO_Pin) {...} // true, if GPIO_Pin on port A is high ... there are also HAL functions for this (just don´t know them, because i never used them..)
@felipekunzler9618
@felipekunzler9618 3 жыл бұрын
hello, I dont have the both callbacks, just 1: HAL_GPIO_EXTI_Callback() ... why?
@stmicroelectronics
@stmicroelectronics 3 жыл бұрын
Hi there, for technical questions we really recommend you check out our community of experts and other developers at community.st.com
@Seff2
@Seff2 3 жыл бұрын
Same here.. did you figure it out?
@ericnovikoff5077
@ericnovikoff5077 3 жыл бұрын
I am using this lesson for a STM32G474RE nucleo board and got the same problem. It seems that if you are already selecting the falling edge for the interrupt in the hardware, you could just set the flag in the interrupt service routine itself (in the user code section) and not worry about the callback, or you could just use the callback you were given (as shown in your message) and redefine it, since it's only called on the falling edge anyway. This is a question for the instructor or the community, but I got it to work by doing the latter since it followed the course more closely.
@ericnovikoff5077
@ericnovikoff5077 3 жыл бұрын
@@stmicroelectronics these are class-specific questions that would be nice to have the instructor or another one to get answers from.
@ericnovikoff5077
@ericnovikoff5077 3 жыл бұрын
Yes. See my reply to Felipe below.
@MilanKarakas
@MilanKarakas 3 жыл бұрын
Seems that this way of programming understand only employers of the STM. Unable to make any program. Tried GPIOB->BSRR = GPIO_BSRR_BS11;, but that thing does not works.
@stmicroelectronics
@stmicroelectronics 3 жыл бұрын
Hello, Visit our online community to find answers to your technical questions and share ideas with your developers and ST experts : community.st.com
@carlosvaldez9281
@carlosvaldez9281 Жыл бұрын
I don't understand how the function HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) recognise the GPIO_Pin. What if I am using another button with another flag? I am missing something I think.
@stmicroelectronics
@stmicroelectronics Жыл бұрын
Hi there, thanks for your question - may we point you towards our community.st.com, where you will find a team of people who can answer you directly ?
@al-moutazbillah3693
@al-moutazbillah3693 11 ай бұрын
Your sound is very low! Is there someone sleeping near you?
@matheussouza-zo9ke
@matheussouza-zo9ke 3 жыл бұрын
Man, speak like a normal people, plis
@angelabackred2173
@angelabackred2173 3 жыл бұрын
😂😂
@stmicroelectronics
@stmicroelectronics 3 жыл бұрын
Hi, thanks for watching, our engineers do their very best to create this content and we do consider your comment !
@ericnovikoff5077
@ericnovikoff5077 3 жыл бұрын
I had to adapt to his accent as well. Then, I remembered this video is for people all around the world who speak English, and not just Americans. So indeed, it could be made by an English speaking person anywhere in the world who also might have an accent. Personally, I'm really glad he made the video and I'm willing to adapt to the accent out of gratitude.
@matheussouza-zo9ke
@matheussouza-zo9ke 3 жыл бұрын
@@ericnovikoff5077 man, you're right
@daniel0191bg
@daniel0191bg 3 жыл бұрын
@@ericnovikoff5077 we are talking about a multimillion USD company, if they want us to use their products, they should get someone who speaks neutral and clear English. The learning contents in Texas instruments are easy to understand and follow. Many of us are not here to learn how to develop embedded systems, we are learning how to use ST's products.
STM32CubeIDE basics - 05 TIM PWM HAL lab
13:37
STMicroelectronics
Рет қаралды 61 М.
1❤️
00:17
Nonomen ノノメン
Рет қаралды 13 МЛН
МАМА И STANDOFF 2 😳 !FAKE GUN! #shorts
00:34
INNA SERG
Рет қаралды 4,7 МЛН
STM32CubeIDE basics - 10 ADC DMA TIM HAL lab
31:32
STMicroelectronics
Рет қаралды 58 М.
STM32CubeIDE basics - 12 FreeRTOS basic lab
32:39
STMicroelectronics
Рет қаралды 27 М.
STM32CubeIDE basics - 11 USART HAL lab
10:55
STMicroelectronics
Рет қаралды 61 М.
STM32CubeIDE basics - 03 GPIO HAL lab
17:50
STMicroelectronics
Рет қаралды 73 М.
HAL: #3 How to - UART
6:37
Web learning
Рет қаралды 74 М.
Lecture 11: External interrupts (EXTI)
12:50
Embedded Systems and Deep Learning
Рет қаралды 60 М.
STM32 Guide #2: Registers + HAL (Blink example)
30:02
Mitch Davis
Рет қаралды 186 М.
Tutorial on STM32 External Interrupts and callback funktions
24:31
iPhone 16 с инновационным аккумулятором
0:45
ÉЖИ АКСЁНОВ
Рет қаралды 7 МЛН