F๐Ÿ’ปW/Coding

Silicon Lab EFR32 ์ฝ”๋“œ ๋ถ„์„

์ฒœ์ˆญ์ด 2023. 6. 26. 13:42

๋ณด๋“œ : EFR32MG22

 

GPIO

LED0 : GPIOD2

LED1 : GPIOD3

BUTTON0 : GPIOB0

BUTTON2 : GPIOB1

 

- GPIO ์„ธํŒ…

  // Configure Button PB1 as input and enable interrupt
  GPIO_PinModeSet(BSP_GPIO_PB1_PORT, BSP_GPIO_PB1_PIN, gpioModeInputPull, 1);
  GPIO_ExtIntConfig(BSP_GPIO_PB1_PORT,
                    BSP_GPIO_PB1_PIN,
                    BSP_GPIO_PB1_PIN,
                    false,
                    true,
                    true);