diff options
| author | YixingShen <[email protected]> | 2024-01-26 02:46:53 +0800 |
|---|---|---|
| committer | YixingShen <[email protected]> | 2024-01-26 02:46:53 +0800 |
| commit | 19130440ccd0db8649b2f4e6c7ccb2ee2eaeefac (patch) | |
| tree | 6506095161145db99af7c103e90ac17b6a98fa4e | |
| parent | 611f9d948be47b96520e84773525b9b79d3c7189 (diff) | |
Revert "Merge branch 'master' of https://github.com/YixingShen/tinyusb"
This reverts commit 611f9d948be47b96520e84773525b9b79d3c7189, reversing
changes made to a7de4ac9b7a2dfb1fa44921fb0f41f249c8cdd5e.
| -rw-r--r-- | hw/bsp/stm32f1/family.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/hw/bsp/stm32f1/family.c b/hw/bsp/stm32f1/family.c index 0c1b362ab..e79f9cd78 100644 --- a/hw/bsp/stm32f1/family.c +++ b/hw/bsp/stm32f1/family.c @@ -57,6 +57,9 @@ void board_init(void) { __HAL_RCC_GPIOC_CLK_ENABLE(); __HAL_RCC_GPIOD_CLK_ENABLE(); + // Enable UART Clock + UART_CLK_EN(); + #if CFG_TUSB_OS == OPT_OS_NONE // 1ms tick timer SysTick_Config(SystemCoreClock / 1000); @@ -83,10 +86,7 @@ void board_init(void) { GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_HIGH; HAL_GPIO_Init(BUTTON_PORT, &GPIO_InitStruct); -#ifdef UART_DEV // UART - UART_CLK_EN(); - GPIO_InitStruct.Pin = UART_TX_PIN | UART_RX_PIN; GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; GPIO_InitStruct.Pull = GPIO_PULLUP; @@ -105,7 +105,6 @@ void board_init(void) { .Init.OverSampling = UART_OVERSAMPLING_16 }; HAL_UART_Init(&UartHandle); -#endif // USB Pins // Configure USB DM and DP pins. |
