diff --git a/bsp/stm32/stm32f091-st-nucleo/board/Kconfig b/bsp/stm32/stm32f091-st-nucleo/board/Kconfig index 481026ed92..681580fdce 100644 --- a/bsp/stm32/stm32f091-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f091-st-nucleo/board/Kconfig @@ -9,6 +9,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart2)" + select BSP_USING_UART select BSP_USING_UART2 default y @@ -21,20 +22,52 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL - default n - - config BSP_USING_UART2 - bool "Enable UART2" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y + select RT_USING_SERIAL + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" - select RT_USING_SPI + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + + endif + + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" default n + select RT_USING_SPI + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n + + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n + endif + menuconfig BSP_USING_I2C1 bool "Enable I2C1 BUS (software simulation)" diff --git a/bsp/stm32/stm32f103-atk-nano/board/Kconfig b/bsp/stm32/stm32f103-atk-nano/board/Kconfig index 1c4ae055bb..84ef7224b6 100644 --- a/bsp/stm32/stm32f103-atk-nano/board/Kconfig +++ b/bsp/stm32/stm32f103-atk-nano/board/Kconfig @@ -9,6 +9,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y @@ -19,6 +20,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_SPI_FLASH bool "Enable SPI FLASH (w25q16 spi2)" + select BSP_USING_SPI select BSP_USING_SPI2 select RT_USING_SFUD select RT_SFUD_USING_SFDP @@ -39,6 +41,39 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y + menuconfig BSP_USING_UART + bool "Enable UART" + default y + select RT_USING_SERIAL + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y + + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default n + + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + + config BSP_USING_UART3 + bool "Enable UART3" + default n + + config BSP_UART3_RX_USING_DMA + bool "Enable UART3 RX DMA" + depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA + default n + endif + config BSP_USING_UART1 bool "Enable UART1" select RT_USING_SERIAL @@ -90,20 +125,42 @@ menu "On-chip Peripheral Drivers" default n endif endif + + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" + default n + select RT_USING_SPI + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" - select RT_USING_SPI - default n + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n - config BSP_USING_SPI2 - bool "Enable SPI2 BUS" - select RT_USING_SPI - default n - - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + config BSP_USING_SPI2 + bool "Enable SPI2 BUS" + default n + + config BSP_SPI2_TX_USING_DMA + bool "Enable SPI2 TX DMA" + depends on BSP_USING_SPI2 + default n + + config BSP_SPI2_RX_USING_DMA + bool "Enable SPI2 RX DMA" + depends on BSP_USING_SPI2 + select BSP_SPI2_TX_USING_DMA + default n + endif menuconfig BSP_USING_I2C1 bool "Enable I2C1 BUS (software simulation)" diff --git a/bsp/stm32/stm32f103-atk-nano/project.uvprojx b/bsp/stm32/stm32f103-atk-nano/project.uvprojx index 4d626125a2..af0b59df29 100644 --- a/bsp/stm32/stm32f103-atk-nano/project.uvprojx +++ b/bsp/stm32/stm32f103-atk-nano/project.uvprojx @@ -1,10 +1,7 @@ - 2.1 -
### uVision Project, (C) Keil Software
- rt-thread @@ -19,28 +16,28 @@ Keil.STM32F1xx_DFP.2.2.0 http://www.keil.com/pack/ IRAM(0x20000000,0x5000) IROM(0x08000000,0x20000) CPUTYPE("Cortex-M3") CLOCK(12000000) ELITTLE - - + + UL2CM3(-S0 -C0 -P0 -FD20000000 -FC1000 -FN1 -FF0STM32F10x_128 -FS08000000 -FL020000 -FP0($$Device:STM32F103RB$Flash\STM32F10x_128.FLM)) 0 $$Device:STM32F103RB$Device\Include\stm32f10x.h - - - - - - - - - + + + + + + + + + $$Device:STM32F103RB$SVD\STM32F103xx.svd 0 0 - - - - - + + + + + 0 0 @@ -62,8 +59,8 @@ 0 0 - - + + 0 0 0 @@ -72,8 +69,8 @@ 0 0 - - + + 0 0 0 @@ -83,14 +80,14 @@ 1 0 fromelf --bin !L --output rtthread.bin - + 0 0 0 0 0 - + 0 @@ -104,8 +101,8 @@ 0 0 3 - - + + 1 @@ -114,7 +111,7 @@ DCM.DLL -pCM3 SARMCM3.DLL - + TCM.DLL -pCM3 @@ -139,10 +136,10 @@ 1 BIN\UL2CM3.DLL "" () - - - - + + + + 0 @@ -175,7 +172,7 @@ 0 0 "Cortex-M3" - + 0 0 0 @@ -307,7 +304,7 @@ 0x0 - + 1 @@ -334,9 +331,9 @@ 0 0 - + STM32F103xB, USE_HAL_DRIVER - + applications;.;board;board\CubeMX_Config\Inc;board\ports;..\libraries\HAL_Drivers;..\libraries\HAL_Drivers\config;..\..\..\include;..\..\..\libcpu\arm\cortex-m3;..\..\..\libcpu\arm\common;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\finsh;..\libraries\STM32F1xx_HAL\CMSIS\Device\ST\STM32F1xx\Include;..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Inc;..\libraries\STM32F1xx_HAL\CMSIS\Include @@ -352,10 +349,10 @@ 0 0 - - - - + + + + @@ -367,13 +364,13 @@ 0 0x08000000 0x20000000 - + .\board\linker_scripts\link.sct - - + + --keep *.o(.rti_fn.*) --keep *.o(FSymTab) - - + + @@ -396,26 +393,36 @@ 1 board\board.c + + stm32f1xx_hal_msp.c 1 board\CubeMX_Config\Src\stm32f1xx_hal_msp.c + + startup_stm32f103xb.s 2 ..\libraries\STM32F1xx_HAL\CMSIS\Device\ST\STM32F1xx\Source\Templates\arm\startup_stm32f103xb.s + + drv_gpio.c 1 ..\libraries\HAL_Drivers\drv_gpio.c + + drv_usart.c 1 ..\libraries\HAL_Drivers\drv_usart.c + + drv_common.c 1 @@ -431,76 +438,106 @@ 1 ..\..\..\src\clock.c + + components.c 1 ..\..\..\src\components.c + + cpu.c 1 ..\..\..\src\cpu.c + + device.c 1 ..\..\..\src\device.c + + idle.c 1 ..\..\..\src\idle.c + + ipc.c 1 ..\..\..\src\ipc.c + + irq.c 1 ..\..\..\src\irq.c + + kservice.c 1 ..\..\..\src\kservice.c + + mem.c 1 ..\..\..\src\mem.c + + memheap.c 1 ..\..\..\src\memheap.c + + mempool.c 1 ..\..\..\src\mempool.c + + object.c 1 ..\..\..\src\object.c + + scheduler.c 1 ..\..\..\src\scheduler.c + + signal.c 1 ..\..\..\src\signal.c + + thread.c 1 ..\..\..\src\thread.c + + timer.c 1 @@ -516,21 +553,29 @@ 1 ..\..\..\libcpu\arm\cortex-m3\cpuport.c + + context_rvds.S 2 ..\..\..\libcpu\arm\cortex-m3\context_rvds.S + + backtrace.c 1 ..\..\..\libcpu\arm\common\backtrace.c + + div0.c 1 ..\..\..\libcpu\arm\common\div0.c + + showmem.c 1 @@ -546,41 +591,57 @@ 1 ..\..\..\components\drivers\misc\pin.c + + serial.c 1 ..\..\..\components\drivers\serial\serial.c + + completion.c 1 ..\..\..\components\drivers\src\completion.c + + dataqueue.c 1 ..\..\..\components\drivers\src\dataqueue.c + + pipe.c 1 ..\..\..\components\drivers\src\pipe.c + + ringblk_buf.c 1 ..\..\..\components\drivers\src\ringblk_buf.c + + ringbuffer.c 1 ..\..\..\components\drivers\src\ringbuffer.c + + waitqueue.c 1 ..\..\..\components\drivers\src\waitqueue.c + + workqueue.c 1 @@ -596,26 +657,36 @@ 1 ..\..\..\components\finsh\shell.c + + symbol.c 1 ..\..\..\components\finsh\symbol.c + + cmd.c 1 ..\..\..\components\finsh\cmd.c + + msh.c 1 ..\..\..\components\finsh\msh.c + + msh_cmd.c 1 ..\..\..\components\finsh\msh_cmd.c + + msh_file.c 1 @@ -631,66 +702,92 @@ 1 ..\libraries\STM32F1xx_HAL\CMSIS\Device\ST\STM32F1xx\Source\Templates\system_stm32f1xx.c + + stm32f1xx_hal_dma.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_dma.c + + stm32f1xx_hal_cortex.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_cortex.c + + stm32f1xx_hal_crc.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_crc.c + + stm32f1xx_hal_pwr.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_pwr.c + + stm32f1xx_hal_rcc.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_rcc.c + + stm32f1xx_hal_rcc_ex.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_rcc_ex.c + + stm32f1xx_hal.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal.c + + stm32f1xx_hal_cec.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_cec.c + + stm32f1xx_hal_sram.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_sram.c + + stm32f1xx_hal_gpio.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_gpio.c + + stm32f1xx_hal_gpio_ex.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_gpio_ex.c + + stm32f1xx_hal_uart.c 1 ..\libraries\STM32F1xx_HAL\STM32F1xx_HAL_Driver\Src\stm32f1xx_hal_uart.c + + stm32f1xx_hal_usart.c 1 @@ -701,11 +798,9 @@ - - - - + + + -
diff --git a/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig b/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig index 51ecf43ef3..2795400969 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig +++ b/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig @@ -9,6 +9,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y @@ -19,6 +20,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_SPI_FLASH bool "Enable SPI FLASH (w25q64 spi1)" + select BSP_USING_SPI select BSP_USING_SPI1 select RT_USING_SFUD select RT_SFUD_USING_SFDP @@ -89,43 +91,93 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL - default y + menuconfig BSP_USING_UART + bool "Enable UART" + default y + select RT_USING_SERIAL + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y - config BSP_USING_UART2 - bool "Enable UART2" - select RT_USING_SERIAL - default n + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default n - config BSP_USING_UART3 - bool "Enable UART3" - select RT_USING_SERIAL - default n - + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + + config BSP_USING_UART3 + bool "Enable UART3" + default n + + config BSP_UART3_RX_USING_DMA + bool "Enable UART3 RX DMA" + depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA + default n + endif + config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" + default n select RT_USING_SPI - default n + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n - config BSP_USING_SPI2 - bool "Enable SPI2 BUS" - select RT_USING_SPI - default n + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n - config BSP_USING_SPI3 - bool "Enable SPI3 BUS" - select RT_USING_SPI - default n + config BSP_USING_SPI2 + bool "Enable SPI2 BUS" + default n + + config BSP_SPI2_TX_USING_DMA + bool "Enable SPI2 TX DMA" + depends on BSP_USING_SPI2 + default n + + config BSP_SPI2_RX_USING_DMA + bool "Enable SPI2 RX DMA" + depends on BSP_USING_SPI2 + select BSP_SPI2_TX_USING_DMA + default n + + config BSP_USING_SPI3 + bool "Enable SPI3 BUS" + default n - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + config BSP_SPI3_TX_USING_DMA + bool "Enable SPI3 TX DMA" + depends on BSP_USING_SPI3 + default n + + config BSP_SPI3_RX_USING_DMA + bool "Enable SPI3 RX DMA" + depends on BSP_USING_SPI3 + select BSP_SPI3_TX_USING_DMA + default n + endif menuconfig BSP_USING_I2C1 bool "Enable I2C1 BUS (software simulation)" diff --git a/bsp/stm32/stm32f407-atk-explorer/board/Kconfig b/bsp/stm32/stm32f407-atk-explorer/board/Kconfig index ab47b88e1c..41ce192f9e 100644 --- a/bsp/stm32/stm32f407-atk-explorer/board/Kconfig +++ b/bsp/stm32/stm32f407-atk-explorer/board/Kconfig @@ -9,21 +9,25 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y config BSP_USING_COM2 bool "Enable COM2 (uart2 pin conflict with Ethernet and PWM)" + select BSP_USING_UART select BSP_USING_UART2 default n config BSP_USING_COM3 bool "Enable COM3 (uart3)" + select BSP_USING_UART select BSP_USING_UART3 default n config BSP_USING_SPI_FLASH bool "Enable SPI FLASH (w25q128 spi1)" + select BSP_USING_SPI select BSP_USING_SPI1 select RT_USING_SFUD select RT_SFUD_USING_SFDP @@ -65,15 +69,29 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y - - config BSP_USING_UART3 - bool "Enable UART3" select RT_USING_SERIAL - default n + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y + + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + + config BSP_USING_UART3 + bool "Enable UART3" + default n + + config BSP_UART3_RX_USING_DMA + bool "Enable UART3 RX DMA" + depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA + default n + endif menuconfig BSP_USING_TIM bool "Enable timer" @@ -112,19 +130,41 @@ menu "On-chip Peripheral Drivers" bool "Enable on-chip FLASH" default n - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" - select RT_USING_SPI - default y - - config BSP_USING_SPI2 - bool "Enable SPI2 BUS" - select RT_USING_SPI + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" default n + select RT_USING_SPI + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n + + config BSP_USING_SPI2 + bool "Enable SPI2 BUS" + default n + + config BSP_SPI2_TX_USING_DMA + bool "Enable SPI2 TX DMA" + depends on BSP_USING_SPI2 + default n + + config BSP_SPI2_RX_USING_DMA + bool "Enable SPI2 RX DMA" + depends on BSP_USING_SPI2 + select BSP_SPI2_TX_USING_DMA + default n + endif menuconfig BSP_USING_ADC bool "Enable ADC" diff --git a/bsp/stm32/stm32f407-st-discovery/board/Kconfig b/bsp/stm32/stm32f407-st-discovery/board/Kconfig index 7c0a91960b..1f5bcd321d 100644 --- a/bsp/stm32/stm32f407-st-discovery/board/Kconfig +++ b/bsp/stm32/stm32f407-st-discovery/board/Kconfig @@ -16,23 +16,41 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y + select RT_USING_SERIAL + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y - config BSP_UART_USING_DMA_RX - bool "Enable UART RX DMA support" + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + endif + + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" default n - - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" select RT_USING_SPI - default n - - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n + + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n + endif menuconfig BSP_USING_I2C1 bool "Enable I2C1 BUS (software simulation)" diff --git a/bsp/stm32/stm32f429-armfly-v6/board/Kconfig b/bsp/stm32/stm32f429-armfly-v6/board/Kconfig index 5986331df2..498495e8d9 100644 --- a/bsp/stm32/stm32f429-armfly-v6/board/Kconfig +++ b/bsp/stm32/stm32f429-armfly-v6/board/Kconfig @@ -9,6 +9,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_RS232_TO_USART bool "Enable RS232 TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y @@ -22,6 +23,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_SPI_FLASH bool "Enable SPI FLASH (w25q64 spi3)" + select BSP_USING_SPI select BSP_USING_SPI3 select RT_USING_SFUD select RT_SFUD_USING_SFDP @@ -60,27 +62,45 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y + select RT_USING_SERIAL + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y - config BSP_UART_USING_DMA_RX - bool "Enable UART RX DMA support" - default n + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + endif config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - config BSP_USING_SPI3 - bool "Enable SPI3 BUS" - select RT_USING_SPI - default n - - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" default n + select RT_USING_SPI + if BSP_USING_SPI + config BSP_USING_SPI3 + bool "Enable SPI3 BUS" + default n + + config BSP_SPI3_TX_USING_DMA + bool "Enable SPI3 TX DMA" + depends on BSP_USING_SPI3 + default n + + config BSP_SPI3_RX_USING_DMA + bool "Enable SPI3 RX DMA" + depends on BSP_USING_SPI3 + select BSP_SPI3_TX_USING_DMA + default n + endif menuconfig BSP_USING_I2C1 bool "Enable I2C1 BUS (software simulation)" diff --git a/bsp/stm32/stm32f429-atk-apollo/board/Kconfig b/bsp/stm32/stm32f429-atk-apollo/board/Kconfig index 8355099335..c8529ead4f 100644 --- a/bsp/stm32/stm32f429-atk-apollo/board/Kconfig +++ b/bsp/stm32/stm32f429-atk-apollo/board/Kconfig @@ -9,11 +9,13 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y config BSP_USING_COM2 bool "Enable COM2 (uart2 pin conflict with Ethernet and PWM)" + select BSP_USING_UART select BSP_USING_UART2 default n @@ -28,6 +30,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_SPI_FLASH bool "Enable SPI FLASH (w25q256 spi5)" + select BSP_USING_SPI select BSP_USING_SPI5 select RT_USING_SFUD select RT_SFUD_USING_SFDP @@ -66,43 +69,93 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y - - config BSP_USING_UART2 - bool "Enable UART2" select RT_USING_SERIAL - default n + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y - config BSP_USING_UART3 - bool "Enable UART3" - select RT_USING_SERIAL - default n + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + + config BSP_USING_UART3 + bool "Enable UART3" + default n + + config BSP_UART3_RX_USING_DMA + bool "Enable UART3 RX DMA" + depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA + default n + endif config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" + default n select RT_USING_SPI - default n + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n - config BSP_USING_SPI2 - bool "Enable SPI2 BUS" - select RT_USING_SPI - default n + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n - config BSP_USING_SPI5 - bool "Enable SPI5 BUS" - select RT_USING_SPI - default n + config BSP_USING_SPI2 + bool "Enable SPI2 BUS" + default n + + config BSP_SPI2_TX_USING_DMA + bool "Enable SPI2 TX DMA" + depends on BSP_USING_SPI2 + default n + + config BSP_SPI2_RX_USING_DMA + bool "Enable SPI2 RX DMA" + depends on BSP_USING_SPI2 + select BSP_SPI2_TX_USING_DMA + default n + + config BSP_USING_SPI5 + bool "Enable SPI5 BUS" + default n - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + config BSP_SPI5_TX_USING_DMA + bool "Enable SPI5 TX DMA" + depends on BSP_USING_SPI5 + default n + + config BSP_SPI5_RX_USING_DMA + bool "Enable SPI5 RX DMA" + depends on BSP_USING_SPI5 + select BSP_SPI5_TX_USING_DMA + default n + endif menuconfig BSP_USING_I2C1 bool "Enable I2C1 BUS (software simulation)" diff --git a/bsp/stm32/stm32f429-fire-challenger/board/Kconfig b/bsp/stm32/stm32f429-fire-challenger/board/Kconfig index 10d86df091..2c8d3f10cf 100644 --- a/bsp/stm32/stm32f429-fire-challenger/board/Kconfig +++ b/bsp/stm32/stm32f429-fire-challenger/board/Kconfig @@ -9,11 +9,13 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y config BSP_USING_RS232 bool "Enable RS232" + select BSP_USING_UART select BSP_USING_UART2 default n @@ -22,7 +24,8 @@ menu "Onboard Peripheral Drivers" default n config BSP_USING_SPI_FLASH - bool "Enable SPI FLASH (W25Q128 spi5)" + bool "Enable SPI FLASH (w25q256 spi5)" + select BSP_USING_SPI select BSP_USING_SPI5 select RT_USING_SFUD select RT_SFUD_USING_SFDP @@ -76,28 +79,55 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y - - config BSP_USING_UART2 - bool "Enable UART2" select RT_USING_SERIAL - default n + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y + + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + + endif config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - config BSP_USING_SPI5 - bool "Enable SPI5 BUS" + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" + default n select RT_USING_SPI - default n + if BSP_USING_SPI + config BSP_USING_SPI5 + bool "Enable SPI5 BUS" + default n - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + config BSP_SPI5_TX_USING_DMA + bool "Enable SPI5 TX DMA" + depends on BSP_USING_SPI5 + default n + + config BSP_SPI5_RX_USING_DMA + bool "Enable SPI5 RX DMA" + depends on BSP_USING_SPI5 + select BSP_SPI5_TX_USING_DMA + default n + endif menuconfig BSP_USING_TIM bool "Enable timer" diff --git a/bsp/stm32/stm32f767-atk-apollo/board/Kconfig b/bsp/stm32/stm32f767-atk-apollo/board/Kconfig index d8a1575d27..e87dbd896a 100644 --- a/bsp/stm32/stm32f767-atk-apollo/board/Kconfig +++ b/bsp/stm32/stm32f767-atk-apollo/board/Kconfig @@ -9,11 +9,13 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y config BSP_USING_RS232 bool "Enable RS232 (uart2 pin conflict with Ethernet)" + select BSP_USING_UART select BSP_USING_UART2 default n @@ -67,28 +69,71 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y - - config BSP_USING_UART2 - bool "Enable UART2" select RT_USING_SERIAL - default n + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y + + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + + endif config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - config BSP_USING_SPI2 - bool "Enable SPI2 BUS" +menuconfig BSP_USING_SPI + bool "Enable SPI BUS" + default n select RT_USING_SPI - default n + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n + + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n + + config BSP_USING_SPI2 + bool "Enable SPI2 BUS" + default n + + config BSP_SPI2_TX_USING_DMA + bool "Enable SPI2 TX DMA" + depends on BSP_USING_SPI2 + default n + + config BSP_SPI2_RX_USING_DMA + bool "Enable SPI2 RX DMA" + depends on BSP_USING_SPI2 + select BSP_SPI2_TX_USING_DMA + default n + endif - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n config BSP_USING_QSPI bool "Enable QSPI BUS" diff --git a/bsp/stm32/stm32f767-fire-challenger/board/Kconfig b/bsp/stm32/stm32f767-fire-challenger/board/Kconfig index 8945170ec8..2423430d38 100644 --- a/bsp/stm32/stm32f767-fire-challenger/board/Kconfig +++ b/bsp/stm32/stm32f767-fire-challenger/board/Kconfig @@ -9,11 +9,13 @@ menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART bool "Enable USB TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y config BSP_USING_RS232 bool "Enable RS232 (uart2 pin conflict with Ethernet)" + select BSP_USING_UART select BSP_USING_UART2 default n @@ -43,43 +45,93 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y - - config BSP_USING_UART2 - bool "Enable UART2" select RT_USING_SERIAL - default n + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y - config BSP_USING_UART3 - bool "Enable UART3" - select RT_USING_SERIAL - default n + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + + config BSP_USING_UART3 + bool "Enable UART3" + default n + + config BSP_UART3_RX_USING_DMA + bool "Enable UART3 RX DMA" + depends on BSP_USING_UART3 && RT_SERIsAL_USING_DMA + default n + endif config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" +menuconfig BSP_USING_SPI + bool "Enable SPI BUS" + default n select RT_USING_SPI - default n + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n - config BSP_USING_SPI2 - bool "Enable SPI2 BUS" - select RT_USING_SPI - default n + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n - config BSP_USING_SPI5 - bool "Enable SPI5 BUS" - select RT_USING_SPI - default n + config BSP_USING_SPI2 + bool "Enable SPI2 BUS" + default n + + config BSP_SPI2_TX_USING_DMA + bool "Enable SPI2 TX DMA" + depends on BSP_USING_SPI2 + default n + + config BSP_SPI2_RX_USING_DMA + bool "Enable SPI2 RX DMA" + depends on BSP_USING_SPI2 + select BSP_SPI2_TX_USING_DMA + default n - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + config BSP_USING_SPI5 + bool "Enable SPI5 BUS" + default n + + config BSP_SPI5_TX_USING_DMA + bool "Enable SPI5 TX DMA" + depends on BSP_USING_SPI5 + default n + + config BSP_SPI5_RX_USING_DMA + bool "Enable SPI5 RX DMA" + depends on BSP_USING_SPI5 + select BSP_SPI5_TX_USING_DMA + default n + endif config BSP_USING_QSPI bool "Enable QSPI BUS" diff --git a/bsp/stm32/stm32l475-atk-pandora/board/Kconfig b/bsp/stm32/stm32l475-atk-pandora/board/Kconfig index 2efacdb00e..538cf8d472 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/Kconfig +++ b/bsp/stm32/stm32l475-atk-pandora/board/Kconfig @@ -9,6 +9,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART bool "Enable STLINK TO USART (uart1)" + select BSP_USING_UART select BSP_USING_UART1 default y @@ -21,6 +22,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_SDCARD bool "Enable SDCARD (spi1)" + select BSP_USING_SPI select BSP_USING_SPI1 select BSP_SPI_USING_DMA select RT_USING_SPI_MSD @@ -37,33 +39,69 @@ menu "On-chip Peripheral Drivers" select RT_USING_PIN default y - config BSP_USING_UART1 - bool "Enable UART1" - select RT_USING_SERIAL + menuconfig BSP_USING_UART + bool "Enable UART" default y - - config BSP_USING_UART2 - bool "Enable UART2" select RT_USING_SERIAL - default n - + if BSP_USING_UART + config BSP_USING_UART1 + bool "Enable UART1" + default y + + config BSP_UART1_RX_USING_DMA + bool "Enable UART1 RX DMA" + depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA + default y + + config BSP_USING_UART2 + bool "Enable UART2" + default n + + config BSP_UART2_RX_USING_DMA + bool "Enable UART2 RX DMA" + depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA + default n + endif + config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - config BSP_USING_SPI1 - bool "Enable SPI1 BUS" + menuconfig BSP_USING_SPI + bool "Enable SPI BUS" + default n select RT_USING_SPI - default n + if BSP_USING_SPI + config BSP_USING_SPI1 + bool "Enable SPI1 BUS" + default n - config BSP_USING_SPI2 - bool "Enable SPI2 BUS" - select RT_USING_SPI - default n + config BSP_SPI1_TX_USING_DMA + bool "Enable SPI1 TX DMA" + depends on BSP_USING_SPI1 + default n + + config BSP_SPI1_RX_USING_DMA + bool "Enable SPI1 RX DMA" + depends on BSP_USING_SPI1 + select BSP_SPI1_TX_USING_DMA + default n - config BSP_SPI_USING_DMA - bool "Enable SPI DMA support" - default n + config BSP_USING_SPI2 + bool "Enable SPI2 BUS" + default n + + config BSP_SPI2_TX_USING_DMA + bool "Enable SPI2 TX DMA" + depends on BSP_USING_SPI2 + default n + + config BSP_SPI2_RX_USING_DMA + bool "Enable SPI2 RX DMA" + depends on BSP_USING_SPI2 + select BSP_SPI2_TX_USING_DMA + default n + endif config BSP_USING_QSPI bool "Enable QSPI BUS"