Update UARTs for stm32f4xx discovery boards. Other minor cleanups.

This commit is contained in:
Nathan Conrad
2020-03-28 11:19:50 -04:00
parent 4191363c55
commit 3926b28faa
9 changed files with 71 additions and 14 deletions
+1 -1
View File
@@ -19,8 +19,8 @@ SRC_C += \
$(ST_CMSIS)/Source/Templates/system_stm32f4xx.c \
$(ST_HAL_DRIVER)/Src/stm32f4xx_hal.c \
$(ST_HAL_DRIVER)/Src/stm32f4xx_hal_cortex.c \
$(ST_HAL_DRIVER)/Src/stm32f4xx_hal_uart.c \
$(ST_HAL_DRIVER)/Src/stm32f4xx_hal_rcc.c \
$(ST_HAL_DRIVER)/Src/stm32f4xx_hal_uart.c \
$(ST_HAL_DRIVER)/Src/stm32f4xx_hal_gpio.c
SRC_S += \
+1 -2
View File
@@ -36,7 +36,6 @@
#define BUTTON_PIN GPIO_PIN_0
#define BUTTON_STATE_ACTIVE 1
// Enable PA2 as the debug log UART
// It is not routed to the ST/Link on the Discovery board.
#define UARTx USART2
@@ -114,7 +113,7 @@ void board_init(void)
SystemClock_Config();
all_rcc_clk_enable();
#if CFG_TUSB_OS == OPT_OS_NONE
#if CFG_TUSB_OS == OPT_OS_NONE
// 1ms tick timer
SysTick_Config(SystemCoreClock / 1000);
#elif CFG_TUSB_OS == OPT_OS_FREERTOS
+1 -1
View File
@@ -68,7 +68,7 @@
/* #define HAL_SD_MODULE_ENABLED */
// #define HAL_SPI_MODULE_ENABLED
/* #define HAL_TIM_MODULE_ENABLED */
/* #define HAL_UART_MODULE_ENABLED */
#define HAL_UART_MODULE_ENABLED
/* #define HAL_USART_MODULE_ENABLED */
/* #define HAL_IRDA_MODULE_ENABLED */
/* #define HAL_SMARTCARD_MODULE_ENABLED */