Skip to content

Files

Latest commit

21ae1ed · Sep 11, 2021

History

History
This branch is 86 commits ahead of, 3 commits behind MYaqoobEmbedded/STM32-Tutorials:master.

Tutorial 07 - EXTI

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021
Sep 11, 2021

Tutorial 07 - EXTI

1. GPIO PIN Configuration

  • GPIO mode : Rising edge / Falling edge Trigger
  • GPIO Pull-up/Pull-down
  • NVIC interrupt Enable

2. EXTI Callback function

void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin)
{
  if (GPIO_Pin == GPIO_PIN_0)
  {
    HAL_GPIO_TogglePin(GPIOG, GPIO_PIN_13);
  }
}