diff --git a/bsp/stm32/libraries/templates/stm32f0xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32f0xx/board/Kconfig index 6a012363e48..65d07ed9d4f 100644 --- a/bsp/stm32/libraries/templates/stm32f0xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32f0xx/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32f10x/board/Kconfig b/bsp/stm32/libraries/templates/stm32f10x/board/Kconfig index 4adac924990..830c618d39f 100644 --- a/bsp/stm32/libraries/templates/stm32f10x/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32f10x/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32f2xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32f2xx/board/Kconfig index 62a95b10642..82256ff00b1 100644 --- a/bsp/stm32/libraries/templates/stm32f2xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32f2xx/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32f4xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32f4xx/board/Kconfig index 6b1faba6b09..ac42628c8a4 100644 --- a/bsp/stm32/libraries/templates/stm32f4xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32f4xx/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32f7xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32f7xx/board/Kconfig index 4c6c6f7e554..9c9e78fa725 100644 --- a/bsp/stm32/libraries/templates/stm32f7xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32f7xx/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32h7xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32h7xx/board/Kconfig index 059987a8e12..10133353a3c 100644 --- a/bsp/stm32/libraries/templates/stm32h7xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32h7xx/board/Kconfig @@ -29,7 +29,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig index 78831f21065..007b7126937 100644 --- a/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig @@ -206,7 +206,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32l4xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32l4xx/board/Kconfig index a02e7d7458a..6de96ab49ed 100644 --- a/bsp/stm32/libraries/templates/stm32l4xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32l4xx/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32l5xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32l5xx/board/Kconfig index 85a3fe5dd35..4bcfb716af5 100644 --- a/bsp/stm32/libraries/templates/stm32l5xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32l5xx/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32mp1xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32mp1xx/board/Kconfig index 28a1826d439..fae6dd32ea8 100644 --- a/bsp/stm32/libraries/templates/stm32mp1xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32mp1xx/board/Kconfig @@ -39,7 +39,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/libraries/templates/stm32wbxx/board/Kconfig b/bsp/stm32/libraries/templates/stm32wbxx/board/Kconfig index 0dc981d28c5..dde7b3fca31 100644 --- a/bsp/stm32/libraries/templates/stm32wbxx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32wbxx/board/Kconfig @@ -157,7 +157,7 @@ menu "On-chip Peripheral Drivers" endchoice endif - source "../libraries/HAL_Drivers/drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f072-st-nucleo/Kconfig b/bsp/stm32/stm32f072-st-nucleo/Kconfig index 7a400db91f4..d778e1c8055 100644 --- a/bsp/stm32/stm32f072-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f072-st-nucleo/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F072RB + bool + select SOC_SERIES_STM32F0 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f072-st-nucleo/applications/main.c b/bsp/stm32/stm32f072-st-nucleo/applications/main.c index 041c8db15b9..22cfb736ce9 100644 --- a/bsp/stm32/stm32f072-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f072-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 zylx first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED2 (user LED) pin: PA5 */ #define LED2_PIN GET_PIN(A, 5) diff --git a/bsp/stm32/stm32f072-st-nucleo/board/Kconfig b/bsp/stm32/stm32f072-st-nucleo/board/Kconfig index 647979d24ba..54afe7d4c3e 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f072-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F072RB - bool - select SOC_SERIES_STM32F0 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART bool "Enable STLINK TO USART (uart2)" @@ -166,7 +159,7 @@ menu "On-chip Peripheral Drivers" endif endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f072-st-nucleo/board/board.c b/bsp/stm32/stm32f072-st-nucleo/board/board.c index 5f06e3253d1..f5801258a55 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f072-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-12-21 zylx first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f072-st-nucleo/board/board.h b/bsp/stm32/stm32f072-st-nucleo/board/board.h index 4dc58c3c927..834459c1028 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f072-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f091-st-nucleo/Kconfig b/bsp/stm32/stm32f091-st-nucleo/Kconfig index 7a400db91f4..41aaf93bd5c 100644 --- a/bsp/stm32/stm32f091-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f091-st-nucleo/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F091RC + bool + select SOC_SERIES_STM32F0 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f091-st-nucleo/applications/main.c b/bsp/stm32/stm32f091-st-nucleo/applications/main.c index 61981d49b02..596eb77e8ef 100644 --- a/bsp/stm32/stm32f091-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f091-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 zylx first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED2 pin: PA5 */ #define LED2_PIN GET_PIN(A, 5) diff --git a/bsp/stm32/stm32f091-st-nucleo/board/Kconfig b/bsp/stm32/stm32f091-st-nucleo/board/Kconfig index 804cc2f2584..ac2c40d16ad 100644 --- a/bsp/stm32/stm32f091-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f091-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F091RC - bool - select SOC_SERIES_STM32F0 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -157,7 +150,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f091-st-nucleo/board/board.c b/bsp/stm32/stm32f091-st-nucleo/board/board.c index ec74fe9af02..45ddb951850 100644 --- a/bsp/stm32/stm32f091-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f091-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-12-21 zylx first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f091-st-nucleo/board/board.h b/bsp/stm32/stm32f091-st-nucleo/board/board.h index efd152dc0d3..6f5b3429084 100644 --- a/bsp/stm32/stm32f091-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f091-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-100ask-mini/Kconfig b/bsp/stm32/stm32f103-100ask-mini/Kconfig index 7a400db91f4..4199912f98d 100644 --- a/bsp/stm32/stm32f103-100ask-mini/Kconfig +++ b/bsp/stm32/stm32f103-100ask-mini/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103C8 + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-100ask-mini/applications/main.c b/bsp/stm32/stm32f103-100ask-mini/applications/main.c index 666fafcb6cf..259581ae40d 100644 --- a/bsp/stm32/stm32f103-100ask-mini/applications/main.c +++ b/bsp/stm32/stm32f103-100ask-mini/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2019-03-08 obito0 first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PA1 */ #define LED0_PIN GET_PIN(A, 1) diff --git a/bsp/stm32/stm32f103-100ask-mini/board/Kconfig b/bsp/stm32/stm32f103-100ask-mini/board/Kconfig index ee8a6172c29..875265bdf95 100644 --- a/bsp/stm32/stm32f103-100ask-mini/board/Kconfig +++ b/bsp/stm32/stm32f103-100ask-mini/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103C8 - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -79,7 +72,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-100ask-mini/board/board.c b/bsp/stm32/stm32f103-100ask-mini/board/board.c index 22f1cc14f7b..12c86d81c09 100644 --- a/bsp/stm32/stm32f103-100ask-mini/board/board.c +++ b/bsp/stm32/stm32f103-100ask-mini/board/board.c @@ -8,7 +8,8 @@ * 2019-03-08 obito0 first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-100ask-mini/board/board.h b/bsp/stm32/stm32f103-100ask-mini/board/board.h index 6c852d96092..259a1cdbaee 100644 --- a/bsp/stm32/stm32f103-100ask-mini/board/board.h +++ b/bsp/stm32/stm32f103-100ask-mini/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-100ask-pro/Kconfig b/bsp/stm32/stm32f103-100ask-pro/Kconfig index 7a400db91f4..ed350cbe678 100644 --- a/bsp/stm32/stm32f103-100ask-pro/Kconfig +++ b/bsp/stm32/stm32f103-100ask-pro/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103ZE + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-100ask-pro/applications/main.c b/bsp/stm32/stm32f103-100ask-pro/applications/main.c index 8e9473cb6ee..849f73d74d1 100644 --- a/bsp/stm32/stm32f103-100ask-pro/applications/main.c +++ b/bsp/stm32/stm32f103-100ask-pro/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2019-03-08 obito0 first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PA1 */ #define LED0_PIN GET_PIN(B, 5) diff --git a/bsp/stm32/stm32f103-100ask-pro/board/Kconfig b/bsp/stm32/stm32f103-100ask-pro/board/Kconfig index e7a16e428ea..b6566158e5d 100644 --- a/bsp/stm32/stm32f103-100ask-pro/board/Kconfig +++ b/bsp/stm32/stm32f103-100ask-pro/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103ZE - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -208,7 +201,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_CAN default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-100ask-pro/board/board.c b/bsp/stm32/stm32f103-100ask-pro/board/board.c index 22f1cc14f7b..12c86d81c09 100644 --- a/bsp/stm32/stm32f103-100ask-pro/board/board.c +++ b/bsp/stm32/stm32f103-100ask-pro/board/board.c @@ -8,7 +8,8 @@ * 2019-03-08 obito0 first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-100ask-pro/board/board.h b/bsp/stm32/stm32f103-100ask-pro/board/board.h index 023339a1772..e63e4c96d94 100644 --- a/bsp/stm32/stm32f103-100ask-pro/board/board.h +++ b/bsp/stm32/stm32f103-100ask-pro/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-atk-nano/Kconfig b/bsp/stm32/stm32f103-atk-nano/Kconfig index 7a400db91f4..3b4560cdca8 100644 --- a/bsp/stm32/stm32f103-atk-nano/Kconfig +++ b/bsp/stm32/stm32f103-atk-nano/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103RB + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-atk-nano/applications/main.c b/bsp/stm32/stm32f103-atk-nano/applications/main.c index 8569ce27bd5..f08e254302f 100644 --- a/bsp/stm32/stm32f103-atk-nano/applications/main.c +++ b/bsp/stm32/stm32f103-atk-nano/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-27 balanceTWK first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PC0 */ #define LED0_PIN GET_PIN(C, 0) diff --git a/bsp/stm32/stm32f103-atk-nano/board/Kconfig b/bsp/stm32/stm32f103-atk-nano/board/Kconfig index 0211a466866..98d2e21cb7a 100644 --- a/bsp/stm32/stm32f103-atk-nano/board/Kconfig +++ b/bsp/stm32/stm32f103-atk-nano/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103RB - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -202,7 +195,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-atk-nano/board/board.c b/bsp/stm32/stm32f103-atk-nano/board/board.c index de585efe325..26c98903604 100644 --- a/bsp/stm32/stm32f103-atk-nano/board/board.c +++ b/bsp/stm32/stm32f103-atk-nano/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 balanceTWK first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-atk-nano/board/board.h b/bsp/stm32/stm32f103-atk-nano/board/board.h index 05d7bdaf2d0..35fb86ea509 100644 --- a/bsp/stm32/stm32f103-atk-nano/board/board.h +++ b/bsp/stm32/stm32f103-atk-nano/board/board.h @@ -12,8 +12,6 @@ #define __BOARD_H__ #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-atk-warshipv3/Kconfig b/bsp/stm32/stm32f103-atk-warshipv3/Kconfig index 7a400db91f4..ed350cbe678 100644 --- a/bsp/stm32/stm32f103-atk-warshipv3/Kconfig +++ b/bsp/stm32/stm32f103-atk-warshipv3/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103ZE + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-atk-warshipv3/applications/main.c b/bsp/stm32/stm32f103-atk-warshipv3/applications/main.c index 8de9bd81e94..f58052fbdae 100644 --- a/bsp/stm32/stm32f103-atk-warshipv3/applications/main.c +++ b/bsp/stm32/stm32f103-atk-warshipv3/applications/main.c @@ -5,12 +5,16 @@ * * Change Logs: * Date Author Notes - * 2019-03-08 obito0 first version + * 2019-03-08 obito0 first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PB5 */ #define LED0_PIN GET_PIN(B, 5) diff --git a/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig b/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig index 9d3e81b729b..a2a5f6f20c3 100644 --- a/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig +++ b/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103ZE - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -242,7 +235,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-atk-warshipv3/board/board.c b/bsp/stm32/stm32f103-atk-warshipv3/board/board.c index 2dc4c9cabf2..cb4f9d3c349 100644 --- a/bsp/stm32/stm32f103-atk-warshipv3/board/board.c +++ b/bsp/stm32/stm32f103-atk-warshipv3/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-atk-warshipv3/board/board.h b/bsp/stm32/stm32f103-atk-warshipv3/board/board.h index 023339a1772..e63e4c96d94 100644 --- a/bsp/stm32/stm32f103-atk-warshipv3/board/board.h +++ b/bsp/stm32/stm32f103-atk-warshipv3/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-blue-pill/Kconfig b/bsp/stm32/stm32f103-blue-pill/Kconfig index 5b7fab59c39..29d94cb329c 100644 --- a/bsp/stm32/stm32f103-blue-pill/Kconfig +++ b/bsp/stm32/stm32f103-blue-pill/Kconfig @@ -24,8 +24,8 @@ config SOC_STM32F103C8 source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" +source "../libraries/Kconfig" if !RT_USING_NANO -source "../libraries/Kconfig" source "board/Kconfig" endif diff --git a/bsp/stm32/stm32f103-blue-pill/applications/main.c b/bsp/stm32/stm32f103-blue-pill/applications/main.c index 9f4d8cbd957..13b172c8301 100644 --- a/bsp/stm32/stm32f103-blue-pill/applications/main.c +++ b/bsp/stm32/stm32f103-blue-pill/applications/main.c @@ -6,13 +6,16 @@ * Change Logs: * Date Author Notes * 2019-03-08 obito0 first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ -#ifndef RT_USING_NANO /* defined the LED0 pin: PC13 */ #define LED0_PIN GET_PIN(C, 13) @@ -29,12 +32,3 @@ int main(void) rt_thread_mdelay(500); } } -#else -int main(void) -{ - while (1) - { - rt_thread_mdelay(500); - } -} -#endif diff --git a/bsp/stm32/stm32f103-blue-pill/board/Kconfig b/bsp/stm32/stm32f103-blue-pill/board/Kconfig index ebb05969e9a..c5c82c8ef06 100644 --- a/bsp/stm32/stm32f103-blue-pill/board/Kconfig +++ b/bsp/stm32/stm32f103-blue-pill/board/Kconfig @@ -188,7 +188,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_USB_DEVICE default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-blue-pill/board/board.c b/bsp/stm32/stm32f103-blue-pill/board/board.c index 53ddd078b6f..12c86d81c09 100644 --- a/bsp/stm32/stm32f103-blue-pill/board/board.c +++ b/bsp/stm32/stm32f103-blue-pill/board/board.c @@ -8,7 +8,8 @@ * 2019-03-08 obito0 first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { @@ -51,10 +52,3 @@ void SystemClock_Config(void) Error_Handler(); } } - -#ifdef RT_USING_NANO -void rt_hw_board_init(void) -{ - -} -#endif diff --git a/bsp/stm32/stm32f103-blue-pill/board/board.h b/bsp/stm32/stm32f103-blue-pill/board/board.h index 04f89988a72..35fb86ea509 100644 --- a/bsp/stm32/stm32f103-blue-pill/board/board.h +++ b/bsp/stm32/stm32f103-blue-pill/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include -#include #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-dofly-M3S/Kconfig b/bsp/stm32/stm32f103-dofly-M3S/Kconfig index 7a400db91f4..ed350cbe678 100644 --- a/bsp/stm32/stm32f103-dofly-M3S/Kconfig +++ b/bsp/stm32/stm32f103-dofly-M3S/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103ZE + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-dofly-M3S/applications/main.c b/bsp/stm32/stm32f103-dofly-M3S/applications/main.c index 31013740629..8a6b46cc394 100644 --- a/bsp/stm32/stm32f103-dofly-M3S/applications/main.c +++ b/bsp/stm32/stm32f103-dofly-M3S/applications/main.c @@ -5,13 +5,16 @@ * * Change Logs: * Date Author Notes - * 2018-11-06 SummerGift first version - * 2019-04-09 WillianChan add stm32f103-dofly-M3S BSP + * 2019-04-09 WillianChan first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PE5 */ #define LED0_PIN GET_PIN(E, 5) diff --git a/bsp/stm32/stm32f103-dofly-M3S/board/Kconfig b/bsp/stm32/stm32f103-dofly-M3S/board/Kconfig index 87315ee04e0..e52ce5e5979 100644 --- a/bsp/stm32/stm32f103-dofly-M3S/board/Kconfig +++ b/bsp/stm32/stm32f103-dofly-M3S/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103ZE - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_SDIO_SDCARD @@ -136,7 +129,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_SDIO select RT_USING_DFS default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-dofly-M3S/board/board.c b/bsp/stm32/stm32f103-dofly-M3S/board/board.c index d32a5096b61..2ec07d94593 100644 --- a/bsp/stm32/stm32f103-dofly-M3S/board/board.c +++ b/bsp/stm32/stm32f103-dofly-M3S/board/board.c @@ -9,7 +9,8 @@ * 2019-04-09 WillianChan add stm32f103-dofly-M3S BSP */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-dofly-M3S/board/board.h b/bsp/stm32/stm32f103-dofly-M3S/board/board.h index 8403f451d47..816d8875c77 100644 --- a/bsp/stm32/stm32f103-dofly-M3S/board/board.h +++ b/bsp/stm32/stm32f103-dofly-M3S/board/board.h @@ -12,10 +12,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-dofly-lyc8/Kconfig b/bsp/stm32/stm32f103-dofly-lyc8/Kconfig index 7a400db91f4..4199912f98d 100644 --- a/bsp/stm32/stm32f103-dofly-lyc8/Kconfig +++ b/bsp/stm32/stm32f103-dofly-lyc8/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103C8 + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-dofly-lyc8/applications/main.c b/bsp/stm32/stm32f103-dofly-lyc8/applications/main.c index ce702bb417f..b53fdcb2b45 100644 --- a/bsp/stm32/stm32f103-dofly-lyc8/applications/main.c +++ b/bsp/stm32/stm32f103-dofly-lyc8/applications/main.c @@ -6,12 +6,16 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include -#include "drv_gpio.h" +#endif /* RT_USING_NANO */ + /* defined the LED0 pin: PB8 */ #define LED0_PIN GET_PIN(B, 8) diff --git a/bsp/stm32/stm32f103-dofly-lyc8/board/Kconfig b/bsp/stm32/stm32f103-dofly-lyc8/board/Kconfig index c7657228fa4..02063a9a7f2 100644 --- a/bsp/stm32/stm32f103-dofly-lyc8/board/Kconfig +++ b/bsp/stm32/stm32f103-dofly-lyc8/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103C8 - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -32,7 +25,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-dofly-lyc8/board/board.c b/bsp/stm32/stm32f103-dofly-lyc8/board/board.c index 84934394091..dc042d25a25 100644 --- a/bsp/stm32/stm32f103-dofly-lyc8/board/board.c +++ b/bsp/stm32/stm32f103-dofly-lyc8/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-dofly-lyc8/board/board.h b/bsp/stm32/stm32f103-dofly-lyc8/board/board.h index 3d813a0af00..2d2e9b5ec21 100644 --- a/bsp/stm32/stm32f103-dofly-lyc8/board/board.h +++ b/bsp/stm32/stm32f103-dofly-lyc8/board/board.h @@ -11,9 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" #define STM32_FLASH_START_ADRESS ((uint32_t)0x08000000) #define STM32_FLASH_SIZE (64 * 1024) diff --git a/bsp/stm32/stm32f103-fire-arbitrary/Kconfig b/bsp/stm32/stm32f103-fire-arbitrary/Kconfig index 7a400db91f4..ed350cbe678 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/Kconfig +++ b/bsp/stm32/stm32f103-fire-arbitrary/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103ZE + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-fire-arbitrary/applications/main.c b/bsp/stm32/stm32f103-fire-arbitrary/applications/main.c index e3078f4e826..f927eb72a54 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/applications/main.c +++ b/bsp/stm32/stm32f103-fire-arbitrary/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-5 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PF7 */ #define LED0_PIN GET_PIN(F, 7) diff --git a/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig b/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig index 1da381d3f4c..15722983d5d 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig +++ b/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103ZE - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -310,7 +303,7 @@ menu "On-chip Peripheral Drivers" int "USB PULL UP STATUS" default 0 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-fire-arbitrary/board/board.c b/bsp/stm32/stm32f103-fire-arbitrary/board/board.c index abbc74be305..f43ee1d8150 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/board/board.c +++ b/bsp/stm32/stm32f103-fire-arbitrary/board/board.c @@ -8,8 +8,8 @@ * 2018-11-06 balanceTWK first version */ -#include -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-fire-arbitrary/board/board.h b/bsp/stm32/stm32f103-fire-arbitrary/board/board.h index 3cc20b82e4b..ffa5bfa5d66 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/board/board.h +++ b/bsp/stm32/stm32f103-fire-arbitrary/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-gizwits-gokitv21/Kconfig b/bsp/stm32/stm32f103-gizwits-gokitv21/Kconfig index 7a400db91f4..4199912f98d 100644 --- a/bsp/stm32/stm32f103-gizwits-gokitv21/Kconfig +++ b/bsp/stm32/stm32f103-gizwits-gokitv21/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103C8 + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-gizwits-gokitv21/applications/main.c b/bsp/stm32/stm32f103-gizwits-gokitv21/applications/main.c index a2ffe21b453..e6fd461504a 100644 --- a/bsp/stm32/stm32f103-gizwits-gokitv21/applications/main.c +++ b/bsp/stm32/stm32f103-gizwits-gokitv21/applications/main.c @@ -5,12 +5,15 @@ * * Change Logs: * Date Author Notes - * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED4 pin: PB1 */ #define LED4_PIN GET_PIN(B, 1) diff --git a/bsp/stm32/stm32f103-gizwits-gokitv21/board/Kconfig b/bsp/stm32/stm32f103-gizwits-gokitv21/board/Kconfig index 7e159d6fb13..c9fe11cdaf9 100644 --- a/bsp/stm32/stm32f103-gizwits-gokitv21/board/Kconfig +++ b/bsp/stm32/stm32f103-gizwits-gokitv21/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103C8 - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -78,7 +71,7 @@ menu "On-chip Peripheral Drivers" range 1 216 default 16 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.c b/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.c index 55faf0d89fe..b0b85dcfc87 100644 --- a/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.c +++ b/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include /** * @brief System Clock Configuration diff --git a/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h b/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h index 6c852d96092..259a1cdbaee 100644 --- a/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h +++ b/bsp/stm32/stm32f103-gizwits-gokitv21/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-hw100k-ibox/Kconfig b/bsp/stm32/stm32f103-hw100k-ibox/Kconfig index 7a400db91f4..ed350cbe678 100644 --- a/bsp/stm32/stm32f103-hw100k-ibox/Kconfig +++ b/bsp/stm32/stm32f103-hw100k-ibox/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103ZE + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-hw100k-ibox/applications/main.c b/bsp/stm32/stm32f103-hw100k-ibox/applications/main.c index 5ba5873b52f..125bca3f7c9 100644 --- a/bsp/stm32/stm32f103-hw100k-ibox/applications/main.c +++ b/bsp/stm32/stm32f103-hw100k-ibox/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PE9 */ #define LED0_PIN GET_PIN(E, 9) diff --git a/bsp/stm32/stm32f103-hw100k-ibox/board/Kconfig b/bsp/stm32/stm32f103-hw100k-ibox/board/Kconfig index 7c7cce397cf..caef7e89256 100644 --- a/bsp/stm32/stm32f103-hw100k-ibox/board/Kconfig +++ b/bsp/stm32/stm32f103-hw100k-ibox/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103ZE - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_RS485_OR_RS232 bool "Enable RS485/RS232 (uart4 be shared)" @@ -216,7 +209,7 @@ menu "On-chip Peripheral Drivers" bool "Enable Watchdog Timer" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-hw100k-ibox/board/board.c b/bsp/stm32/stm32f103-hw100k-ibox/board/board.c index 779d731980f..ef0e9ac8d0d 100644 --- a/bsp/stm32/stm32f103-hw100k-ibox/board/board.c +++ b/bsp/stm32/stm32f103-hw100k-ibox/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-hw100k-ibox/board/board.h b/bsp/stm32/stm32f103-hw100k-ibox/board/board.h index 3dfff3bdb0c..e25394bb322 100644 --- a/bsp/stm32/stm32f103-hw100k-ibox/board/board.h +++ b/bsp/stm32/stm32f103-hw100k-ibox/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-onenet-nbiot/Kconfig b/bsp/stm32/stm32f103-onenet-nbiot/Kconfig index 7a400db91f4..3b4560cdca8 100644 --- a/bsp/stm32/stm32f103-onenet-nbiot/Kconfig +++ b/bsp/stm32/stm32f103-onenet-nbiot/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103RB + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-onenet-nbiot/applications/main.c b/bsp/stm32/stm32f103-onenet-nbiot/applications/main.c index 8569ce27bd5..f08e254302f 100644 --- a/bsp/stm32/stm32f103-onenet-nbiot/applications/main.c +++ b/bsp/stm32/stm32f103-onenet-nbiot/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-27 balanceTWK first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PC0 */ #define LED0_PIN GET_PIN(C, 0) diff --git a/bsp/stm32/stm32f103-onenet-nbiot/board/Kconfig b/bsp/stm32/stm32f103-onenet-nbiot/board/Kconfig index b532fa55c4b..e4d4bb6a2ea 100644 --- a/bsp/stm32/stm32f103-onenet-nbiot/board/Kconfig +++ b/bsp/stm32/stm32f103-onenet-nbiot/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103RB - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -68,7 +61,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-onenet-nbiot/board/board.c b/bsp/stm32/stm32f103-onenet-nbiot/board/board.c index 5e045816b2f..aef00868680 100644 --- a/bsp/stm32/stm32f103-onenet-nbiot/board/board.c +++ b/bsp/stm32/stm32f103-onenet-nbiot/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 balanceTWK first version */ -#include "board.h" +#include +#include /** * @brief System Clock Configuration diff --git a/bsp/stm32/stm32f103-onenet-nbiot/board/board.h b/bsp/stm32/stm32f103-onenet-nbiot/board/board.h index 2e5f93a0bbc..e63e4c96d94 100644 --- a/bsp/stm32/stm32f103-onenet-nbiot/board/board.h +++ b/bsp/stm32/stm32f103-onenet-nbiot/board/board.h @@ -12,8 +12,6 @@ #define __BOARD_H__ #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-yf-ufun/Kconfig b/bsp/stm32/stm32f103-yf-ufun/Kconfig index 7a400db91f4..310d56eb02a 100644 --- a/bsp/stm32/stm32f103-yf-ufun/Kconfig +++ b/bsp/stm32/stm32f103-yf-ufun/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103RC + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-yf-ufun/applications/main.c b/bsp/stm32/stm32f103-yf-ufun/applications/main.c index 8f9c5c7a07d..e7057a7bf92 100644 --- a/bsp/stm32/stm32f103-yf-ufun/applications/main.c +++ b/bsp/stm32/stm32f103-yf-ufun/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED3 pin: PA3 */ #define LED3_PIN GET_PIN(A, 3) diff --git a/bsp/stm32/stm32f103-yf-ufun/board/Kconfig b/bsp/stm32/stm32f103-yf-ufun/board/Kconfig index 4892c73b49c..dc853634e17 100644 --- a/bsp/stm32/stm32f103-yf-ufun/board/Kconfig +++ b/bsp/stm32/stm32f103-yf-ufun/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103RC - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -101,7 +94,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_DFS_ELMFAT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-yf-ufun/board/board.c b/bsp/stm32/stm32f103-yf-ufun/board/board.c index 5271b59c71a..0ee9ec37996 100644 --- a/bsp/stm32/stm32f103-yf-ufun/board/board.c +++ b/bsp/stm32/stm32f103-yf-ufun/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f103-yf-ufun/board/board.h b/bsp/stm32/stm32f103-yf-ufun/board/board.h index fa0ff3fed24..c411be8f068 100644 --- a/bsp/stm32/stm32f103-yf-ufun/board/board.h +++ b/bsp/stm32/stm32f103-yf-ufun/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f103-ys-f1pro/Kconfig b/bsp/stm32/stm32f103-ys-f1pro/Kconfig index 7a400db91f4..ed350cbe678 100644 --- a/bsp/stm32/stm32f103-ys-f1pro/Kconfig +++ b/bsp/stm32/stm32f103-ys-f1pro/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F103ZE + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f103-ys-f1pro/applications/main.c b/bsp/stm32/stm32f103-ys-f1pro/applications/main.c index adf981c8b00..90b5fb3e146 100644 --- a/bsp/stm32/stm32f103-ys-f1pro/applications/main.c +++ b/bsp/stm32/stm32f103-ys-f1pro/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2022-09-01 liYony first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED1 pin: PB0 */ #define LED1_PIN GET_PIN(B, 0) diff --git a/bsp/stm32/stm32f103-ys-f1pro/board/Kconfig b/bsp/stm32/stm32f103-ys-f1pro/board/Kconfig index 7ed6ebc52c2..23a802ef936 100644 --- a/bsp/stm32/stm32f103-ys-f1pro/board/Kconfig +++ b/bsp/stm32/stm32f103-ys-f1pro/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F103ZE - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -34,7 +27,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f103-ys-f1pro/board/board.c b/bsp/stm32/stm32f103-ys-f1pro/board/board.c index 6fad08c1d7a..82502b3c1dd 100644 --- a/bsp/stm32/stm32f103-ys-f1pro/board/board.c +++ b/bsp/stm32/stm32f103-ys-f1pro/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include /** * @brief System Clock Configuration diff --git a/bsp/stm32/stm32f103-ys-f1pro/board/board.h b/bsp/stm32/stm32f103-ys-f1pro/board/board.h index 250e5c7b033..9dfa04eea8c 100644 --- a/bsp/stm32/stm32f103-ys-f1pro/board/board.h +++ b/bsp/stm32/stm32f103-ys-f1pro/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f107-uc-eval/Kconfig b/bsp/stm32/stm32f107-uc-eval/Kconfig index 7a400db91f4..cf7bf14f7fc 100644 --- a/bsp/stm32/stm32f107-uc-eval/Kconfig +++ b/bsp/stm32/stm32f107-uc-eval/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F107VC + bool + select SOC_SERIES_STM32F1 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f107-uc-eval/applications/main.c b/bsp/stm32/stm32f107-uc-eval/applications/main.c index 9f1a27444d0..5d53deab417 100644 --- a/bsp/stm32/stm32f107-uc-eval/applications/main.c +++ b/bsp/stm32/stm32f107-uc-eval/applications/main.c @@ -7,11 +7,15 @@ * Date Author Notes * 2018-11-06 SummerGift change to new framework * 2019-01-12 whj add stm32f107-uc-Eval bsp + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED1 pin: PD13 */ #define LED1_PIN GET_PIN(D, 13) diff --git a/bsp/stm32/stm32f107-uc-eval/board/Kconfig b/bsp/stm32/stm32f107-uc-eval/board/Kconfig index 10acf5fca56..98dcf2f1ae6 100644 --- a/bsp/stm32/stm32f107-uc-eval/board/Kconfig +++ b/bsp/stm32/stm32f107-uc-eval/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F107VC - bool - select SOC_SERIES_STM32F1 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -41,7 +34,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f107-uc-eval/board/board.c b/bsp/stm32/stm32f107-uc-eval/board/board.c index f053579c2f2..4587941d680 100644 --- a/bsp/stm32/stm32f107-uc-eval/board/board.c +++ b/bsp/stm32/stm32f107-uc-eval/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift change to new framework */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f107-uc-eval/board/board.h b/bsp/stm32/stm32f107-uc-eval/board/board.h index ce1681ba28f..ba31da810d5 100644 --- a/bsp/stm32/stm32f107-uc-eval/board/board.h +++ b/bsp/stm32/stm32f107-uc-eval/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f207-st-nucleo/Kconfig b/bsp/stm32/stm32f207-st-nucleo/Kconfig index 7a400db91f4..7fca6060826 100644 --- a/bsp/stm32/stm32f207-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f207-st-nucleo/Kconfig @@ -15,8 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F207ZG + bool + select SOC_SERIES_STM32F2 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f207-st-nucleo/applications/main.c b/bsp/stm32/stm32f207-st-nucleo/applications/main.c index b88176a8acd..49c891c5538 100644 --- a/bsp/stm32/stm32f207-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f207-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PB14 */ #define LED0_PIN GET_PIN(B, 14) diff --git a/bsp/stm32/stm32f207-st-nucleo/board/Kconfig b/bsp/stm32/stm32f207-st-nucleo/board/Kconfig index 9521c89825e..f28ced5cb62 100644 --- a/bsp/stm32/stm32f207-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f207-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F207ZG - bool - select SOC_SERIES_STM32F2 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -28,7 +21,7 @@ menu "On-chip Peripheral Drivers" default y endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f207-st-nucleo/board/board.c b/bsp/stm32/stm32f207-st-nucleo/board/board.c index cd22eb8a57f..8aab0cc5505 100644 --- a/bsp/stm32/stm32f207-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f207-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f207-st-nucleo/board/board.h b/bsp/stm32/stm32f207-st-nucleo/board/board.h index c52bed558b5..2c511fd6c6a 100644 --- a/bsp/stm32/stm32f207-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f207-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f302-st-nucleo/Kconfig b/bsp/stm32/stm32f302-st-nucleo/Kconfig index 79b160b8567..fb71ffbecaf 100644 --- a/bsp/stm32/stm32f302-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f302-st-nucleo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F302R8 + bool + select SOC_SERIES_STM32F3 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f302-st-nucleo/applications/main.c b/bsp/stm32/stm32f302-st-nucleo/applications/main.c index 92a4f084e4f..7cfcabdc1c3 100644 --- a/bsp/stm32/stm32f302-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f302-st-nucleo/applications/main.c @@ -6,25 +6,29 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ + +/* defined the LED0 pin: PB13 */ +#define LED0_PIN GET_PIN(B, 13) int main(void) { - /* LED pin: PB13 */ - rt_uint16_t led = rt_pin_get("PB.13"); - /* set LED pin mode to output */ - rt_pin_mode(led, PIN_MODE_OUTPUT); + rt_pin_mode(LED0_PIN, PIN_MODE_OUTPUT); while (1) { - rt_pin_write(led, PIN_HIGH); + rt_pin_write(LED0_PIN, PIN_HIGH); rt_thread_mdelay(500); - rt_pin_write(led, PIN_LOW); + rt_pin_write(LED0_PIN, PIN_LOW); rt_thread_mdelay(500); } diff --git a/bsp/stm32/stm32f302-st-nucleo/board/Kconfig b/bsp/stm32/stm32f302-st-nucleo/board/Kconfig index e4414bfa2a9..1bdbb7eea22 100644 --- a/bsp/stm32/stm32f302-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f302-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F302R8 - bool - select SOC_SERIES_STM32F3 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu diff --git a/bsp/stm32/stm32f302-st-nucleo/board/board.c b/bsp/stm32/stm32f302-st-nucleo/board/board.c index 2f0ec3e7590..175f61685de 100644 --- a/bsp/stm32/stm32f302-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f302-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f302-st-nucleo/board/board.h b/bsp/stm32/stm32f302-st-nucleo/board/board.h index de61eb75141..2b84e583ced 100644 --- a/bsp/stm32/stm32f302-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f302-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f334-st-nucleo/Kconfig b/bsp/stm32/stm32f334-st-nucleo/Kconfig index 79b160b8567..e3f8480d13c 100644 --- a/bsp/stm32/stm32f334-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f334-st-nucleo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F334R8 + bool + select SOC_SERIES_STM32F3 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f334-st-nucleo/applications/main.c b/bsp/stm32/stm32f334-st-nucleo/applications/main.c index 1b4d409a457..2bcbd772d0f 100644 --- a/bsp/stm32/stm32f334-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f334-st-nucleo/applications/main.c @@ -8,23 +8,26 @@ * 2023-06-05 tangzz98 first version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ + +/* defined the LED0 pin: PA5 */ +#define LED0_PIN GET_PIN(A, 5) int main(void) { - /* LED pin: PB13 */ - rt_uint16_t led = rt_pin_get("PA.5"); - /* set LED pin mode to output */ - rt_pin_mode(led, PIN_MODE_OUTPUT); + rt_pin_mode(LED0_PIN, PIN_MODE_OUTPUT); while (1) { - rt_pin_write(led, PIN_HIGH); + rt_pin_write(LED0_PIN, PIN_HIGH); rt_thread_mdelay(500); - rt_pin_write(led, PIN_LOW); + rt_pin_write(LED0_PIN, PIN_LOW); rt_thread_mdelay(500); } diff --git a/bsp/stm32/stm32f334-st-nucleo/board/Kconfig b/bsp/stm32/stm32f334-st-nucleo/board/Kconfig index a4a9dd2c0fe..0e6eb5d1466 100644 --- a/bsp/stm32/stm32f334-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f334-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F334R8 - bool - select SOC_SERIES_STM32F3 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu diff --git a/bsp/stm32/stm32f334-st-nucleo/board/board.c b/bsp/stm32/stm32f334-st-nucleo/board/board.c index 0565fc0dfcd..815f7692835 100644 --- a/bsp/stm32/stm32f334-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f334-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2023-06-05 tangzz98 first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f334-st-nucleo/board/board.h b/bsp/stm32/stm32f334-st-nucleo/board/board.h index d343bebc848..cd749cbea21 100644 --- a/bsp/stm32/stm32f334-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f334-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f401-st-nucleo/Kconfig b/bsp/stm32/stm32f401-st-nucleo/Kconfig index 79b160b8567..b4dc11b77fb 100644 --- a/bsp/stm32/stm32f401-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f401-st-nucleo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F401RE + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f401-st-nucleo/applications/main.c b/bsp/stm32/stm32f401-st-nucleo/applications/main.c index 36a52e02a86..ce0f2572d00 100644 --- a/bsp/stm32/stm32f401-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f401-st-nucleo/applications/main.c @@ -6,13 +6,17 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ -/* defined the LD2 (user LED) pin: PB1 */ +/* defined the LD2 (user LED) pin: PA5 */ #define LED2_PIN GET_PIN(A, 5) int main(void) diff --git a/bsp/stm32/stm32f401-st-nucleo/board/Kconfig b/bsp/stm32/stm32f401-st-nucleo/board/Kconfig index a462e103a9f..f9e5650bf92 100644 --- a/bsp/stm32/stm32f401-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f401-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F401RE - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART bool "Enable STLINK TO USART (uart2)" @@ -208,7 +201,7 @@ menu "On-chip Peripheral Drivers" endif endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f401-st-nucleo/board/board.c b/bsp/stm32/stm32f401-st-nucleo/board/board.c index 9c33cdbba5d..00b4975f173 100644 --- a/bsp/stm32/stm32f401-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f401-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f401-st-nucleo/board/board.h b/bsp/stm32/stm32f401-st-nucleo/board/board.h index 93a2407c875..ae1c69f8b52 100644 --- a/bsp/stm32/stm32f401-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f401-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f401-weact-blackpill/Kconfig b/bsp/stm32/stm32f401-weact-blackpill/Kconfig index 79b160b8567..0cbf0f9a33e 100644 --- a/bsp/stm32/stm32f401-weact-blackpill/Kconfig +++ b/bsp/stm32/stm32f401-weact-blackpill/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F401CC + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f401-weact-blackpill/applications/main.c b/bsp/stm32/stm32f401-weact-blackpill/applications/main.c index 5faa7145bd3..c61ddb90ee7 100644 --- a/bsp/stm32/stm32f401-weact-blackpill/applications/main.c +++ b/bsp/stm32/stm32f401-weact-blackpill/applications/main.c @@ -6,13 +6,17 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ -/* defined the LED0 pin: PB1 */ +/* defined the LED0 pin: PC13 */ #define LED0_PIN GET_PIN(C, 13) int main(void) diff --git a/bsp/stm32/stm32f401-weact-blackpill/board/Kconfig b/bsp/stm32/stm32f401-weact-blackpill/board/Kconfig index 3bb705e5a64..18e74b8184c 100644 --- a/bsp/stm32/stm32f401-weact-blackpill/board/Kconfig +++ b/bsp/stm32/stm32f401-weact-blackpill/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F401CC - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_ARDUINO @@ -131,7 +124,7 @@ menu "On-chip Peripheral Drivers" default 46 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f401-weact-blackpill/board/board.c b/bsp/stm32/stm32f401-weact-blackpill/board/board.c index 8e1061d2c68..918a9b245c7 100644 --- a/bsp/stm32/stm32f401-weact-blackpill/board/board.c +++ b/bsp/stm32/stm32f401-weact-blackpill/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f401-weact-blackpill/board/board.h b/bsp/stm32/stm32f401-weact-blackpill/board/board.h index 76454062fbf..002cb8da444 100644 --- a/bsp/stm32/stm32f401-weact-blackpill/board/board.h +++ b/bsp/stm32/stm32f401-weact-blackpill/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f405-smdz-breadfruit/Kconfig b/bsp/stm32/stm32f405-smdz-breadfruit/Kconfig index 79b160b8567..4a7f6c96821 100644 --- a/bsp/stm32/stm32f405-smdz-breadfruit/Kconfig +++ b/bsp/stm32/stm32f405-smdz-breadfruit/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F405RG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f405-smdz-breadfruit/applications/main.c b/bsp/stm32/stm32f405-smdz-breadfruit/applications/main.c index 9f52445b11d..937dcbf488d 100644 --- a/bsp/stm32/stm32f405-smdz-breadfruit/applications/main.c +++ b/bsp/stm32/stm32f405-smdz-breadfruit/applications/main.c @@ -6,14 +6,19 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ -/* defined the LED0 pin: PC4-36 PA8-8,PC5-37,PA10-10*/ -#define LED0_PIN 10 +/* defined the LED0 pin: PC4 */ +/* LEDs: PC4, PA8, PC5, PA10 */ +#define LED0_PIN GET_PIN(C, 4) int main(void) { diff --git a/bsp/stm32/stm32f405-smdz-breadfruit/board/Kconfig b/bsp/stm32/stm32f405-smdz-breadfruit/board/Kconfig index 9a69caa8537..9a965262ffe 100644 --- a/bsp/stm32/stm32f405-smdz-breadfruit/board/Kconfig +++ b/bsp/stm32/stm32f405-smdz-breadfruit/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F405RG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -32,7 +25,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f405-smdz-breadfruit/board/board.c b/bsp/stm32/stm32f405-smdz-breadfruit/board/board.c index 190ca080cf5..306fc433f26 100644 --- a/bsp/stm32/stm32f405-smdz-breadfruit/board/board.c +++ b/bsp/stm32/stm32f405-smdz-breadfruit/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h b/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h index 64d30cc5b73..6ef645fb5df 100644 --- a/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h +++ b/bsp/stm32/stm32f405-smdz-breadfruit/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f405zg-mini-template/Kconfig b/bsp/stm32/stm32f405zg-mini-template/Kconfig index 79b160b8567..577928c20be 100644 --- a/bsp/stm32/stm32f405zg-mini-template/Kconfig +++ b/bsp/stm32/stm32f405zg-mini-template/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F405ZG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f405zg-mini-template/applications/main.c b/bsp/stm32/stm32f405zg-mini-template/applications/main.c index ed2b96fa797..bf5eb5b80e6 100644 --- a/bsp/stm32/stm32f405zg-mini-template/applications/main.c +++ b/bsp/stm32/stm32f405zg-mini-template/applications/main.c @@ -5,13 +5,16 @@ * * Change Logs: * Date Author Notes - * 2018-11-06 SummerGift first version * 2023-08-22 Donocean first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the RGB0 pin: PF6 */ #define LED0_PIN GET_PIN(F, 6) diff --git a/bsp/stm32/stm32f405zg-mini-template/board/Kconfig b/bsp/stm32/stm32f405zg-mini-template/board/Kconfig index c1a9a4f2117..8a65aca73d1 100644 --- a/bsp/stm32/stm32f405zg-mini-template/board/Kconfig +++ b/bsp/stm32/stm32f405zg-mini-template/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F405ZG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_SPI_FLASH @@ -120,7 +113,7 @@ menu "On-chip Peripheral Drivers" endif endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f405zg-mini-template/board/board.c b/bsp/stm32/stm32f405zg-mini-template/board/board.c index f2e4f070c9b..4f2db145e83 100644 --- a/bsp/stm32/stm32f405zg-mini-template/board/board.c +++ b/bsp/stm32/stm32f405zg-mini-template/board/board.c @@ -9,7 +9,8 @@ * 2023-08-20 Donocean Configure Main clock to 168MHz */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f405zg-mini-template/board/board.h b/bsp/stm32/stm32f405zg-mini-template/board/board.h index 9b438444e26..c7c7391f2c5 100644 --- a/bsp/stm32/stm32f405zg-mini-template/board/board.h +++ b/bsp/stm32/stm32f405zg-mini-template/board/board.h @@ -12,10 +12,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f407-armfly-v5/Kconfig b/bsp/stm32/stm32f407-armfly-v5/Kconfig index 79b160b8567..ad277e4f131 100644 --- a/bsp/stm32/stm32f407-armfly-v5/Kconfig +++ b/bsp/stm32/stm32f407-armfly-v5/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F407IG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f407-armfly-v5/applications/main.c b/bsp/stm32/stm32f407-armfly-v5/applications/main.c index f7ace7aa576..d4ffbccdbf8 100644 --- a/bsp/stm32/stm32f407-armfly-v5/applications/main.c +++ b/bsp/stm32/stm32f407-armfly-v5/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2020-07-13 Dozingfiretruck first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED4 pin: PC2 */ #define LED0_PIN GET_PIN(C, 2) diff --git a/bsp/stm32/stm32f407-armfly-v5/board/Kconfig b/bsp/stm32/stm32f407-armfly-v5/board/Kconfig index a67ea1f21da..aa5964cb66a 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/Kconfig +++ b/bsp/stm32/stm32f407-armfly-v5/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F407IG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_RS232_TO_USART @@ -186,7 +179,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_DFS default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f407-armfly-v5/board/board.c b/bsp/stm32/stm32f407-armfly-v5/board/board.c index 89a7fdc26af..e80bcb0e7cb 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/board.c +++ b/bsp/stm32/stm32f407-armfly-v5/board/board.c @@ -8,7 +8,8 @@ * 2020-07-13 Dozingfiretruck first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f407-armfly-v5/board/board.h b/bsp/stm32/stm32f407-armfly-v5/board/board.h index 995b482f866..4e8feb60fd0 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/board.h +++ b/bsp/stm32/stm32f407-armfly-v5/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f407-atk-explorer/Kconfig b/bsp/stm32/stm32f407-atk-explorer/Kconfig index 79b160b8567..d90b5952443 100644 --- a/bsp/stm32/stm32f407-atk-explorer/Kconfig +++ b/bsp/stm32/stm32f407-atk-explorer/Kconfig @@ -15,7 +15,21 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F407ZG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + +config BOARD_STM32F407_ATK_EXPLORER + bool + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f407-atk-explorer/applications/main.c b/bsp/stm32/stm32f407-atk-explorer/applications/main.c index 9fb7ebf1538..573ae823e71 100644 --- a/bsp/stm32/stm32f407-atk-explorer/applications/main.c +++ b/bsp/stm32/stm32f407-atk-explorer/applications/main.c @@ -7,11 +7,15 @@ * Date Author Notes * 2018-11-06 SummerGift first version * 2018-11-19 flybreak add stm32f407-atk-explorer bsp + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PF9 */ #define LED0_PIN GET_PIN(F, 9) diff --git a/bsp/stm32/stm32f407-atk-explorer/board/Kconfig b/bsp/stm32/stm32f407-atk-explorer/board/Kconfig index 8445eff75fb..c8302e8c87b 100644 --- a/bsp/stm32/stm32f407-atk-explorer/board/Kconfig +++ b/bsp/stm32/stm32f407-atk-explorer/board/Kconfig @@ -1,16 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F407ZG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - -config BOARD_STM32F407_ATK_EXPLORER - bool - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -500,7 +489,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_FMC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f407-atk-explorer/board/board.c b/bsp/stm32/stm32f407-atk-explorer/board/board.c index 02a3a3d53f6..f5de0dd107a 100644 --- a/bsp/stm32/stm32f407-atk-explorer/board/board.c +++ b/bsp/stm32/stm32f407-atk-explorer/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f407-atk-explorer/board/board.h b/bsp/stm32/stm32f407-atk-explorer/board/board.h index b88f85a0643..c9c29aa1348 100644 --- a/bsp/stm32/stm32f407-atk-explorer/board/board.h +++ b/bsp/stm32/stm32f407-atk-explorer/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f407-robomaster-c/Kconfig b/bsp/stm32/stm32f407-robomaster-c/Kconfig index 79b160b8567..ad277e4f131 100644 --- a/bsp/stm32/stm32f407-robomaster-c/Kconfig +++ b/bsp/stm32/stm32f407-robomaster-c/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F407IG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f407-robomaster-c/applications/main.c b/bsp/stm32/stm32f407-robomaster-c/applications/main.c index 919267ba149..88aa5968a2e 100644 --- a/bsp/stm32/stm32f407-robomaster-c/applications/main.c +++ b/bsp/stm32/stm32f407-robomaster-c/applications/main.c @@ -5,13 +5,16 @@ * * Change Logs: * Date Author Notes - * 2018-11-06 SummerGift first version - * 2021-06-30 crazt modify for robomaster C board + * 2021-06-30 crazt first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED Blue pin: PH10 */ #define LED_B_PIN GET_PIN(H, 10) diff --git a/bsp/stm32/stm32f407-robomaster-c/board/Kconfig b/bsp/stm32/stm32f407-robomaster-c/board/Kconfig index 78eaf1cd333..f9226bda3e8 100644 --- a/bsp/stm32/stm32f407-robomaster-c/board/Kconfig +++ b/bsp/stm32/stm32f407-robomaster-c/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F407IG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_ARDUINO @@ -202,7 +195,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f407-robomaster-c/board/board.c b/bsp/stm32/stm32f407-robomaster-c/board/board.c index d544465866c..57aa190669a 100644 --- a/bsp/stm32/stm32f407-robomaster-c/board/board.c +++ b/bsp/stm32/stm32f407-robomaster-c/board/board.c @@ -9,7 +9,8 @@ * 2021-06-30 crazt modify for robomaster C board */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f407-robomaster-c/board/board.h b/bsp/stm32/stm32f407-robomaster-c/board/board.h index 92b95201692..d03ea54c080 100644 --- a/bsp/stm32/stm32f407-robomaster-c/board/board.h +++ b/bsp/stm32/stm32f407-robomaster-c/board/board.h @@ -12,10 +12,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f407-rt-spark/board/Kconfig b/bsp/stm32/stm32f407-rt-spark/board/Kconfig index 222339a1c12..94a62539a89 100644 --- a/bsp/stm32/stm32f407-rt-spark/board/Kconfig +++ b/bsp/stm32/stm32f407-rt-spark/board/Kconfig @@ -664,7 +664,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_FMC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f407-st-discovery/Kconfig b/bsp/stm32/stm32f407-st-discovery/Kconfig index 79b160b8567..2578bf455bb 100644 --- a/bsp/stm32/stm32f407-st-discovery/Kconfig +++ b/bsp/stm32/stm32f407-st-discovery/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F407VG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f407-st-discovery/applications/main.c b/bsp/stm32/stm32f407-st-discovery/applications/main.c index ecc3464e690..95b0daddca6 100644 --- a/bsp/stm32/stm32f407-st-discovery/applications/main.c +++ b/bsp/stm32/stm32f407-st-discovery/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 misonyo first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PD14 */ #define LED0_PIN GET_PIN(D, 14) diff --git a/bsp/stm32/stm32f407-st-discovery/board/Kconfig b/bsp/stm32/stm32f407-st-discovery/board/Kconfig index d68092835a2..604e56d3e44 100644 --- a/bsp/stm32/stm32f407-st-discovery/board/Kconfig +++ b/bsp/stm32/stm32f407-st-discovery/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F407VG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -70,7 +63,7 @@ menu "On-chip Peripheral Drivers" range 1 216 default 25 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f407-st-discovery/board/board.c b/bsp/stm32/stm32f407-st-discovery/board/board.c index 5fff5426fef..48deaaf9b10 100644 --- a/bsp/stm32/stm32f407-st-discovery/board/board.c +++ b/bsp/stm32/stm32f407-st-discovery/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f407-st-discovery/board/board.h b/bsp/stm32/stm32f407-st-discovery/board/board.h index ca3b4f8b243..2df8a2355dd 100644 --- a/bsp/stm32/stm32f407-st-discovery/board/board.h +++ b/bsp/stm32/stm32f407-st-discovery/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f410-st-nucleo/Kconfig b/bsp/stm32/stm32f410-st-nucleo/Kconfig index 79b160b8567..4666cce094e 100644 --- a/bsp/stm32/stm32f410-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f410-st-nucleo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F410RB + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f410-st-nucleo/applications/main.c b/bsp/stm32/stm32f410-st-nucleo/applications/main.c index 0de22d3ffde..f01561b005b 100644 --- a/bsp/stm32/stm32f410-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f410-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2020-03-07 tanglj86 first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PA5 */ #define LED0_PIN GET_PIN(A, 5) diff --git a/bsp/stm32/stm32f410-st-nucleo/board/Kconfig b/bsp/stm32/stm32f410-st-nucleo/board/Kconfig index 20f86112624..db487454e85 100644 --- a/bsp/stm32/stm32f410-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f410-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F410RB - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART bool "Enable STLINK TO USART (uart2)" @@ -114,7 +107,7 @@ menu "On-chip Peripheral Drivers" default 25 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f410-st-nucleo/board/board.c b/bsp/stm32/stm32f410-st-nucleo/board/board.c index 3e64df40d77..851e473a7f7 100644 --- a/bsp/stm32/stm32f410-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f410-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2020-03-07 tanglj86 first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f411-atk-nano/Kconfig b/bsp/stm32/stm32f411-atk-nano/Kconfig index 79b160b8567..b05130fafa1 100644 --- a/bsp/stm32/stm32f411-atk-nano/Kconfig +++ b/bsp/stm32/stm32f411-atk-nano/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F411RC + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f411-atk-nano/applications/main.c b/bsp/stm32/stm32f411-atk-nano/applications/main.c index 351b59dc19a..1e35cb63351 100644 --- a/bsp/stm32/stm32f411-atk-nano/applications/main.c +++ b/bsp/stm32/stm32f411-atk-nano/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2020-05-11 bigaij first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PC0 */ #define LED0_PIN GET_PIN(C, 0) diff --git a/bsp/stm32/stm32f411-atk-nano/board/Kconfig b/bsp/stm32/stm32f411-atk-nano/board/Kconfig index a8c6c660916..af4d8b84708 100644 --- a/bsp/stm32/stm32f411-atk-nano/board/Kconfig +++ b/bsp/stm32/stm32f411-atk-nano/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F411RC - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -159,7 +152,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f411-atk-nano/board/board.c b/bsp/stm32/stm32f411-atk-nano/board/board.c index 08158c2f96a..32eb015f162 100644 --- a/bsp/stm32/stm32f411-atk-nano/board/board.c +++ b/bsp/stm32/stm32f411-atk-nano/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f411-atk-nano/board/board.h b/bsp/stm32/stm32f411-atk-nano/board/board.h index f301f3f5275..4f56eb8e569 100644 --- a/bsp/stm32/stm32f411-atk-nano/board/board.h +++ b/bsp/stm32/stm32f411-atk-nano/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f411-st-nucleo/Kconfig b/bsp/stm32/stm32f411-st-nucleo/Kconfig index 79b160b8567..d5b1524e05c 100644 --- a/bsp/stm32/stm32f411-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f411-st-nucleo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F411RE + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f411-st-nucleo/applications/main.c b/bsp/stm32/stm32f411-st-nucleo/applications/main.c index 9f366155073..590e0919c8e 100644 --- a/bsp/stm32/stm32f411-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f411-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PA5 */ #define LED0_PIN GET_PIN(A, 5) diff --git a/bsp/stm32/stm32f411-st-nucleo/board/Kconfig b/bsp/stm32/stm32f411-st-nucleo/board/Kconfig index 19cebb0b350..4624e8eab42 100644 --- a/bsp/stm32/stm32f411-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f411-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F411RE - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART bool "Enable STLINK TO USART (uart2)" @@ -233,7 +226,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f411-st-nucleo/board/board.c b/bsp/stm32/stm32f411-st-nucleo/board/board.c index 1d833867199..f733dde70e7 100644 --- a/bsp/stm32/stm32f411-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f411-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f411-st-nucleo/board/board.h b/bsp/stm32/stm32f411-st-nucleo/board/board.h index 25b839b3805..9bd1b060202 100644 --- a/bsp/stm32/stm32f411-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f411-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f411-weact-blackpill/Kconfig b/bsp/stm32/stm32f411-weact-blackpill/Kconfig index 79b160b8567..d5b1524e05c 100644 --- a/bsp/stm32/stm32f411-weact-blackpill/Kconfig +++ b/bsp/stm32/stm32f411-weact-blackpill/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F411RE + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f411-weact-blackpill/applications/main.c b/bsp/stm32/stm32f411-weact-blackpill/applications/main.c index f28cc62dd27..4d21341f143 100644 --- a/bsp/stm32/stm32f411-weact-blackpill/applications/main.c +++ b/bsp/stm32/stm32f411-weact-blackpill/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PC13 */ #define LED0_PIN GET_PIN(C, 13) diff --git a/bsp/stm32/stm32f411-weact-blackpill/board/Kconfig b/bsp/stm32/stm32f411-weact-blackpill/board/Kconfig index 563869c25b7..d7798f16de4 100644 --- a/bsp/stm32/stm32f411-weact-blackpill/board/Kconfig +++ b/bsp/stm32/stm32f411-weact-blackpill/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F411RE - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_ARDUINO bool "Compatible with Arduino Ecosystem (RTduino)" @@ -183,7 +176,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_USB_DEVICE default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f411-weact-blackpill/board/board.c b/bsp/stm32/stm32f411-weact-blackpill/board/board.c index 7f27135a6b9..c4968a8a730 100644 --- a/bsp/stm32/stm32f411-weact-blackpill/board/board.c +++ b/bsp/stm32/stm32f411-weact-blackpill/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f411-weact-blackpill/board/board.h b/bsp/stm32/stm32f411-weact-blackpill/board/board.h index 25b839b3805..9bd1b060202 100644 --- a/bsp/stm32/stm32f411-weact-blackpill/board/board.h +++ b/bsp/stm32/stm32f411-weact-blackpill/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f412-st-nucleo/Kconfig b/bsp/stm32/stm32f412-st-nucleo/Kconfig index 79b160b8567..ca218de8e37 100644 --- a/bsp/stm32/stm32f412-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f412-st-nucleo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F412ZG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f412-st-nucleo/applications/main.c b/bsp/stm32/stm32f412-st-nucleo/applications/main.c index ec30dd059bc..4139c204730 100644 --- a/bsp/stm32/stm32f412-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f412-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the USER LED2 pin: PB7 */ #define LED2_PIN GET_PIN(B, 7) diff --git a/bsp/stm32/stm32f412-st-nucleo/board/Kconfig b/bsp/stm32/stm32f412-st-nucleo/board/Kconfig index 40dc97105f7..547d6857e40 100644 --- a/bsp/stm32/stm32f412-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f412-st-nucleo/board/Kconfig @@ -1,13 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F412ZG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART diff --git a/bsp/stm32/stm32f412-st-nucleo/board/board.c b/bsp/stm32/stm32f412-st-nucleo/board/board.c index b8f8168dfab..be864756e85 100644 --- a/bsp/stm32/stm32f412-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f412-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f412-st-nucleo/board/board.h b/bsp/stm32/stm32f412-st-nucleo/board/board.h index 8d1465a1c9c..3741628abdb 100644 --- a/bsp/stm32/stm32f412-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f412-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f413-st-nucleo/Kconfig b/bsp/stm32/stm32f413-st-nucleo/Kconfig index 79b160b8567..ab2a912e696 100644 --- a/bsp/stm32/stm32f413-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f413-st-nucleo/Kconfig @@ -15,7 +15,18 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" + +config SOC_STM32F413ZH + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f413-st-nucleo/applications/main.c b/bsp/stm32/stm32f413-st-nucleo/applications/main.c index ddd672e739c..e543f100fec 100644 --- a/bsp/stm32/stm32f413-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f413-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED1 pin: PB0 */ #define LED1_PIN GET_PIN(B, 0) diff --git a/bsp/stm32/stm32f413-st-nucleo/board/Kconfig b/bsp/stm32/stm32f413-st-nucleo/board/Kconfig index 6af61350740..5b3ae767a1b 100644 --- a/bsp/stm32/stm32f413-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f413-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F413ZH - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART @@ -160,7 +153,7 @@ menu "On-chip Peripheral Drivers" select BSP_USBD_TYPE_FS default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f413-st-nucleo/board/board.c b/bsp/stm32/stm32f413-st-nucleo/board/board.c index b36f9735303..b71acd61b0a 100644 --- a/bsp/stm32/stm32f413-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f413-st-nucleo/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include /** * @brief System Clock Configuration diff --git a/bsp/stm32/stm32f413-st-nucleo/board/board.h b/bsp/stm32/stm32f413-st-nucleo/board/board.h index e98990ce756..02f62905692 100644 --- a/bsp/stm32/stm32f413-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f413-st-nucleo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f427-robomaster-a/Kconfig b/bsp/stm32/stm32f427-robomaster-a/Kconfig index 79b160b8567..fe518d308ca 100644 --- a/bsp/stm32/stm32f427-robomaster-a/Kconfig +++ b/bsp/stm32/stm32f427-robomaster-a/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F427II + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f427-robomaster-a/applications/main.c b/bsp/stm32/stm32f427-robomaster-a/applications/main.c index f63f29396c7..59098f00e20 100644 --- a/bsp/stm32/stm32f427-robomaster-a/applications/main.c +++ b/bsp/stm32/stm32f427-robomaster-a/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED_G pin: PF14 */ #define LED0_PIN GET_PIN(F, 14) diff --git a/bsp/stm32/stm32f427-robomaster-a/board/Kconfig b/bsp/stm32/stm32f427-robomaster-a/board/Kconfig index 0ced3474391..76e47e04f39 100644 --- a/bsp/stm32/stm32f427-robomaster-a/board/Kconfig +++ b/bsp/stm32/stm32f427-robomaster-a/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F427II - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_SDCARD bool "Enable SDCARD (sdio)" @@ -246,7 +239,7 @@ menu "On-chip Peripheral Drivers" endif endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f427-robomaster-a/board/board.c b/bsp/stm32/stm32f427-robomaster-a/board/board.c index 780e089fcd5..865640b7433 100644 --- a/bsp/stm32/stm32f427-robomaster-a/board/board.c +++ b/bsp/stm32/stm32f427-robomaster-a/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include /** * @brief System Clock Configuration diff --git a/bsp/stm32/stm32f427-robomaster-a/board/board.h b/bsp/stm32/stm32f427-robomaster-a/board/board.h index 0e3a162baed..a1a7398a1b7 100644 --- a/bsp/stm32/stm32f427-robomaster-a/board/board.h +++ b/bsp/stm32/stm32f427-robomaster-a/board/board.h @@ -12,10 +12,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f429-armfly-v6/Kconfig b/bsp/stm32/stm32f429-armfly-v6/Kconfig index 79b160b8567..61648f9905f 100644 --- a/bsp/stm32/stm32f429-armfly-v6/Kconfig +++ b/bsp/stm32/stm32f429-armfly-v6/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F429BI + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f429-armfly-v6/board/Kconfig b/bsp/stm32/stm32f429-armfly-v6/board/Kconfig index 0aa90398d88..e9d993c9ecf 100644 --- a/bsp/stm32/stm32f429-armfly-v6/board/Kconfig +++ b/bsp/stm32/stm32f429-armfly-v6/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F429BI - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_RS232_TO_USART @@ -219,7 +212,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_LTDC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f429-atk-apollo/Kconfig b/bsp/stm32/stm32f429-atk-apollo/Kconfig index 79b160b8567..ddc9b196d57 100644 --- a/bsp/stm32/stm32f429-atk-apollo/Kconfig +++ b/bsp/stm32/stm32f429-atk-apollo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F429IG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f429-atk-apollo/applications/main.c b/bsp/stm32/stm32f429-atk-apollo/applications/main.c index 609b4e63b45..50c7fface37 100644 --- a/bsp/stm32/stm32f429-atk-apollo/applications/main.c +++ b/bsp/stm32/stm32f429-atk-apollo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PB1 */ #define LED0_PIN GET_PIN(B, 1) diff --git a/bsp/stm32/stm32f429-atk-apollo/board/Kconfig b/bsp/stm32/stm32f429-atk-apollo/board/Kconfig index 0e2fa4d8330..f5ab5b5a838 100644 --- a/bsp/stm32/stm32f429-atk-apollo/board/Kconfig +++ b/bsp/stm32/stm32f429-atk-apollo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F429IG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -295,7 +288,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_FMC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f429-atk-apollo/board/board.c b/bsp/stm32/stm32f429-atk-apollo/board/board.c index 36d2ff17d3f..d0335498044 100644 --- a/bsp/stm32/stm32f429-atk-apollo/board/board.c +++ b/bsp/stm32/stm32f429-atk-apollo/board/board.c @@ -8,7 +8,8 @@ * 2018-11-7 SummerGift first version */ -#include "board.h" +#include +#include /** System Clock Configuration */ diff --git a/bsp/stm32/stm32f429-atk-apollo/board/board.h b/bsp/stm32/stm32f429-atk-apollo/board/board.h index e07f601b842..a06b3236c9c 100644 --- a/bsp/stm32/stm32f429-atk-apollo/board/board.h +++ b/bsp/stm32/stm32f429-atk-apollo/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f429-fire-challenger/Kconfig b/bsp/stm32/stm32f429-fire-challenger/Kconfig index 79b160b8567..ddc9b196d57 100644 --- a/bsp/stm32/stm32f429-fire-challenger/Kconfig +++ b/bsp/stm32/stm32f429-fire-challenger/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F429IG + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f429-fire-challenger/applications/main.c b/bsp/stm32/stm32f429-fire-challenger/applications/main.c index 27c28e0cb2e..efbc9b6f567 100644 --- a/bsp/stm32/stm32f429-fire-challenger/applications/main.c +++ b/bsp/stm32/stm32f429-fire-challenger/applications/main.c @@ -7,11 +7,15 @@ * Date Author Notes * 2018-11-06 SummerGift first version * 2018-11-19 flybreak add stm32f429-fire-challenger bsp + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PH10 */ #define LED0_PIN GET_PIN(H, 10) diff --git a/bsp/stm32/stm32f429-fire-challenger/board/Kconfig b/bsp/stm32/stm32f429-fire-challenger/board/Kconfig index 36af05fe924..0c68ab1cc9a 100644 --- a/bsp/stm32/stm32f429-fire-challenger/board/Kconfig +++ b/bsp/stm32/stm32f429-fire-challenger/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F429IG - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_USB_TO_USART @@ -241,7 +234,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_LTDC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f429-fire-challenger/board/board.c b/bsp/stm32/stm32f429-fire-challenger/board/board.c index 5ca583d5999..2d1b0661ecc 100644 --- a/bsp/stm32/stm32f429-fire-challenger/board/board.c +++ b/bsp/stm32/stm32f429-fire-challenger/board/board.c @@ -8,7 +8,8 @@ * 2018-11-06 SummerGift first version */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f429-fire-challenger/board/board.h b/bsp/stm32/stm32f429-fire-challenger/board/board.h index 6a205b9393f..9319220119a 100644 --- a/bsp/stm32/stm32f429-fire-challenger/board/board.h +++ b/bsp/stm32/stm32f429-fire-challenger/board/board.h @@ -11,10 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f429-st-disco/.config b/bsp/stm32/stm32f429-st-disco/.config index 81505675088..748b440ca2d 100644 --- a/bsp/stm32/stm32f429-st-disco/.config +++ b/bsp/stm32/stm32f429-st-disco/.config @@ -2,6 +2,7 @@ # Automatically generated file; DO NOT EDIT. # RT-Thread Configuration # +CONFIG_SOC_STM32F429ZI=y # # RT-Thread Kernel @@ -9,8 +10,10 @@ CONFIG_RT_NAME_MAX=8 # CONFIG_RT_USING_ARCH_DATA_TYPE is not set # CONFIG_RT_USING_SMART is not set +# CONFIG_RT_USING_NANO is not set # CONFIG_RT_USING_AMP is not set # CONFIG_RT_USING_SMP is not set +CONFIG_RT_CPUS_NR=1 CONFIG_RT_ALIGN_SIZE=8 # CONFIG_RT_THREAD_PRIORITY_8 is not set CONFIG_RT_THREAD_PRIORITY_32=y @@ -35,7 +38,7 @@ CONFIG_IDLE_THREAD_STACK_SIZE=1024 CONFIG_RT_USING_DEBUG=y CONFIG_RT_DEBUGING_COLOR=y CONFIG_RT_DEBUGING_CONTEXT=y -# CONFIG_RT_DEBUGING_INIT is not set +# CONFIG_RT_DEBUGING_AUTO_INIT is not set # # Inter-Thread communication @@ -46,7 +49,7 @@ CONFIG_RT_USING_EVENT=y CONFIG_RT_USING_MAILBOX=y CONFIG_RT_USING_MESSAGEQUEUE=y # CONFIG_RT_USING_MESSAGEQUEUE_PRIORITY is not set -CONFIG_RT_USING_SIGNALS=y +# CONFIG_RT_USING_SIGNALS is not set # # Memory Management @@ -66,19 +69,15 @@ CONFIG_RT_USING_MEMHEAP_AUTO_BINDING=y # CONFIG_RT_USING_MEMTRACE is not set # CONFIG_RT_USING_HEAP_ISR is not set CONFIG_RT_USING_HEAP=y - -# -# Kernel Device Object -# CONFIG_RT_USING_DEVICE=y # CONFIG_RT_USING_DEVICE_OPS is not set -# CONFIG_RT_USING_DM is not set # CONFIG_RT_USING_INTERRUPT_INFO is not set CONFIG_RT_USING_CONSOLE=y CONFIG_RT_CONSOLEBUF_SIZE=128 CONFIG_RT_CONSOLE_DEVICE_NAME="uart1" -CONFIG_RT_VER_NUM=0x50002 +CONFIG_RT_VER_NUM=0x50100 # CONFIG_RT_USING_STDC_ATOMIC is not set +CONFIG_RT_BACKTRACE_LEVEL_MAX_NR=32 # CONFIG_RT_USING_CACHE is not set CONFIG_RT_USING_HW_ATOMIC=y # CONFIG_ARCH_ARM_BOOTWITH_FLUSH_CACHE is not set @@ -137,6 +136,7 @@ CONFIG_RT_USING_DFS_DEVFS=y # # Device Drivers # +# CONFIG_RT_USING_DM is not set CONFIG_RT_USING_DEVICE_IPC=y CONFIG_RT_UNAMED_PIPE_NUMBER=64 # CONFIG_RT_USING_SYSTEM_WORKQUEUE is not set @@ -152,6 +152,7 @@ CONFIG_RT_USING_I2C=y # CONFIG_RT_I2C_DEBUG is not set CONFIG_RT_USING_I2C_BITOPS=y # CONFIG_RT_I2C_BITOPS_DEBUG is not set +# CONFIG_RT_USING_SOFT_I2C is not set # CONFIG_RT_USING_PHY is not set CONFIG_RT_USING_PIN=y # CONFIG_RT_USING_ADC is not set @@ -163,7 +164,6 @@ CONFIG_RT_USING_PIN=y # CONFIG_RT_USING_MTD_NOR is not set # CONFIG_RT_USING_MTD_NAND is not set # CONFIG_RT_USING_PM is not set -# CONFIG_RT_USING_FDT is not set # CONFIG_RT_USING_RTC is not set # CONFIG_RT_USING_SDIO is not set CONFIG_RT_USING_SPI=y @@ -240,6 +240,12 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_RT_USING_LWIP is not set # CONFIG_RT_USING_AT is not set +# +# Memory protection +# +# CONFIG_RT_USING_MEM_PROTECTION is not set +# CONFIG_RT_USING_HW_STACK_GUARD is not set + # # Utilities # @@ -292,6 +298,11 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # # CONFIG_PKG_USING_WLAN_WICED is not set # CONFIG_PKG_USING_RW007 is not set + +# +# CYW43012 WiFi +# +# CONFIG_PKG_USING_WLAN_CYW43012 is not set # CONFIG_PKG_USING_COAP is not set # CONFIG_PKG_USING_NOPOLL is not set # CONFIG_PKG_USING_NETUTILS is not set @@ -353,6 +364,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_ZFTP is not set # CONFIG_PKG_USING_WOL is not set # CONFIG_PKG_USING_ZEPHYR_POLLING is not set +# CONFIG_PKG_USING_MATTER_ADAPTATION_LAYER is not set # # security packages @@ -399,7 +411,6 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # LVGL: powerful and easy-to-use embedded GUI library # # CONFIG_PKG_USING_LVGL is not set -# CONFIG_PKG_USING_LITTLEVGL2RTT is not set # CONFIG_PKG_USING_LV_MUSIC_DEMO is not set # CONFIG_PKG_USING_GUI_GUIDER_DEMO is not set @@ -476,6 +487,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_ARMV7M_DWT_TOOL is not set # CONFIG_PKG_USING_VOFA_PLUS is not set # CONFIG_PKG_USING_RT_TRACE is not set +# CONFIG_PKG_USING_ZDEBUG is not set # # system packages @@ -512,6 +524,8 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_UC_COMMON is not set # CONFIG_PKG_USING_UC_MODBUS is not set # CONFIG_PKG_USING_FREERTOS_WRAPPER is not set +# CONFIG_PKG_USING_LITEOS_SDK is not set +# CONFIG_PKG_USING_TZ_DATABASE is not set # CONFIG_PKG_USING_CAIRO is not set # CONFIG_PKG_USING_PIXMAN is not set # CONFIG_PKG_USING_PARTITION is not set @@ -535,6 +549,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_QBOOT is not set # CONFIG_PKG_USING_PPOOL is not set # CONFIG_PKG_USING_OPENAMP is not set +# CONFIG_PKG_USING_RPMSG_LITE is not set # CONFIG_PKG_USING_LPM is not set # CONFIG_PKG_USING_TLSF is not set # CONFIG_PKG_USING_EVENT_RECORDER is not set @@ -548,6 +563,8 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_AGILE_UPGRADE is not set # CONFIG_PKG_USING_FLASH_BLOB is not set # CONFIG_PKG_USING_MLIBC is not set +# CONFIG_PKG_USING_TASK_MSG_BUS is not set +# CONFIG_PKG_USING_SFDB is not set # # peripheral libraries and drivers @@ -612,6 +629,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_BALANCE is not set # CONFIG_PKG_USING_SHT2X is not set # CONFIG_PKG_USING_SHT3X is not set +# CONFIG_PKG_USING_SHT4X is not set # CONFIG_PKG_USING_AD7746 is not set # CONFIG_PKG_USING_ADT74XX is not set # CONFIG_PKG_USING_MAX17048 is not set @@ -712,6 +730,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_FINGERPRINT is not set # CONFIG_PKG_USING_BT_ECB02C is not set # CONFIG_PKG_USING_UAT is not set +# CONFIG_PKG_USING_ST7789 is not set # CONFIG_PKG_USING_SPI_TOOLS is not set # @@ -735,6 +754,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # CONFIG_PKG_USING_UKAL is not set # CONFIG_PKG_USING_DIGITALCTRL is not set # CONFIG_PKG_USING_KISSFFT is not set +# CONFIG_PKG_USING_CMSIS_DSP is not set # # miscellaneous packages @@ -957,6 +977,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # # CONFIG_PKG_USING_ARDUINO_ADAFRUIT_GFX_LIBRARY is not set # CONFIG_PKG_USING_ARDUINO_U8G2 is not set +# CONFIG_PKG_USING_ARDUINO_TFT_ESPI is not set # CONFIG_PKG_USING_ARDUINO_ADAFRUIT_ST7735 is not set # CONFIG_PKG_USING_ARDUINO_ADAFRUIT_SSD1306 is not set # CONFIG_PKG_USING_ARDUINO_ADAFRUIT_ILI9341 is not set @@ -965,6 +986,7 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # # Timing # +# CONFIG_PKG_USING_ARDUINO_RTCLIB is not set # CONFIG_PKG_USING_ARDUINO_MSTIMER2 is not set # CONFIG_PKG_USING_ARDUINO_TICKER is not set # CONFIG_PKG_USING_ARDUINO_TASKSCHEDULER is not set @@ -1001,7 +1023,6 @@ CONFIG_RT_LIBC_TZ_DEFAULT_SEC=0 # # CONFIG_PKG_USING_ARDUINO_ADAFRUIT_MFRC630 is not set # CONFIG_PKG_USING_ARDUINO_ADAFRUIT_SI5351 is not set -# CONFIG_PKG_USING_ARDUINO_RTCLIB is not set # # Signal IO @@ -1024,7 +1045,6 @@ CONFIG_SOC_SERIES_STM32F4=y # # Hardware Drivers Config # -CONFIG_SOC_STM32F429ZI=y # # Onboard Peripheral Drivers diff --git a/bsp/stm32/stm32f429-st-disco/Kconfig b/bsp/stm32/stm32f429-st-disco/Kconfig index 79b160b8567..75d6a77aaec 100644 --- a/bsp/stm32/stm32f429-st-disco/Kconfig +++ b/bsp/stm32/stm32f429-st-disco/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F429ZI + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f429-st-disco/applications/main.c b/bsp/stm32/stm32f429-st-disco/applications/main.c index 48f43fd6faa..f54c7c566ed 100644 --- a/bsp/stm32/stm32f429-st-disco/applications/main.c +++ b/bsp/stm32/stm32f429-st-disco/applications/main.c @@ -7,11 +7,15 @@ * Date Author Notes * 2018-11-06 SummerGift first version * 2019-10-19 xuzhuoyi add stm32f429-st-disco bsp + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED1 pin: PG13 */ #define LED1_PIN GET_PIN(G, 13) diff --git a/bsp/stm32/stm32f429-st-disco/board/Kconfig b/bsp/stm32/stm32f429-st-disco/board/Kconfig index fddfaa96161..fcec182d7f7 100644 --- a/bsp/stm32/stm32f429-st-disco/board/Kconfig +++ b/bsp/stm32/stm32f429-st-disco/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F429ZI - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_SDRAM @@ -111,7 +104,7 @@ menu "On-chip Peripheral Drivers" select BSP_USING_LCD default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f429-st-disco/board/board.c b/bsp/stm32/stm32f429-st-disco/board/board.c index 542681ae0b3..190b6f79da4 100644 --- a/bsp/stm32/stm32f429-st-disco/board/board.c +++ b/bsp/stm32/stm32f429-st-disco/board/board.c @@ -9,7 +9,8 @@ * 2019-10-13 xuzhuoyi add stm32f429-st-disco bsp */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f429-st-disco/board/board.h b/bsp/stm32/stm32f429-st-disco/board/board.h index 650b64a256a..94098c6b97b 100644 --- a/bsp/stm32/stm32f429-st-disco/board/board.h +++ b/bsp/stm32/stm32f429-st-disco/board/board.h @@ -12,10 +12,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f429-st-disco/rtconfig.h b/bsp/stm32/stm32f429-st-disco/rtconfig.h index b41db94443d..6ba035c9d0b 100644 --- a/bsp/stm32/stm32f429-st-disco/rtconfig.h +++ b/bsp/stm32/stm32f429-st-disco/rtconfig.h @@ -4,9 +4,12 @@ /* Automatically generated file; DO NOT EDIT. */ /* RT-Thread Configuration */ +#define SOC_STM32F429ZI + /* RT-Thread Kernel */ #define RT_NAME_MAX 8 +#define RT_CPUS_NR 1 #define RT_ALIGN_SIZE 8 #define RT_THREAD_PRIORITY_32 #define RT_THREAD_PRIORITY_MAX 32 @@ -31,7 +34,6 @@ #define RT_USING_EVENT #define RT_USING_MAILBOX #define RT_USING_MESSAGEQUEUE -#define RT_USING_SIGNALS /* Memory Management */ @@ -41,14 +43,12 @@ #define RT_USING_MEMHEAP_AS_HEAP #define RT_USING_MEMHEAP_AUTO_BINDING #define RT_USING_HEAP - -/* Kernel Device Object */ - #define RT_USING_DEVICE #define RT_USING_CONSOLE #define RT_CONSOLEBUF_SIZE 128 #define RT_CONSOLE_DEVICE_NAME "uart1" -#define RT_VER_NUM 0x50002 +#define RT_VER_NUM 0x50100 +#define RT_BACKTRACE_LEVEL_MAX_NR 32 #define RT_USING_HW_ATOMIC #define RT_USING_CPU_FFS #define ARCH_ARM @@ -126,6 +126,9 @@ /* Network */ +/* Memory protection */ + + /* Utilities */ @@ -145,6 +148,9 @@ /* Wiced WiFi */ +/* CYW43012 WiFi */ + + /* IoT Cloud */ @@ -250,8 +256,6 @@ /* Hardware Drivers Config */ -#define SOC_STM32F429ZI - /* Onboard Peripheral Drivers */ #define BSP_USING_SDRAM diff --git a/bsp/stm32/stm32f446-st-nucleo/Kconfig b/bsp/stm32/stm32f446-st-nucleo/Kconfig index 79b160b8567..dca75b1339d 100644 --- a/bsp/stm32/stm32f446-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f446-st-nucleo/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F446ZE + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f446-st-nucleo/applications/main.c b/bsp/stm32/stm32f446-st-nucleo/applications/main.c index b419a794498..48cb8396229 100644 --- a/bsp/stm32/stm32f446-st-nucleo/applications/main.c +++ b/bsp/stm32/stm32f446-st-nucleo/applications/main.c @@ -6,11 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED2 pin: PB7 */ #define LED2_PIN GET_PIN(B, 7) diff --git a/bsp/stm32/stm32f446-st-nucleo/board/Kconfig b/bsp/stm32/stm32f446-st-nucleo/board/Kconfig index 99d45bee623..02063a9a7f2 100644 --- a/bsp/stm32/stm32f446-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f446-st-nucleo/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F446ZE - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" endmenu @@ -32,7 +25,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f446-st-nucleo/board/board.c b/bsp/stm32/stm32f446-st-nucleo/board/board.c index a2500ee68a0..825f68bd10c 100644 --- a/bsp/stm32/stm32f446-st-nucleo/board/board.c +++ b/bsp/stm32/stm32f446-st-nucleo/board/board.c @@ -9,7 +9,8 @@ * 2019-01-08 AndeyQi add stm32f446-st-nucleo bsp */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f446-st-nucleo/board/board.h b/bsp/stm32/stm32f446-st-nucleo/board/board.h index 3da6cda6d20..96803437ce0 100644 --- a/bsp/stm32/stm32f446-st-nucleo/board/board.h +++ b/bsp/stm32/stm32f446-st-nucleo/board/board.h @@ -12,10 +12,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #define STM32_FLASH_START_ADRESS ((uint32_t)0x08000000) #define STM32_FLASH_SIZE (512 * 1024) diff --git a/bsp/stm32/stm32f469-st-disco/Kconfig b/bsp/stm32/stm32f469-st-disco/Kconfig index 79b160b8567..f8ff75a689f 100644 --- a/bsp/stm32/stm32f469-st-disco/Kconfig +++ b/bsp/stm32/stm32f469-st-disco/Kconfig @@ -15,7 +15,17 @@ config PKGS_DIR option env="PKGS_ROOT" default "packages" +config SOC_STM32F469NI + bool + select SOC_SERIES_STM32F4 + select RT_USING_COMPONENTS_INIT + select RT_USING_USER_MAIN + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f469-st-disco/applications/main.c b/bsp/stm32/stm32f469-st-disco/applications/main.c index e5a331ad8c7..4f54207460b 100644 --- a/bsp/stm32/stm32f469-st-disco/applications/main.c +++ b/bsp/stm32/stm32f469-st-disco/applications/main.c @@ -5,13 +5,16 @@ * * Change Logs: * Date Author Notes - * 2018-11-06 SummerGift first version - * 2019-04-09 WillianChan add stm32f469-st-disco bsp + * 2019-04-09 WillianChan first version + * 2023-12-03 Meco Man support nano version */ +#include #include +#include +#ifndef RT_USING_NANO #include -#include +#endif /* RT_USING_NANO */ /* defined the LED1 pin: PG6 */ #define LED1_PIN GET_PIN(G, 6) diff --git a/bsp/stm32/stm32f469-st-disco/board/Kconfig b/bsp/stm32/stm32f469-st-disco/board/Kconfig index 6eea01cadb5..c96f12bc91b 100644 --- a/bsp/stm32/stm32f469-st-disco/board/Kconfig +++ b/bsp/stm32/stm32f469-st-disco/board/Kconfig @@ -1,12 +1,5 @@ menu "Hardware Drivers Config" -config SOC_STM32F469NI - bool - select SOC_SERIES_STM32F4 - select RT_USING_COMPONENTS_INIT - select RT_USING_USER_MAIN - default y - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART bool "Enable STLINK TO USART (uart3)" @@ -261,7 +254,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_LTDC bool "Enable LTDC" default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f469-st-disco/board/board.c b/bsp/stm32/stm32f469-st-disco/board/board.c index fefb07fafd6..e9dced29f69 100644 --- a/bsp/stm32/stm32f469-st-disco/board/board.c +++ b/bsp/stm32/stm32f469-st-disco/board/board.c @@ -9,7 +9,8 @@ * 2019-04-09 WillianChan add stm32f469-st-disco bsp */ -#include "board.h" +#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32f469-st-disco/board/board.h b/bsp/stm32/stm32f469-st-disco/board/board.h index 14f3a6f0373..d098d80c30d 100644 --- a/bsp/stm32/stm32f469-st-disco/board/board.h +++ b/bsp/stm32/stm32f469-st-disco/board/board.h @@ -12,10 +12,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include "drv_common.h" -#include "drv_gpio.h" #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32f723-st-disco/Kconfig b/bsp/stm32/stm32f723-st-disco/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32f723-st-disco/Kconfig +++ b/bsp/stm32/stm32f723-st-disco/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f723-st-disco/board/Kconfig b/bsp/stm32/stm32f723-st-disco/board/Kconfig index be3f9ab747b..f77c9ec8d9c 100644 --- a/bsp/stm32/stm32f723-st-disco/board/Kconfig +++ b/bsp/stm32/stm32f723-st-disco/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default y endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f746-st-disco/Kconfig b/bsp/stm32/stm32f746-st-disco/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32f746-st-disco/Kconfig +++ b/bsp/stm32/stm32f746-st-disco/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f746-st-disco/board/Kconfig b/bsp/stm32/stm32f746-st-disco/board/Kconfig index bcef1eb3397..b5519dace33 100644 --- a/bsp/stm32/stm32f746-st-disco/board/Kconfig +++ b/bsp/stm32/stm32f746-st-disco/board/Kconfig @@ -109,7 +109,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_LTDC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f746-st-nucleo/Kconfig b/bsp/stm32/stm32f746-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32f746-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f746-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f746-st-nucleo/board/Kconfig b/bsp/stm32/stm32f746-st-nucleo/board/Kconfig index 78ea3494a2c..df051d13623 100644 --- a/bsp/stm32/stm32f746-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f746-st-nucleo/board/Kconfig @@ -241,7 +241,7 @@ menu "On-chip Peripheral Drivers" int "USB PULL UP STATUS" default 0 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f767-atk-apollo/Kconfig b/bsp/stm32/stm32f767-atk-apollo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32f767-atk-apollo/Kconfig +++ b/bsp/stm32/stm32f767-atk-apollo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f767-atk-apollo/board/Kconfig b/bsp/stm32/stm32f767-atk-apollo/board/Kconfig index f47878e9904..e337a094280 100644 --- a/bsp/stm32/stm32f767-atk-apollo/board/Kconfig +++ b/bsp/stm32/stm32f767-atk-apollo/board/Kconfig @@ -255,7 +255,7 @@ menu "On-chip Peripheral Drivers" bool "Enable LTDC" default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f767-fire-challenger-v1/Kconfig b/bsp/stm32/stm32f767-fire-challenger-v1/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32f767-fire-challenger-v1/Kconfig +++ b/bsp/stm32/stm32f767-fire-challenger-v1/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f767-fire-challenger-v1/board/Kconfig b/bsp/stm32/stm32f767-fire-challenger-v1/board/Kconfig index 8b1918684d1..fc0562c09ca 100644 --- a/bsp/stm32/stm32f767-fire-challenger-v1/board/Kconfig +++ b/bsp/stm32/stm32f767-fire-challenger-v1/board/Kconfig @@ -175,7 +175,7 @@ menu "On-chip Peripheral Drivers" bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f767-st-nucleo/Kconfig b/bsp/stm32/stm32f767-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32f767-st-nucleo/Kconfig +++ b/bsp/stm32/stm32f767-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f767-st-nucleo/board/Kconfig b/bsp/stm32/stm32f767-st-nucleo/board/Kconfig index 26f22c378aa..3cb7a5ccd1d 100644 --- a/bsp/stm32/stm32f767-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f767-st-nucleo/board/Kconfig @@ -56,7 +56,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART3 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32f769-st-disco/Kconfig b/bsp/stm32/stm32f769-st-disco/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32f769-st-disco/Kconfig +++ b/bsp/stm32/stm32f769-st-disco/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32f769-st-disco/board/Kconfig b/bsp/stm32/stm32f769-st-disco/board/Kconfig index dbb42a1d992..fc6b54dd385 100644 --- a/bsp/stm32/stm32f769-st-disco/board/Kconfig +++ b/bsp/stm32/stm32f769-st-disco/board/Kconfig @@ -74,7 +74,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32g070-st-nucleo/Kconfig b/bsp/stm32/stm32g070-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32g070-st-nucleo/Kconfig +++ b/bsp/stm32/stm32g070-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32g070-st-nucleo/board/Kconfig b/bsp/stm32/stm32g070-st-nucleo/board/Kconfig index 4b7368b1a43..be468b410e3 100644 --- a/bsp/stm32/stm32g070-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32g070-st-nucleo/board/Kconfig @@ -186,7 +186,7 @@ menu "On-chip Peripheral Drivers" bool "Enable Watchdog Timer" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32g071-st-nucleo/Kconfig b/bsp/stm32/stm32g071-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32g071-st-nucleo/Kconfig +++ b/bsp/stm32/stm32g071-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32g071-st-nucleo/board/Kconfig b/bsp/stm32/stm32g071-st-nucleo/board/Kconfig index ee86ae58dc8..f6641f010c7 100644 --- a/bsp/stm32/stm32g071-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32g071-st-nucleo/board/Kconfig @@ -169,7 +169,7 @@ menu "On-chip Peripheral Drivers" bool "Enable Watchdog Timer" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32g431-st-nucleo/Kconfig b/bsp/stm32/stm32g431-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32g431-st-nucleo/Kconfig +++ b/bsp/stm32/stm32g431-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32g431-st-nucleo/board/Kconfig b/bsp/stm32/stm32g431-st-nucleo/board/Kconfig index 1b769221f66..8635d183009 100644 --- a/bsp/stm32/stm32g431-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32g431-st-nucleo/board/Kconfig @@ -59,7 +59,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART4 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32g474-st-nucleo/Kconfig b/bsp/stm32/stm32g474-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32g474-st-nucleo/Kconfig +++ b/bsp/stm32/stm32g474-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32g474-st-nucleo/board/Kconfig b/bsp/stm32/stm32g474-st-nucleo/board/Kconfig index 620f2a1a0a2..0fa184b676d 100644 --- a/bsp/stm32/stm32g474-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32g474-st-nucleo/board/Kconfig @@ -168,7 +168,7 @@ menu "On-chip Peripheral Drivers" default 25 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h563-st-nucleo/Kconfig b/bsp/stm32/stm32h563-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h563-st-nucleo/Kconfig +++ b/bsp/stm32/stm32h563-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h563-st-nucleo/board/Kconfig b/bsp/stm32/stm32h563-st-nucleo/board/Kconfig index a071b60d3eb..6af29c13f27 100644 --- a/bsp/stm32/stm32h563-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32h563-st-nucleo/board/Kconfig @@ -56,7 +56,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h743-armfly-v7/Kconfig b/bsp/stm32/stm32h743-armfly-v7/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h743-armfly-v7/Kconfig +++ b/bsp/stm32/stm32h743-armfly-v7/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h743-armfly-v7/board/Kconfig b/bsp/stm32/stm32h743-armfly-v7/board/Kconfig index 3306a438aef..0dedbb0d589 100644 --- a/bsp/stm32/stm32h743-armfly-v7/board/Kconfig +++ b/bsp/stm32/stm32h743-armfly-v7/board/Kconfig @@ -29,7 +29,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h743-atk-apollo/Kconfig b/bsp/stm32/stm32h743-atk-apollo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h743-atk-apollo/Kconfig +++ b/bsp/stm32/stm32h743-atk-apollo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h743-atk-apollo/board/Kconfig b/bsp/stm32/stm32h743-atk-apollo/board/Kconfig index 03206e5d114..f46f5f79564 100644 --- a/bsp/stm32/stm32h743-atk-apollo/board/Kconfig +++ b/bsp/stm32/stm32h743-atk-apollo/board/Kconfig @@ -197,7 +197,7 @@ menu "On-chip Peripheral Drivers" default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h743-openmv-h7plus/Kconfig b/bsp/stm32/stm32h743-openmv-h7plus/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h743-openmv-h7plus/Kconfig +++ b/bsp/stm32/stm32h743-openmv-h7plus/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h743-openmv-h7plus/board/Kconfig b/bsp/stm32/stm32h743-openmv-h7plus/board/Kconfig index ca3ae90a229..656e2f955aa 100644 --- a/bsp/stm32/stm32h743-openmv-h7plus/board/Kconfig +++ b/bsp/stm32/stm32h743-openmv-h7plus/board/Kconfig @@ -59,7 +59,7 @@ menu "Hardware Drivers Config" select RT_USING_RTC default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h743-st-nucleo/Kconfig b/bsp/stm32/stm32h743-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h743-st-nucleo/Kconfig +++ b/bsp/stm32/stm32h743-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h743-st-nucleo/board/Kconfig b/bsp/stm32/stm32h743-st-nucleo/board/Kconfig index 71a9e6d6fbf..4cf0104dfd8 100644 --- a/bsp/stm32/stm32h743-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32h743-st-nucleo/board/Kconfig @@ -29,7 +29,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h747-st-discovery/Kconfig b/bsp/stm32/stm32h747-st-discovery/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h747-st-discovery/Kconfig +++ b/bsp/stm32/stm32h747-st-discovery/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h747-st-discovery/board/Kconfig b/bsp/stm32/stm32h747-st-discovery/board/Kconfig index eef2a51548c..b7770bbdc8d 100644 --- a/bsp/stm32/stm32h747-st-discovery/board/Kconfig +++ b/bsp/stm32/stm32h747-st-discovery/board/Kconfig @@ -29,7 +29,7 @@ menu "On-chip Peripheral Drivers" endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/Kconfig b/bsp/stm32/stm32h750-armfly-h7-tool/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/Kconfig +++ b/bsp/stm32/stm32h750-armfly-h7-tool/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig b/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig index 98431741e44..ff284c91f4b 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig +++ b/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig @@ -136,7 +136,7 @@ menu "On-chip Peripheral Drivers" select BSP_USBD_PHY_ULPI default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h750-artpi/Kconfig b/bsp/stm32/stm32h750-artpi/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h750-artpi/Kconfig +++ b/bsp/stm32/stm32h750-artpi/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h750-artpi/board/Kconfig b/bsp/stm32/stm32h750-artpi/board/Kconfig index 1d488c446f5..0e1b0972a72 100644 --- a/bsp/stm32/stm32h750-artpi/board/Kconfig +++ b/bsp/stm32/stm32h750-artpi/board/Kconfig @@ -386,7 +386,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_LTDC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h750-fk750m1-vbt6/Kconfig b/bsp/stm32/stm32h750-fk750m1-vbt6/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h750-fk750m1-vbt6/Kconfig +++ b/bsp/stm32/stm32h750-fk750m1-vbt6/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h750-fk750m1-vbt6/board/Kconfig b/bsp/stm32/stm32h750-fk750m1-vbt6/board/Kconfig index d387aa3dd25..43416899bfa 100644 --- a/bsp/stm32/stm32h750-fk750m1-vbt6/board/Kconfig +++ b/bsp/stm32/stm32h750-fk750m1-vbt6/board/Kconfig @@ -114,14 +114,13 @@ menu "On-chip Peripheral Drivers" menuconfig BSP_USING_ONCHIP_RTC bool "Enable RTC" select RT_USING_RTC - select RT_USING_LIBC default n config BSP_USING_ON_CHIP_FLASH bool "Enable on-chip FLASH" default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32h750-weact-ministm32h7xx/Kconfig b/bsp/stm32/stm32h750-weact-ministm32h7xx/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32h750-weact-ministm32h7xx/Kconfig +++ b/bsp/stm32/stm32h750-weact-ministm32h7xx/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32h750-weact-ministm32h7xx/board/Kconfig b/bsp/stm32/stm32h750-weact-ministm32h7xx/board/Kconfig index 55e845bd642..ae3e8fabc50 100644 --- a/bsp/stm32/stm32h750-weact-ministm32h7xx/board/Kconfig +++ b/bsp/stm32/stm32h750-weact-ministm32h7xx/board/Kconfig @@ -176,7 +176,7 @@ menu "On-chip Peripheral Drivers" select BSP_USBD_PHY_ULPI default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l010-st-nucleo/Kconfig b/bsp/stm32/stm32l010-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l010-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l010-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l010-st-nucleo/board/Kconfig b/bsp/stm32/stm32l010-st-nucleo/board/Kconfig index 4946a219473..9861ceec785 100644 --- a/bsp/stm32/stm32l010-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l010-st-nucleo/board/Kconfig @@ -37,7 +37,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l053-st-nucleo/Kconfig b/bsp/stm32/stm32l053-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l053-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l053-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l053-st-nucleo/board/Kconfig b/bsp/stm32/stm32l053-st-nucleo/board/Kconfig index b086dbff9ba..bde022d45b4 100644 --- a/bsp/stm32/stm32l053-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l053-st-nucleo/board/Kconfig @@ -38,7 +38,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART2 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l412-st-nucleo/Kconfig b/bsp/stm32/stm32l412-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l412-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l412-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l412-st-nucleo/board/Kconfig b/bsp/stm32/stm32l412-st-nucleo/board/Kconfig index ec1cba23e28..34604a52f53 100644 --- a/bsp/stm32/stm32l412-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l412-st-nucleo/board/Kconfig @@ -62,7 +62,7 @@ menu "On-chip Peripheral Drivers" bool "Enable Watchdog Timer" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l431-BearPi/Kconfig b/bsp/stm32/stm32l431-BearPi/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l431-BearPi/Kconfig +++ b/bsp/stm32/stm32l431-BearPi/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l431-BearPi/board/Kconfig b/bsp/stm32/stm32l431-BearPi/board/Kconfig index c5bde336d1d..d9f3761b071 100644 --- a/bsp/stm32/stm32l431-BearPi/board/Kconfig +++ b/bsp/stm32/stm32l431-BearPi/board/Kconfig @@ -148,7 +148,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l432-st-nucleo/Kconfig b/bsp/stm32/stm32l432-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l432-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l432-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l432-st-nucleo/board/Kconfig b/bsp/stm32/stm32l432-st-nucleo/board/Kconfig index fcc0a9ffa64..645582c8b02 100644 --- a/bsp/stm32/stm32l432-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l432-st-nucleo/board/Kconfig @@ -62,7 +62,7 @@ menu "On-chip Peripheral Drivers" bool "Enable Watchdog Timer" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l433-ali-startkit/Kconfig b/bsp/stm32/stm32l433-ali-startkit/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l433-ali-startkit/Kconfig +++ b/bsp/stm32/stm32l433-ali-startkit/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l433-ali-startkit/board/Kconfig b/bsp/stm32/stm32l433-ali-startkit/board/Kconfig index 8b88d1f6b39..d4a0f6c5ddf 100644 --- a/bsp/stm32/stm32l433-ali-startkit/board/Kconfig +++ b/bsp/stm32/stm32l433-ali-startkit/board/Kconfig @@ -220,7 +220,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l433-st-nucleo/Kconfig b/bsp/stm32/stm32l433-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l433-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l433-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l433-st-nucleo/board/Kconfig b/bsp/stm32/stm32l433-st-nucleo/board/Kconfig index e0652e11b8f..0fb450304e9 100644 --- a/bsp/stm32/stm32l433-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l433-st-nucleo/board/Kconfig @@ -84,7 +84,7 @@ menu "On-chip Peripheral Drivers" endchoice endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l452-st-nucleo/Kconfig b/bsp/stm32/stm32l452-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l452-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l452-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l452-st-nucleo/board/Kconfig b/bsp/stm32/stm32l452-st-nucleo/board/Kconfig index 6672d209b90..2470c20b36b 100644 --- a/bsp/stm32/stm32l452-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l452-st-nucleo/board/Kconfig @@ -81,7 +81,7 @@ menu "On-chip Peripheral Drivers" range 1 176 default 16 endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l475-atk-pandora/Kconfig b/bsp/stm32/stm32l475-atk-pandora/Kconfig index 18ee161f555..586c8dc4289 100644 --- a/bsp/stm32/stm32l475-atk-pandora/Kconfig +++ b/bsp/stm32/stm32l475-atk-pandora/Kconfig @@ -22,10 +22,14 @@ config SOC_STM32L475VE select RT_USING_USER_MAIN default y +config BOARD_STM32L475_ATK_PANDORA + bool + default y + source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" +source "../libraries/Kconfig" if !RT_USING_NANO -source "../libraries/Kconfig" source "board/Kconfig" endif diff --git a/bsp/stm32/stm32l475-atk-pandora/applications/main.c b/bsp/stm32/stm32l475-atk-pandora/applications/main.c index 7ff30d00595..87a18eaf441 100644 --- a/bsp/stm32/stm32l475-atk-pandora/applications/main.c +++ b/bsp/stm32/stm32l475-atk-pandora/applications/main.c @@ -6,13 +6,15 @@ * Change Logs: * Date Author Notes * 2018-11-06 SummerGift first version + * 2023-12-03 Meco Man support nano version */ -#include #include - +#include +#include #ifndef RT_USING_NANO #include +#endif /* RT_USING_NANO */ /* defined the LED0 pin: PE7 */ #define LED0_PIN GET_PIN(E, 7) @@ -30,28 +32,4 @@ int main(void) rt_thread_mdelay(500); } } -#else -int main(void) -{ - GPIO_InitTypeDef GPIO_InitStruct = {0}; - - /* GPIO Ports Clock Enable */ - __HAL_RCC_GPIOE_CLK_ENABLE(); - - /*Configure GPIO pin Output Level */ - HAL_GPIO_WritePin(GPIOE, GPIO_PIN_7, GPIO_PIN_SET); - /*Configure GPIO pin : PE7 */ - GPIO_InitStruct.Pin = GPIO_PIN_7; - GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP; - GPIO_InitStruct.Pull = GPIO_PULLUP; - GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_MEDIUM; - HAL_GPIO_Init(GPIOE, &GPIO_InitStruct); - - while (1) - { - HAL_GPIO_TogglePin(GPIOE, GPIO_PIN_7); - rt_thread_mdelay(500); - } -} -#endif /* RT_USING_NANO */ diff --git a/bsp/stm32/stm32l475-atk-pandora/board/Kconfig b/bsp/stm32/stm32l475-atk-pandora/board/Kconfig index 0bc4844a117..659408da4f1 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/Kconfig +++ b/bsp/stm32/stm32l475-atk-pandora/board/Kconfig @@ -1,9 +1,5 @@ menu "Hardware Drivers Config" -config BOARD_STM32L475_ATK_PANDORA - bool - default y - menu "Onboard Peripheral Drivers" config BSP_USING_STLINK_TO_USART @@ -576,7 +572,7 @@ menu "On-chip Peripheral Drivers" BSP_USING_STM32_SDIO use drv_sdio_adapter.c,and BSP_USING_SDIO use drv_sdio.c - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l475-atk-pandora/board/SConscript b/bsp/stm32/stm32l475-atk-pandora/board/SConscript index e1deb74ee5d..bf886a10dbe 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/SConscript +++ b/bsp/stm32/stm32l475-atk-pandora/board/SConscript @@ -43,8 +43,6 @@ if not GetDepend(['RT_USING_NANO']): if GetDepend(['BSP_USING_AUDIO']): path += [cwd + os.path.join('ports', 'audio')] -else: - src += [os.path.join('nano', 'drv_console.c')] startup_path_prefix = SDK_LIB diff --git a/bsp/stm32/stm32l475-atk-pandora/board/board.c b/bsp/stm32/stm32l475-atk-pandora/board/board.c index 17f1f410102..183c61401a4 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/board.c +++ b/bsp/stm32/stm32l475-atk-pandora/board/board.c @@ -5,12 +5,11 @@ * * Change Logs: * Date Author Notes - * 2009-01-05 Bernard first implementation * 2019-05-09 Zero-Free Adding multiple configurations for system clock frequency */ #include -#include +#include void SystemClock_Config(void) { diff --git a/bsp/stm32/stm32l475-atk-pandora/board/board.h b/bsp/stm32/stm32l475-atk-pandora/board/board.h index 410d3155e6c..c554ff60a24 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/board.h +++ b/bsp/stm32/stm32l475-atk-pandora/board/board.h @@ -11,12 +11,7 @@ #ifndef __BOARD_H__ #define __BOARD_H__ -#include #include -#include -#ifndef RT_USING_NANO -#include -#endif /* RT_USING_NANO */ #ifdef __cplusplus extern "C" { diff --git a/bsp/stm32/stm32l475-atk-pandora/board/nano/drv_console.c b/bsp/stm32/stm32l475-atk-pandora/board/nano/drv_console.c deleted file mode 100644 index 95a77342277..00000000000 --- a/bsp/stm32/stm32l475-atk-pandora/board/nano/drv_console.c +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright (c) 2006-2021, RT-Thread Development Team - * - * SPDX-License-Identifier: Apache-2.0 - * - * Change Logs: - * Date Author Notes - * 2023-11-30 Meco Man First version - */ - -#include - -UART_HandleTypeDef huart1; - -void rt_hw_console_init(void) -{ - huart1.Instance = USART1; - huart1.Init.BaudRate = 115200; - huart1.Init.WordLength = UART_WORDLENGTH_8B; - huart1.Init.StopBits = UART_STOPBITS_1; - huart1.Init.Parity = UART_PARITY_NONE; - huart1.Init.Mode = UART_MODE_TX_RX; - huart1.Init.HwFlowCtl = UART_HWCONTROL_NONE; - huart1.Init.OverSampling = UART_OVERSAMPLING_16; - huart1.Init.OneBitSampling = UART_ONE_BIT_SAMPLE_DISABLE; - huart1.AdvancedInit.AdvFeatureInit = UART_ADVFEATURE_NO_INIT; - if (HAL_UART_Init(&huart1) != HAL_OK) - { - Error_Handler(); - } -} - -void rt_hw_console_output(const char *str) -{ - rt_size_t i = 0, size = 0; - char a = '\r'; - - __HAL_UNLOCK(&huart1); - - size = rt_strlen(str); - for (i = 0; i < size; i++) - { - if (*(str + i) == '\n') - { - HAL_UART_Transmit(&huart1, (uint8_t *)&a, 1, 1); - } - HAL_UART_Transmit(&huart1, (uint8_t *)(str + i), 1, 1); - } -} - -char rt_hw_console_getchar(void) -{ - int ch = -1; - - if (__HAL_UART_GET_FLAG(&huart1, UART_FLAG_RXNE) != RESET) - { - ch = huart1.Instance->RDR & 0xff; - } - else - { - rt_thread_mdelay(10); - } - return ch; -} diff --git a/bsp/stm32/stm32l475-st-discovery/Kconfig b/bsp/stm32/stm32l475-st-discovery/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l475-st-discovery/Kconfig +++ b/bsp/stm32/stm32l475-st-discovery/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l475-st-discovery/board/Kconfig b/bsp/stm32/stm32l475-st-discovery/board/Kconfig index c3da67a5f40..0c695f75204 100644 --- a/bsp/stm32/stm32l475-st-discovery/board/Kconfig +++ b/bsp/stm32/stm32l475-st-discovery/board/Kconfig @@ -32,7 +32,7 @@ menu "On-chip Peripheral Drivers" depends on BSP_USING_UART1 && RT_SERIAL_USING_DMA default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l476-st-nucleo/Kconfig b/bsp/stm32/stm32l476-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l476-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l476-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l476-st-nucleo/board/Kconfig b/bsp/stm32/stm32l476-st-nucleo/board/Kconfig index 3f329322ab5..d0eee73a109 100644 --- a/bsp/stm32/stm32l476-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l476-st-nucleo/board/Kconfig @@ -269,7 +269,7 @@ menu "On-chip Peripheral Drivers" endchoice endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l496-ali-developer/Kconfig b/bsp/stm32/stm32l496-ali-developer/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l496-ali-developer/Kconfig +++ b/bsp/stm32/stm32l496-ali-developer/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l496-ali-developer/board/Kconfig b/bsp/stm32/stm32l496-ali-developer/board/Kconfig index bfe1551a06f..1b21530b7c5 100644 --- a/bsp/stm32/stm32l496-ali-developer/board/Kconfig +++ b/bsp/stm32/stm32l496-ali-developer/board/Kconfig @@ -228,7 +228,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_WDT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l496-st-discovery/Kconfig b/bsp/stm32/stm32l496-st-discovery/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l496-st-discovery/Kconfig +++ b/bsp/stm32/stm32l496-st-discovery/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l496-st-discovery/board/Kconfig b/bsp/stm32/stm32l496-st-discovery/board/Kconfig index 78f4a0f51d6..8ab426c1103 100644 --- a/bsp/stm32/stm32l496-st-discovery/board/Kconfig +++ b/bsp/stm32/stm32l496-st-discovery/board/Kconfig @@ -37,7 +37,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l496-st-nucleo/Kconfig b/bsp/stm32/stm32l496-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l496-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l496-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l496-st-nucleo/board/Kconfig b/bsp/stm32/stm32l496-st-nucleo/board/Kconfig index 0ed4a9cefd6..82c8aad1e19 100644 --- a/bsp/stm32/stm32l496-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l496-st-nucleo/board/Kconfig @@ -285,7 +285,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_DFS_ELMFAT default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l4r5-st-nucleo/Kconfig b/bsp/stm32/stm32l4r5-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l4r5-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l4r5-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l4r9-st-eval/Kconfig b/bsp/stm32/stm32l4r9-st-eval/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l4r9-st-eval/Kconfig +++ b/bsp/stm32/stm32l4r9-st-eval/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l4r9-st-eval/board/Kconfig b/bsp/stm32/stm32l4r9-st-eval/board/Kconfig index c1cceb57a5f..e38e6eb96ac 100644 --- a/bsp/stm32/stm32l4r9-st-eval/board/Kconfig +++ b/bsp/stm32/stm32l4r9-st-eval/board/Kconfig @@ -90,7 +90,7 @@ menu "On-chip Peripheral Drivers" config BSP_USING_FMC bool default n - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l4r9-st-sensortile-box/Kconfig b/bsp/stm32/stm32l4r9-st-sensortile-box/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l4r9-st-sensortile-box/Kconfig +++ b/bsp/stm32/stm32l4r9-st-sensortile-box/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l4r9-st-sensortile-box/board/Kconfig b/bsp/stm32/stm32l4r9-st-sensortile-box/board/Kconfig index ae62ce437fd..709a2d1ad47 100644 --- a/bsp/stm32/stm32l4r9-st-sensortile-box/board/Kconfig +++ b/bsp/stm32/stm32l4r9-st-sensortile-box/board/Kconfig @@ -31,7 +31,7 @@ menu "On-chip Peripheral Drivers" default y - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32l552-st-nucleo/Kconfig b/bsp/stm32/stm32l552-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32l552-st-nucleo/Kconfig +++ b/bsp/stm32/stm32l552-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32l552-st-nucleo/board/Kconfig b/bsp/stm32/stm32l552-st-nucleo/board/Kconfig index cb91e5e4469..4bcfb716af5 100644 --- a/bsp/stm32/stm32l552-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32l552-st-nucleo/board/Kconfig @@ -33,7 +33,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32mp157a-st-discovery/Kconfig b/bsp/stm32/stm32mp157a-st-discovery/Kconfig index 7a400db91f4..1b639d65a79 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/Kconfig +++ b/bsp/stm32/stm32mp157a-st-discovery/Kconfig @@ -18,5 +18,8 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig b/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig index 4c7665b1673..ae00b7a4f7a 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig +++ b/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig @@ -291,7 +291,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32mp157a-st-ev1/Kconfig b/bsp/stm32/stm32mp157a-st-ev1/Kconfig index 7a400db91f4..1b639d65a79 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/Kconfig +++ b/bsp/stm32/stm32mp157a-st-ev1/Kconfig @@ -18,5 +18,8 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig b/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig index 35a8ec35a91..45748392634 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig +++ b/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig @@ -328,7 +328,7 @@ menu "On-chip Peripheral Drivers" default n endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32u575-st-nucleo/Kconfig b/bsp/stm32/stm32u575-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32u575-st-nucleo/Kconfig +++ b/bsp/stm32/stm32u575-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32u575-st-nucleo/board/Kconfig b/bsp/stm32/stm32u575-st-nucleo/board/Kconfig index 3d6d5b29a1b..813d5eb97b8 100644 --- a/bsp/stm32/stm32u575-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32u575-st-nucleo/board/Kconfig @@ -197,7 +197,7 @@ menu "On-chip Peripheral Drivers" endif endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32u585-iot02a/Kconfig b/bsp/stm32/stm32u585-iot02a/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32u585-iot02a/Kconfig +++ b/bsp/stm32/stm32u585-iot02a/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32u585-iot02a/board/Kconfig b/bsp/stm32/stm32u585-iot02a/board/Kconfig index 7bc7e1ebf10..995dfbc7e02 100644 --- a/bsp/stm32/stm32u585-iot02a/board/Kconfig +++ b/bsp/stm32/stm32u585-iot02a/board/Kconfig @@ -25,7 +25,7 @@ menu "On-chip Peripheral Drivers" default y endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32wb55-st-nucleo/Kconfig b/bsp/stm32/stm32wb55-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32wb55-st-nucleo/Kconfig +++ b/bsp/stm32/stm32wb55-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32wb55-st-nucleo/board/Kconfig b/bsp/stm32/stm32wb55-st-nucleo/board/Kconfig index 806100aca1e..dde7b3fca31 100644 --- a/bsp/stm32/stm32wb55-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32wb55-st-nucleo/board/Kconfig @@ -157,7 +157,7 @@ menu "On-chip Peripheral Drivers" endchoice endif - source "../libraries/HAL_Drivers/Kconfig" + source "$BSP_DIR/../libraries/HAL_Drivers/drivers/Kconfig" endmenu diff --git a/bsp/stm32/stm32wl55-st-nucleo/Kconfig b/bsp/stm32/stm32wl55-st-nucleo/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32wl55-st-nucleo/Kconfig +++ b/bsp/stm32/stm32wl55-st-nucleo/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32wle5-yizhilian-lm401/Kconfig b/bsp/stm32/stm32wle5-yizhilian-lm401/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32wle5-yizhilian-lm401/Kconfig +++ b/bsp/stm32/stm32wle5-yizhilian-lm401/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif diff --git a/bsp/stm32/stm32wle5-yizhilian-lm402/Kconfig b/bsp/stm32/stm32wle5-yizhilian-lm402/Kconfig index 79b160b8567..362bdfbed87 100644 --- a/bsp/stm32/stm32wle5-yizhilian-lm402/Kconfig +++ b/bsp/stm32/stm32wle5-yizhilian-lm402/Kconfig @@ -18,4 +18,7 @@ config PKGS_DIR source "$RTT_DIR/Kconfig" source "$PKGS_DIR/Kconfig" source "../libraries/Kconfig" + +if !RT_USING_NANO source "board/Kconfig" +endif