diff options
| author | HiFiPhile <[email protected]> | 2024-11-10 12:32:22 +0100 |
|---|---|---|
| committer | hathach <[email protected]> | 2025-07-10 12:31:25 +0700 |
| commit | 9f626fe17917dc73ae656ddceb303c14282443f1 (patch) | |
| tree | c601ec46a5e70f62b8c53ab2e3b1a289cafd030b | |
| parent | f918c4a978cc154a0f20c787d68e799382951ddf (diff) | |
Fix F4 BSP without UART_DEV.
| -rw-r--r-- | hw/bsp/stm32f4/family.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/hw/bsp/stm32f4/family.c b/hw/bsp/stm32f4/family.c index 3a1507dbf..260927903 100644 --- a/hw/bsp/stm32f4/family.c +++ b/hw/bsp/stm32f4/family.c @@ -53,6 +53,7 @@ void OTG_HS_IRQHandler(void) { //--------------------------------------------------------------------+ // MACRO TYPEDEF CONSTANT ENUM //--------------------------------------------------------------------+ +#ifdef UART_DEV UART_HandleTypeDef UartHandle = { .Instance = UART_DEV, .Init = { @@ -65,6 +66,7 @@ UART_HandleTypeDef UartHandle = { .OverSampling = UART_OVERSAMPLING_16 } }; +#endif void board_init(void) { board_clock_init(); @@ -233,7 +235,7 @@ int board_uart_write(void const *buf, int len) { HAL_UART_Transmit(&UartHandle, (uint8_t *) (uintptr_t) buf, len, 0xffff); return len; #else - (void) buf; (void) len; (void) UartHandle; + (void) buf; (void) len; return 0; #endif } |
