summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHiFiPhile <[email protected]>2024-04-09 23:55:38 +0200
committerHiFiPhile <[email protected]>2024-04-09 23:55:38 +0200
commit3ecabe3ebebbd896527619d27a785491ebe3421c (patch)
treef4488e6aa0fc45f691b1b11079e3036eb252899e
parent0d4465a0983dc6eda1aa59efe4d4b0414aba97ff (diff)
Fix stm32h573i_dk button & led.
-rw-r--r--hw/bsp/stm32h5/boards/stm32h573i_dk/board.h4
-rw-r--r--hw/bsp/stm32h5/family.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/hw/bsp/stm32h5/boards/stm32h573i_dk/board.h b/hw/bsp/stm32h5/boards/stm32h573i_dk/board.h
index 674cf8e2a..7baef6ca6 100644
--- a/hw/bsp/stm32h5/boards/stm32h573i_dk/board.h
+++ b/hw/bsp/stm32h5/boards/stm32h573i_dk/board.h
@@ -35,12 +35,12 @@ extern "C" {
// LED
#define LED_PORT GPIOI
#define LED_PIN GPIO_PIN_9
-#define LED_STATE_ON 0
+#define LED_STATE_ON 1
// Button
#define BUTTON_PORT GPIOC
#define BUTTON_PIN GPIO_PIN_13
-#define BUTTON_STATE_ACTIVE 0
+#define BUTTON_STATE_ACTIVE 1
// UART Enable for STLink VCOM
#define UART_DEV USART1
diff --git a/hw/bsp/stm32h5/family.c b/hw/bsp/stm32h5/family.c
index 81c0ef4ce..02500db4e 100644
--- a/hw/bsp/stm32h5/family.c
+++ b/hw/bsp/stm32h5/family.c
@@ -73,10 +73,10 @@ void board_init(void) {
__HAL_RCC_GPIOE_CLK_ENABLE();
#endif
#ifdef __HAL_RCC_GPIOG_CLK_ENABLE
- __HAL_RCC_GPIOE_CLK_ENABLE();
+ __HAL_RCC_GPIOG_CLK_ENABLE();
#endif
#ifdef __HAL_RCC_GPIOI_CLK_ENABLE
- __HAL_RCC_GPIOE_CLK_ENABLE();
+ __HAL_RCC_GPIOI_CLK_ENABLE();
#endif
UART_CLK_EN();