From 81e5fa061f3d6ba37896615ac06ae0c7adae4f89 Mon Sep 17 00:00:00 2001 From: "Man, Jianting (Meco)" <920369182@qq.com> Date: Mon, 21 Mar 2022 10:04:37 -0400 Subject: [PATCH] [stm32f072 nucleo] support pwm for arduino (#5693) --- .../apm32f103xe-minibroard/board/Kconfig | 2 +- bsp/hc32f4a0/board/Kconfig | 4 +- .../HAL_Drivers/config/f0/pwm_config.h | 24 ++- bsp/stm32/libraries/HAL_Drivers/drv_pwm.c | 6 + .../templates/stm32l1xx/board/Kconfig | 4 +- .../applications/arduino/pins_arduino.c | 4 +- .../board/CubeMX_Config/.mxproject | 4 +- .../board/CubeMX_Config/CubeMX_Config.ioc | 55 +++++-- .../board/CubeMX_Config/Inc/main.h | 2 - .../CubeMX_Config/Inc/stm32f0xx_hal_conf.h | 87 +++++----- .../board/CubeMX_Config/Inc/stm32f0xx_it.h | 2 - .../board/CubeMX_Config/Src/main.c | 154 +++++++++++++++++- .../CubeMX_Config/Src/stm32f0xx_hal_msp.c | 90 +++++++++- .../board/CubeMX_Config/Src/stm32f0xx_it.c | 1 - bsp/stm32/stm32f072-st-nucleo/board/Kconfig | 30 +++- bsp/stm32/stm32f091-st-nucleo/board/Kconfig | 4 +- bsp/stm32/stm32f103-atk-nano/board/Kconfig | 4 +- .../stm32f103-atk-warshipv3/board/Kconfig | 4 +- .../stm32f103-fire-arbitrary/board/Kconfig | 4 +- bsp/stm32/stm32f103-yf-ufun/board/Kconfig | 2 +- bsp/stm32/stm32f407-armfly-v5/board/Kconfig | 4 +- .../stm32f407-atk-explorer/board/Kconfig | 4 +- bsp/stm32/stm32f411-st-nucleo/board/Kconfig | 4 +- bsp/stm32/stm32f413-st-nucleo/board/Kconfig | 4 +- .../stm32f427-robomaster-a/board/Kconfig | 8 +- bsp/stm32/stm32f429-armfly-v6/board/Kconfig | 4 +- bsp/stm32/stm32f429-atk-apollo/board/Kconfig | 4 +- .../stm32f429-fire-challenger/board/Kconfig | 4 +- bsp/stm32/stm32f746-st-nucleo/board/Kconfig | 4 +- bsp/stm32/stm32f767-atk-apollo/board/Kconfig | 4 +- bsp/stm32/stm32g070-st-nucleo/board/Kconfig | 4 +- bsp/stm32/stm32g071-st-nucleo/board/Kconfig | 4 +- .../stm32h750-armfly-h7-tool/board/Kconfig | 4 +- .../stm32l433-ali-startkit/board/Kconfig | 4 +- bsp/stm32/stm32l475-atk-pandora/board/Kconfig | 2 + .../stm32l496-ali-developer/board/Kconfig | 4 +- .../stm32mp157a-st-discovery/board/Kconfig | 4 +- bsp/stm32/stm32mp157a-st-ev1/board/Kconfig | 4 +- bsp/tae32f5300/drivers/Kconfig | 4 +- bsp/tm4c123bsp/board/Kconfig | 2 +- bsp/w60x/drivers/Kconfig | 20 +-- bsp/wch/arm/ch32f103c8-core/board/Kconfig | 16 +- bsp/wch/arm/ch32f203r-evt/board/Kconfig | 32 ++-- 43 files changed, 461 insertions(+), 174 deletions(-) diff --git a/bsp/apm32/apm32f103xe-minibroard/board/Kconfig b/bsp/apm32/apm32f103xe-minibroard/board/Kconfig index 2146256f92..6c3933ccaf 100644 --- a/bsp/apm32/apm32f103xe-minibroard/board/Kconfig +++ b/bsp/apm32/apm32f103xe-minibroard/board/Kconfig @@ -147,7 +147,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 diff --git a/bsp/hc32f4a0/board/Kconfig b/bsp/hc32f4a0/board/Kconfig index 77eaf83ea2..9610b86473 100644 --- a/bsp/hc32f4a0/board/Kconfig +++ b/bsp/hc32f4a0/board/Kconfig @@ -240,7 +240,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM1 - bool "Enable timer1 output pwm" + bool "Enable timer1 output PWM" default n if BSP_USING_PWM1 config BSP_USING_PWM1_CH1 @@ -261,7 +261,7 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH1 diff --git a/bsp/stm32/libraries/HAL_Drivers/config/f0/pwm_config.h b/bsp/stm32/libraries/HAL_Drivers/config/f0/pwm_config.h index 3a91b88dc9..052e4ccec5 100644 --- a/bsp/stm32/libraries/HAL_Drivers/config/f0/pwm_config.h +++ b/bsp/stm32/libraries/HAL_Drivers/config/f0/pwm_config.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006-2021, RT-Thread Development Team + * Copyright (c) 2006-2022, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * @@ -61,6 +61,28 @@ extern "C" { #endif /* PWM5_CONFIG */ #endif /* BSP_USING_PWM5 */ +#ifdef BSP_USING_PWM16 +#ifndef PWM16_CONFIG +#define PWM16_CONFIG \ + { \ + .tim_handle.Instance = TIM16, \ + .name = "pwm16", \ + .channel = 0 \ + } +#endif /* PWM16_CONFIG */ +#endif /* BSP_USING_PWM16 */ + +#ifdef BSP_USING_PWM17 +#ifndef PWM17_CONFIG +#define PWM17_CONFIG \ + { \ + .tim_handle.Instance = TIM17, \ + .name = "pwm17", \ + .channel = 0 \ + } +#endif /* PWM17_CONFIG */ +#endif /* BSP_USING_PWM17 */ + #ifdef __cplusplus } #endif diff --git a/bsp/stm32/libraries/HAL_Drivers/drv_pwm.c b/bsp/stm32/libraries/HAL_Drivers/drv_pwm.c index 29c2bd5903..fabb1438a3 100644 --- a/bsp/stm32/libraries/HAL_Drivers/drv_pwm.c +++ b/bsp/stm32/libraries/HAL_Drivers/drv_pwm.c @@ -587,6 +587,12 @@ static void pwm_get_channel(void) #ifdef BSP_USING_PWM12_CH2 stm32_pwm_obj[PWM12_INDEX].channel |= 1 << 1; #endif +#ifdef BSP_USING_PWM16_CH1 + stm32_pwm_obj[PWM16_INDEX].channel |= 1 << 0; +#endif +#ifdef BSP_USING_PWM17_CH1 + stm32_pwm_obj[PWM17_INDEX].channel |= 1 << 0; +#endif } static int stm32_pwm_init(void) diff --git a/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig b/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig index 3ec4eedb99..ebf997e6c4 100644 --- a/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig +++ b/bsp/stm32/libraries/templates/stm32l1xx/board/Kconfig @@ -99,12 +99,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 diff --git a/bsp/stm32/stm32f072-st-nucleo/applications/arduino/pins_arduino.c b/bsp/stm32/stm32f072-st-nucleo/applications/arduino/pins_arduino.c index 9f71da8711..0c4ec25750 100644 --- a/bsp/stm32/stm32f072-st-nucleo/applications/arduino/pins_arduino.c +++ b/bsp/stm32/stm32f072-st-nucleo/applications/arduino/pins_arduino.c @@ -30,8 +30,8 @@ const pin_map_t pin_map_table[]= {D7, GET_PIN(A,8)}, {D8, GET_PIN(A,9)}, {D9, GET_PIN(C,7), "pwm3", 2}, /* PWM */ - {D10, GET_PIN(B,6)}, - {D11, GET_PIN(A,7)}, + {D10, GET_PIN(B,6), "pwm16", 1}, /* PWM */ + {D11, GET_PIN(A,7), "pwm17", 1}, /* PWM */ {D12, GET_PIN(A,6)}, {D13, GET_PIN(A,5)}, {D14, GET_PIN(B,9)}, diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/.mxproject b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/.mxproject index 7a07e7c089..9f73a77b6d 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/.mxproject +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/.mxproject @@ -1,8 +1,8 @@ [PreviousLibFiles] -LibFiles=Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_def.h;Drivers\STM32F0xx_HAL_Driver\Inc\Legacy\stm32_hal_legacy.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_cortex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart_ex.h;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_gpio.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_dma.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_cortex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart_ex.c;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_def.h;Drivers\STM32F0xx_HAL_Driver\Inc\Legacy\stm32_hal_legacy.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_cortex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart_ex.h;Drivers\CMSIS\Device\ST\STM32F0xx\Include\stm32f072xb.h;Drivers\CMSIS\Device\ST\STM32F0xx\Include\stm32f0xx.h;Drivers\CMSIS\Device\ST\STM32F0xx\Include\system_stm32f0xx.h;Drivers\CMSIS\Device\ST\STM32F0xx\Source\Templates\system_stm32f0xx.c;Drivers\CMSIS\Include\arm_common_tables.h;Drivers\CMSIS\Include\arm_const_structs.h;Drivers\CMSIS\Include\arm_math.h;Drivers\CMSIS\Include\cmsis_armcc.h;Drivers\CMSIS\Include\cmsis_armcc_V6.h;Drivers\CMSIS\Include\cmsis_gcc.h;Drivers\CMSIS\Include\core_cm0.h;Drivers\CMSIS\Include\core_cm0plus.h;Drivers\CMSIS\Include\core_cm3.h;Drivers\CMSIS\Include\core_cm4.h;Drivers\CMSIS\Include\core_cm7.h;Drivers\CMSIS\Include\core_cmFunc.h;Drivers\CMSIS\Include\core_cmInstr.h;Drivers\CMSIS\Include\core_cmSimd.h;Drivers\CMSIS\Include\core_sc000.h;Drivers\CMSIS\Include\core_sc300.h; +LibFiles=Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_def.h;Drivers\STM32F0xx_HAL_Driver\Inc\Legacy\stm32_hal_legacy.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_cortex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_exti.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart_ex.h;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_gpio.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_dma.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_cortex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_exti.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim_ex.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart.c;Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart_ex.c;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_adc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_rcc_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_def.h;Drivers\STM32F0xx_HAL_Driver\Inc\Legacy\stm32_hal_legacy.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_i2c_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_gpio_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_dma.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_cortex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_pwr_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_flash_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_exti.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_tim_ex.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart.h;Drivers\STM32F0xx_HAL_Driver\Inc\stm32f0xx_hal_uart_ex.h;Drivers\CMSIS\Device\ST\STM32F0xx\Include\stm32f072xb.h;Drivers\CMSIS\Device\ST\STM32F0xx\Include\stm32f0xx.h;Drivers\CMSIS\Device\ST\STM32F0xx\Include\system_stm32f0xx.h;Drivers\CMSIS\Device\ST\STM32F0xx\Source\Templates\system_stm32f0xx.c;Drivers\CMSIS\Include\cmsis_armcc.h;Drivers\CMSIS\Include\cmsis_armclang.h;Drivers\CMSIS\Include\cmsis_compiler.h;Drivers\CMSIS\Include\cmsis_gcc.h;Drivers\CMSIS\Include\cmsis_iccarm.h;Drivers\CMSIS\Include\cmsis_version.h;Drivers\CMSIS\Include\core_armv8mbl.h;Drivers\CMSIS\Include\core_armv8mml.h;Drivers\CMSIS\Include\core_cm0.h;Drivers\CMSIS\Include\core_cm0plus.h;Drivers\CMSIS\Include\core_cm1.h;Drivers\CMSIS\Include\core_cm23.h;Drivers\CMSIS\Include\core_cm3.h;Drivers\CMSIS\Include\core_cm33.h;Drivers\CMSIS\Include\core_cm4.h;Drivers\CMSIS\Include\core_cm7.h;Drivers\CMSIS\Include\core_sc000.h;Drivers\CMSIS\Include\core_sc300.h;Drivers\CMSIS\Include\mpu_armv7.h;Drivers\CMSIS\Include\mpu_armv8.h;Drivers\CMSIS\Include\tz_context.h; [PreviousUsedKeilFiles] -SourceFiles=..\Src\main.c;..\Src\stm32f0xx_it.c;..\Src\stm32f0xx_hal_msp.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_gpio.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_dma.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_cortex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart_ex.c;..\Drivers\CMSIS\Device\ST\STM32F0xx\Source\Templates\system_stm32f0xx.c;..\\Src\system_stm32f0xx.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_gpio.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_dma.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_cortex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart_ex.c;..\Drivers\CMSIS\Device\ST\STM32F0xx\Source\Templates\system_stm32f0xx.c;..\\Src\system_stm32f0xx.c;;; +SourceFiles=..\Src\main.c;..\Src\stm32f0xx_it.c;..\Src\stm32f0xx_hal_msp.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_gpio.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_dma.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_cortex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_exti.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart_ex.c;..\Drivers\CMSIS\Device\ST\STM32F0xx\Source\Templates\system_stm32f0xx.c;..\\Src\system_stm32f0xx.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_adc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_rcc_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_i2c_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_gpio.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_dma.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_cortex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_pwr_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_flash_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_exti.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_tim_ex.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart.c;..\Drivers\STM32F0xx_HAL_Driver\Src\stm32f0xx_hal_uart_ex.c;..\Drivers\CMSIS\Device\ST\STM32F0xx\Source\Templates\system_stm32f0xx.c;..\\Src\system_stm32f0xx.c;;; HeaderPath=..\Drivers\STM32F0xx_HAL_Driver\Inc;..\Drivers\STM32F0xx_HAL_Driver\Inc\Legacy;..\Drivers\CMSIS\Device\ST\STM32F0xx\Include;..\Drivers\CMSIS\Include;..\Inc; CDefines=USE_HAL_DRIVER;STM32F072xB;USE_HAL_DRIVER;USE_HAL_DRIVER; diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/CubeMX_Config.ioc b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/CubeMX_Config.ioc index b46bdd8932..637b9e25fa 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/CubeMX_Config.ioc +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/CubeMX_Config.ioc @@ -9,8 +9,10 @@ Mcu.IP2=RCC Mcu.IP3=SYS Mcu.IP4=TIM2 Mcu.IP5=TIM3 -Mcu.IP6=USART2 -Mcu.IPNb=7 +Mcu.IP6=TIM16 +Mcu.IP7=TIM17 +Mcu.IP8=USART2 +Mcu.IPNb=9 Mcu.Name=STM32F072R(8-B)Tx Mcu.Package=LQFP64 Mcu.Pin0=PC13 @@ -18,17 +20,21 @@ Mcu.Pin1=PC14-OSC32_IN Mcu.Pin10=PA3 Mcu.Pin11=PA4 Mcu.Pin12=PA5 -Mcu.Pin13=PB0 -Mcu.Pin14=PB10 -Mcu.Pin15=PC7 -Mcu.Pin16=PA13 -Mcu.Pin17=PA14 -Mcu.Pin18=PB3 -Mcu.Pin19=PB4 +Mcu.Pin13=PA7 +Mcu.Pin14=PB0 +Mcu.Pin15=PB10 +Mcu.Pin16=PC7 +Mcu.Pin17=PA13 +Mcu.Pin18=PA14 +Mcu.Pin19=PB3 Mcu.Pin2=PC15-OSC32_OUT -Mcu.Pin20=VP_SYS_VS_Systick -Mcu.Pin21=VP_TIM2_VS_ClockSourceINT -Mcu.Pin22=VP_TIM3_VS_ClockSourceINT +Mcu.Pin20=PB4 +Mcu.Pin21=PB6 +Mcu.Pin22=VP_SYS_VS_Systick +Mcu.Pin23=VP_TIM2_VS_ClockSourceINT +Mcu.Pin24=VP_TIM3_VS_ClockSourceINT +Mcu.Pin25=VP_TIM16_VS_ClockSourceINT +Mcu.Pin26=VP_TIM17_VS_ClockSourceINT Mcu.Pin3=PF0-OSC_IN Mcu.Pin4=PF1-OSC_OUT Mcu.Pin5=PC0 @@ -36,12 +42,12 @@ Mcu.Pin6=PC1 Mcu.Pin7=PA0 Mcu.Pin8=PA1 Mcu.Pin9=PA2 -Mcu.PinsNb=23 +Mcu.PinsNb=27 Mcu.ThirdPartyNb=0 Mcu.UserConstants= Mcu.UserName=STM32F072RBTx -MxCube.Version=5.2.0 -MxDb.Version=DB.5.0.20 +MxCube.Version=6.5.0 +MxDb.Version=DB.6.0.50 NVIC.ForceEnableDMAVector=true NVIC.HardFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:true NVIC.NonMaskableInt_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:true @@ -90,6 +96,8 @@ PA5.GPIO_PuPd=GPIO_NOPULL PA5.GPIO_Speed=GPIO_SPEED_FREQ_LOW PA5.Locked=true PA5.Signal=GPIO_Output +PA7.Locked=true +PA7.Signal=S_TIM17_CH1 PB0.Locked=true PB0.Mode=IN8 PB0.Signal=ADC_IN8 @@ -99,6 +107,9 @@ PB3.Locked=true PB3.Signal=S_TIM2_CH2 PB4.Locked=true PB4.Signal=S_TIM3_CH1 +PB6.Locked=true +PB6.Mode=PWM Generation1 CH1N +PB6.Signal=TIM16_CH1N PC0.Locked=true PC0.Mode=IN10 PC0.Signal=ADC_IN10 @@ -132,7 +143,7 @@ ProjectManager.CustomerFirmwarePackage= ProjectManager.DefaultFWLocation=true ProjectManager.DeletePrevious=true ProjectManager.DeviceId=STM32F072RBTx -ProjectManager.FirmwarePackage=STM32Cube FW_F0 V1.10.0 +ProjectManager.FirmwarePackage=STM32Cube FW_F0 V1.11.3 ProjectManager.FreePins=false ProjectManager.HalAssertFull=false ProjectManager.HeapSize=0x200 @@ -150,7 +161,7 @@ ProjectManager.StackSize=0x400 ProjectManager.TargetToolchain=MDK-ARM V5 ProjectManager.ToolChainLocation= ProjectManager.UnderRoot=false -ProjectManager.functionlistsort=1-MX_GPIO_Init-GPIO-false-HAL-true,2-SystemClock_Config-RCC-false-HAL-false,3-MX_USART2_UART_Init-USART2-false-HAL-true,4-MX_ADC_Init-ADC-false-HAL-true,5-MX_TIM2_Init-TIM2-false-HAL-true,6-MX_TIM3_Init-TIM3-false-HAL-true +ProjectManager.functionlistsort=1-MX_GPIO_Init-GPIO-false-HAL-true,2-SystemClock_Config-RCC-false-HAL-false,3-MX_USART2_UART_Init-USART2-false-HAL-true,4-MX_ADC_Init-ADC-false-HAL-true,5-MX_TIM2_Init-TIM2-false-HAL-true,6-MX_TIM3_Init-TIM3-false-HAL-true,7-MX_TIM16_Init-TIM16-false-HAL-true,8-MX_TIM17_Init-TIM17-false-HAL-true RCC.AHBFreq_Value=48000000 RCC.APB1Freq_Value=48000000 RCC.APB1TimFreq_Value=48000000 @@ -175,6 +186,8 @@ RCC.USART1Freq_Value=48000000 RCC.USART2Freq_Value=48000000 SH.GPXTI13.0=GPIO_EXTI13 SH.GPXTI13.ConfNb=1 +SH.S_TIM17_CH1.0=TIM17_CH1,Output Compare1 CH1 +SH.S_TIM17_CH1.ConfNb=1 SH.S_TIM2_CH2.0=TIM2_CH2,PWM Generation2 CH2 SH.S_TIM2_CH2.ConfNb=1 SH.S_TIM2_CH3.0=TIM2_CH3,PWM Generation3 CH3 @@ -183,6 +196,10 @@ SH.S_TIM3_CH1.0=TIM3_CH1,PWM Generation1 CH1 SH.S_TIM3_CH1.ConfNb=1 SH.S_TIM3_CH2.0=TIM3_CH2,PWM Generation2 CH2 SH.S_TIM3_CH2.ConfNb=1 +TIM16.Channel=TIM_CHANNEL_1 +TIM16.IPParameters=Channel +TIM17.Channel=TIM_CHANNEL_1 +TIM17.IPParameters=Channel TIM2.Channel-PWM\ Generation2\ CH2=TIM_CHANNEL_2 TIM2.Channel-PWM\ Generation3\ CH3=TIM_CHANNEL_3 TIM2.IPParameters=Channel-PWM Generation3 CH3,Channel-PWM Generation2 CH2 @@ -194,6 +211,10 @@ USART2.VirtualMode=VM_ASYNC USART2.VirtualMode-Asynchronous=VM_ASYNC VP_SYS_VS_Systick.Mode=SysTick VP_SYS_VS_Systick.Signal=SYS_VS_Systick +VP_TIM16_VS_ClockSourceINT.Mode=Enable_Timer +VP_TIM16_VS_ClockSourceINT.Signal=TIM16_VS_ClockSourceINT +VP_TIM17_VS_ClockSourceINT.Mode=Enable_Timer +VP_TIM17_VS_ClockSourceINT.Signal=TIM17_VS_ClockSourceINT VP_TIM2_VS_ClockSourceINT.Mode=Internal VP_TIM2_VS_ClockSourceINT.Signal=TIM2_VS_ClockSourceINT VP_TIM3_VS_ClockSourceINT.Mode=Internal diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/main.h b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/main.h index 72dbd371f6..e0a9b94880 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/main.h +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/main.h @@ -101,5 +101,3 @@ void Error_Handler(void); #endif #endif /* __MAIN_H */ - -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_hal_conf.h b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_hal_conf.h index 151ff3659e..270af92338 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_hal_conf.h +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_hal_conf.h @@ -1,3 +1,4 @@ +/* USER CODE BEGIN Header */ /** ****************************************************************************** * @file stm32f0xx_hal_conf.h @@ -5,32 +6,16 @@ ****************************************************************************** * @attention * - *

© COPYRIGHT(c) 2022 STMicroelectronics

+ * Copyright (c) 2016 STMicroelectronics. + * All rights reserved. * - * Redistribution and use in source and binary forms, with or without modification, - * are permitted provided that the following conditions are met: - * 1. Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * 3. Neither the name of STMicroelectronics nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" - * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE - * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * This software is licensed under terms that can be found in the LICENSE file + * in the root directory of this software component. + * If no LICENSE file comes with this software, it is provided AS-IS. * ****************************************************************************** */ +/* USER CODE END Header */ /* Define to prevent recursive inclusion -------------------------------------*/ #ifndef __STM32F0xx_HAL_CONF_H @@ -48,7 +33,7 @@ * @brief This is the list of modules to be used in the HAL driver */ #define HAL_MODULE_ENABLED -#define HAL_ADC_MODULE_ENABLED + #define HAL_ADC_MODULE_ENABLED /*#define HAL_CRYP_MODULE_ENABLED */ /*#define HAL_CAN_MODULE_ENABLED */ /*#define HAL_CEC_MODULE_ENABLED */ @@ -72,11 +57,11 @@ /*#define HAL_SMBUS_MODULE_ENABLED */ /*#define HAL_WWDG_MODULE_ENABLED */ /*#define HAL_PCD_MODULE_ENABLED */ -/*#define HAL_EXTI_MODULE_ENABLED */ #define HAL_CORTEX_MODULE_ENABLED #define HAL_DMA_MODULE_ENABLED #define HAL_FLASH_MODULE_ENABLED #define HAL_GPIO_MODULE_ENABLED +#define HAL_EXTI_MODULE_ENABLED #define HAL_PWR_MODULE_ENABLED #define HAL_RCC_MODULE_ENABLED #define HAL_I2C_MODULE_ENABLED @@ -129,7 +114,7 @@ * @brief Internal High Speed oscillator for USB (HSI48) value. */ #if !defined (HSI48_VALUE) -#define HSI48_VALUE ((uint32_t)48000000) /*!< Value of the Internal High Speed oscillator for USB in Hz. + #define HSI48_VALUE ((uint32_t)48000000) /*!< Value of the Internal High Speed oscillator for USB in Hz. The real value may vary depending on the variations in voltage and temperature. */ #endif /* HSI48_VALUE */ @@ -138,7 +123,7 @@ * @brief Internal Low Speed oscillator (LSI) value. */ #if !defined (LSI_VALUE) - #define LSI_VALUE ((uint32_t)40000) + #define LSI_VALUE ((uint32_t)40000) #endif /* LSI_VALUE */ /*!< Value of the Internal Low Speed oscillator in Hz The real value may vary depending on the variations in voltage and temperature. */ @@ -146,9 +131,12 @@ * @brief External Low Speed oscillator (LSI) value. */ #if !defined (LSE_VALUE) - #define LSE_VALUE ((uint32_t)32768) /*!< Value of the External Low Speed oscillator in Hz */ + #define LSE_VALUE ((uint32_t)32768) /*!< Value of the External Low Speed oscillator in Hz */ #endif /* LSE_VALUE */ +/** + * @brief Time out for LSE start up value in ms. + */ #if !defined (LSE_STARTUP_TIMEOUT) #define LSE_STARTUP_TIMEOUT ((uint32_t)5000) /*!< Time out for LSE start up, in ms */ #endif /* LSE_STARTUP_TIMEOUT */ @@ -168,6 +156,27 @@ #define PREFETCH_ENABLE 1 #define INSTRUCTION_CACHE_ENABLE 0 #define DATA_CACHE_ENABLE 0 +#define USE_SPI_CRC 0U + +#define USE_HAL_ADC_REGISTER_CALLBACKS 0U /* ADC register callback disabled */ +#define USE_HAL_CAN_REGISTER_CALLBACKS 0U /* CAN register callback disabled */ +#define USE_HAL_COMP_REGISTER_CALLBACKS 0U /* COMP register callback disabled */ +#define USE_HAL_CEC_REGISTER_CALLBACKS 0U /* CEC register callback disabled */ +#define USE_HAL_DAC_REGISTER_CALLBACKS 0U /* DAC register callback disabled */ +#define USE_HAL_I2C_REGISTER_CALLBACKS 0U /* I2C register callback disabled */ +#define USE_HAL_SMBUS_REGISTER_CALLBACKS 0U /* SMBUS register callback disabled */ +#define USE_HAL_UART_REGISTER_CALLBACKS 0U /* UART register callback disabled */ +#define USE_HAL_USART_REGISTER_CALLBACKS 0U /* USART register callback disabled */ +#define USE_HAL_IRDA_REGISTER_CALLBACKS 0U /* IRDA register callback disabled */ +#define USE_HAL_SMARTCARD_REGISTER_CALLBACKS 0U /* SMARTCARD register callback disabled */ +#define USE_HAL_WWDG_REGISTER_CALLBACKS 0U /* WWDG register callback disabled */ +#define USE_HAL_RTC_REGISTER_CALLBACKS 0U /* RTC register callback disabled */ +#define USE_HAL_SPI_REGISTER_CALLBACKS 0U /* SPI register callback disabled */ +#define USE_HAL_I2S_REGISTER_CALLBACKS 0U /* I2S register callback disabled */ +#define USE_HAL_TIM_REGISTER_CALLBACKS 0U /* TIM register callback disabled */ +#define USE_HAL_TSC_REGISTER_CALLBACKS 0U /* TSC register callback disabled */ +#define USE_HAL_PCD_REGISTER_CALLBACKS 0U /* PCD register callback disabled */ + /* ########################## Assert Selection ############################## */ /** * @brief Uncomment the line below to expanse the "assert_param" macro in the @@ -175,15 +184,6 @@ */ /* #define USE_FULL_ASSERT 1U */ -/* ################## SPI peripheral configuration ########################## */ - -/* CRC FEATURE: Use to activate CRC feature inside HAL SPI Driver -* Activated: CRC code is present inside driver -* Deactivated: CRC code cleaned from driver -*/ - -#define USE_SPI_CRC 0U - /* Includes ------------------------------------------------------------------*/ /** * @brief Include module's header file @@ -193,14 +193,14 @@ #include "stm32f0xx_hal_rcc.h" #endif /* HAL_RCC_MODULE_ENABLED */ -#ifdef HAL_EXTI_MODULE_ENABLED - #include "stm32f0xx_hal_exti.h" -#endif /* HAL_EXTI_MODULE_ENABLED */ - #ifdef HAL_GPIO_MODULE_ENABLED #include "stm32f0xx_hal_gpio.h" #endif /* HAL_GPIO_MODULE_ENABLED */ +#ifdef HAL_EXTI_MODULE_ENABLED + #include "stm32f0xx_hal_exti.h" +#endif /* HAL_EXTI_MODULE_ENABLED */ + #ifdef HAL_DMA_MODULE_ENABLED #include "stm32f0xx_hal_dma.h" #endif /* HAL_DMA_MODULE_ENABLED */ @@ -301,15 +301,15 @@ #ifdef USE_FULL_ASSERT /** * @brief The assert_param macro is used for function's parameters check. - * @param expr: If expr is false, it calls assert_failed function + * @param expr If expr is false, it calls assert_failed function * which reports the name of the source file and the source * line number of the call that failed. * If expr is true, it returns no value. * @retval None */ - #define assert_param(expr) ((expr) ? (void)0U : assert_failed((char *)__FILE__, __LINE__)) + #define assert_param(expr) ((expr) ? (void)0U : assert_failed((uint8_t *)__FILE__, __LINE__)) /* Exported functions ------------------------------------------------------- */ - void assert_failed(char* file, uint32_t line); + void assert_failed(uint8_t* file, uint32_t line); #else #define assert_param(expr) ((void)0U) #endif /* USE_FULL_ASSERT */ @@ -320,4 +320,3 @@ #endif /* __STM32F0xx_HAL_CONF_H */ -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_it.h b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_it.h index 4bb625e9b2..baafd16c35 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_it.h +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Inc/stm32f0xx_it.h @@ -76,5 +76,3 @@ void SysTick_Handler(void); #endif #endif /* __STM32F0xx_IT_H */ - -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/main.c b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/main.c index 47b5eeac9a..3753cf676c 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/main.c +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/main.c @@ -37,7 +37,6 @@ ****************************************************************************** */ /* USER CODE END Header */ - /* Includes ------------------------------------------------------------------*/ #include "main.h" @@ -62,10 +61,12 @@ /* USER CODE END PM */ /* Private variables ---------------------------------------------------------*/ -ADC_HandleTypeDef hadc; + ADC_HandleTypeDef hadc; TIM_HandleTypeDef htim2; TIM_HandleTypeDef htim3; +TIM_HandleTypeDef htim16; +TIM_HandleTypeDef htim17; UART_HandleTypeDef huart2; @@ -81,6 +82,8 @@ static void MX_USART2_UART_Init(void); static void MX_ADC_Init(void); static void MX_TIM2_Init(void); static void MX_TIM3_Init(void); +static void MX_TIM16_Init(void); +static void MX_TIM17_Init(void); /* USER CODE BEGIN PFP */ /* Private function prototypes -----------------------------------------------*/ @@ -123,6 +126,8 @@ int main(void) MX_ADC_Init(); MX_TIM2_Init(); MX_TIM3_Init(); + MX_TIM16_Init(); + MX_TIM17_Init(); /* USER CODE BEGIN 2 */ /* USER CODE END 2 */ @@ -148,7 +153,8 @@ void SystemClock_Config(void) RCC_ClkInitTypeDef RCC_ClkInitStruct = {0}; RCC_PeriphCLKInitTypeDef PeriphClkInit = {0}; - /** Initializes the CPU, AHB and APB busses clocks + /** Initializes the RCC Oscillators according to the specified parameters + * in the RCC_OscInitTypeDef structure. */ RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI14|RCC_OSCILLATORTYPE_HSI48; RCC_OscInitStruct.HSI48State = RCC_HSI48_ON; @@ -159,7 +165,8 @@ void SystemClock_Config(void) { Error_Handler(); } - /** Initializes the CPU, AHB and APB busses clocks + + /** Initializes the CPU, AHB and APB buses clocks */ RCC_ClkInitStruct.ClockType = RCC_CLOCKTYPE_HCLK|RCC_CLOCKTYPE_SYSCLK |RCC_CLOCKTYPE_PCLK1; @@ -196,6 +203,7 @@ static void MX_ADC_Init(void) /* USER CODE BEGIN ADC_Init 1 */ /* USER CODE END ADC_Init 1 */ + /** Configure the global features of the ADC (Clock, Resolution, Data Alignment and number of conversion) */ hadc.Instance = ADC1; @@ -216,6 +224,7 @@ static void MX_ADC_Init(void) { Error_Handler(); } + /** Configure for the selected ADC regular channel to be converted. */ sConfig.Channel = ADC_CHANNEL_0; @@ -225,6 +234,7 @@ static void MX_ADC_Init(void) { Error_Handler(); } + /** Configure for the selected ADC regular channel to be converted. */ sConfig.Channel = ADC_CHANNEL_1; @@ -232,6 +242,7 @@ static void MX_ADC_Init(void) { Error_Handler(); } + /** Configure for the selected ADC regular channel to be converted. */ sConfig.Channel = ADC_CHANNEL_4; @@ -239,6 +250,7 @@ static void MX_ADC_Init(void) { Error_Handler(); } + /** Configure for the selected ADC regular channel to be converted. */ sConfig.Channel = ADC_CHANNEL_8; @@ -246,6 +258,7 @@ static void MX_ADC_Init(void) { Error_Handler(); } + /** Configure for the selected ADC regular channel to be converted. */ sConfig.Channel = ADC_CHANNEL_10; @@ -253,6 +266,7 @@ static void MX_ADC_Init(void) { Error_Handler(); } + /** Configure for the selected ADC regular channel to be converted. */ sConfig.Channel = ADC_CHANNEL_11; @@ -288,7 +302,7 @@ static void MX_TIM2_Init(void) htim2.Instance = TIM2; htim2.Init.Prescaler = 0; htim2.Init.CounterMode = TIM_COUNTERMODE_UP; - htim2.Init.Period = 0; + htim2.Init.Period = 4294967295; htim2.Init.ClockDivision = TIM_CLOCKDIVISION_DIV1; htim2.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE; if (HAL_TIM_Base_Init(&htim2) != HAL_OK) @@ -351,7 +365,7 @@ static void MX_TIM3_Init(void) htim3.Instance = TIM3; htim3.Init.Prescaler = 0; htim3.Init.CounterMode = TIM_COUNTERMODE_UP; - htim3.Init.Period = 0; + htim3.Init.Period = 65535; htim3.Init.ClockDivision = TIM_CLOCKDIVISION_DIV1; htim3.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE; if (HAL_TIM_Base_Init(&htim3) != HAL_OK) @@ -392,6 +406,130 @@ static void MX_TIM3_Init(void) } +/** + * @brief TIM16 Initialization Function + * @param None + * @retval None + */ +static void MX_TIM16_Init(void) +{ + + /* USER CODE BEGIN TIM16_Init 0 */ + + /* USER CODE END TIM16_Init 0 */ + + TIM_OC_InitTypeDef sConfigOC = {0}; + TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig = {0}; + + /* USER CODE BEGIN TIM16_Init 1 */ + + /* USER CODE END TIM16_Init 1 */ + htim16.Instance = TIM16; + htim16.Init.Prescaler = 0; + htim16.Init.CounterMode = TIM_COUNTERMODE_UP; + htim16.Init.Period = 65535; + htim16.Init.ClockDivision = TIM_CLOCKDIVISION_DIV1; + htim16.Init.RepetitionCounter = 0; + htim16.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE; + if (HAL_TIM_Base_Init(&htim16) != HAL_OK) + { + Error_Handler(); + } + if (HAL_TIM_PWM_Init(&htim16) != HAL_OK) + { + Error_Handler(); + } + sConfigOC.OCMode = TIM_OCMODE_PWM1; + sConfigOC.Pulse = 0; + sConfigOC.OCPolarity = TIM_OCPOLARITY_HIGH; + sConfigOC.OCNPolarity = TIM_OCNPOLARITY_HIGH; + sConfigOC.OCFastMode = TIM_OCFAST_DISABLE; + sConfigOC.OCIdleState = TIM_OCIDLESTATE_RESET; + sConfigOC.OCNIdleState = TIM_OCNIDLESTATE_RESET; + if (HAL_TIM_PWM_ConfigChannel(&htim16, &sConfigOC, TIM_CHANNEL_1) != HAL_OK) + { + Error_Handler(); + } + sBreakDeadTimeConfig.OffStateRunMode = TIM_OSSR_DISABLE; + sBreakDeadTimeConfig.OffStateIDLEMode = TIM_OSSI_DISABLE; + sBreakDeadTimeConfig.LockLevel = TIM_LOCKLEVEL_OFF; + sBreakDeadTimeConfig.DeadTime = 0; + sBreakDeadTimeConfig.BreakState = TIM_BREAK_DISABLE; + sBreakDeadTimeConfig.BreakPolarity = TIM_BREAKPOLARITY_HIGH; + sBreakDeadTimeConfig.AutomaticOutput = TIM_AUTOMATICOUTPUT_DISABLE; + if (HAL_TIMEx_ConfigBreakDeadTime(&htim16, &sBreakDeadTimeConfig) != HAL_OK) + { + Error_Handler(); + } + /* USER CODE BEGIN TIM16_Init 2 */ + + /* USER CODE END TIM16_Init 2 */ + HAL_TIM_MspPostInit(&htim16); + +} + +/** + * @brief TIM17 Initialization Function + * @param None + * @retval None + */ +static void MX_TIM17_Init(void) +{ + + /* USER CODE BEGIN TIM17_Init 0 */ + + /* USER CODE END TIM17_Init 0 */ + + TIM_OC_InitTypeDef sConfigOC = {0}; + TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig = {0}; + + /* USER CODE BEGIN TIM17_Init 1 */ + + /* USER CODE END TIM17_Init 1 */ + htim17.Instance = TIM17; + htim17.Init.Prescaler = 0; + htim17.Init.CounterMode = TIM_COUNTERMODE_UP; + htim17.Init.Period = 65535; + htim17.Init.ClockDivision = TIM_CLOCKDIVISION_DIV1; + htim17.Init.RepetitionCounter = 0; + htim17.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE; + if (HAL_TIM_Base_Init(&htim17) != HAL_OK) + { + Error_Handler(); + } + if (HAL_TIM_OC_Init(&htim17) != HAL_OK) + { + Error_Handler(); + } + sConfigOC.OCMode = TIM_OCMODE_TIMING; + sConfigOC.Pulse = 0; + sConfigOC.OCPolarity = TIM_OCPOLARITY_HIGH; + sConfigOC.OCNPolarity = TIM_OCNPOLARITY_HIGH; + sConfigOC.OCFastMode = TIM_OCFAST_DISABLE; + sConfigOC.OCIdleState = TIM_OCIDLESTATE_RESET; + sConfigOC.OCNIdleState = TIM_OCNIDLESTATE_RESET; + if (HAL_TIM_OC_ConfigChannel(&htim17, &sConfigOC, TIM_CHANNEL_1) != HAL_OK) + { + Error_Handler(); + } + sBreakDeadTimeConfig.OffStateRunMode = TIM_OSSR_DISABLE; + sBreakDeadTimeConfig.OffStateIDLEMode = TIM_OSSI_DISABLE; + sBreakDeadTimeConfig.LockLevel = TIM_LOCKLEVEL_OFF; + sBreakDeadTimeConfig.DeadTime = 0; + sBreakDeadTimeConfig.BreakState = TIM_BREAK_DISABLE; + sBreakDeadTimeConfig.BreakPolarity = TIM_BREAKPOLARITY_HIGH; + sBreakDeadTimeConfig.AutomaticOutput = TIM_AUTOMATICOUTPUT_DISABLE; + if (HAL_TIMEx_ConfigBreakDeadTime(&htim17, &sBreakDeadTimeConfig) != HAL_OK) + { + Error_Handler(); + } + /* USER CODE BEGIN TIM17_Init 2 */ + + /* USER CODE END TIM17_Init 2 */ + HAL_TIM_MspPostInit(&htim17); + +} + /** * @brief USART2 Initialization Function * @param None @@ -486,7 +624,7 @@ void Error_Handler(void) * @param line: assert_param error line source number * @retval None */ -void assert_failed(char *file, uint32_t line) +void assert_failed(uint8_t *file, uint32_t line) { /* USER CODE BEGIN 6 */ /* User can add his own implementation to report the file name and line number, @@ -494,5 +632,3 @@ void assert_failed(char *file, uint32_t line) /* USER CODE END 6 */ } #endif /* USE_FULL_ASSERT */ - -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_hal_msp.c b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_hal_msp.c index 7f1953cce7..e2b729d572 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_hal_msp.c +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_hal_msp.c @@ -80,7 +80,7 @@ /* USER CODE END 0 */ void HAL_TIM_MspPostInit(TIM_HandleTypeDef *htim); - /** + /** * Initializes the Global MSP. */ void HAL_MspInit(void) @@ -216,6 +216,28 @@ void HAL_TIM_Base_MspInit(TIM_HandleTypeDef* htim_base) /* USER CODE END TIM3_MspInit 1 */ } + else if(htim_base->Instance==TIM16) + { + /* USER CODE BEGIN TIM16_MspInit 0 */ + + /* USER CODE END TIM16_MspInit 0 */ + /* Peripheral clock enable */ + __HAL_RCC_TIM16_CLK_ENABLE(); + /* USER CODE BEGIN TIM16_MspInit 1 */ + + /* USER CODE END TIM16_MspInit 1 */ + } + else if(htim_base->Instance==TIM17) + { + /* USER CODE BEGIN TIM17_MspInit 0 */ + + /* USER CODE END TIM17_MspInit 0 */ + /* Peripheral clock enable */ + __HAL_RCC_TIM17_CLK_ENABLE(); + /* USER CODE BEGIN TIM17_MspInit 1 */ + + /* USER CODE END TIM17_MspInit 1 */ + } } @@ -273,6 +295,48 @@ void HAL_TIM_MspPostInit(TIM_HandleTypeDef* htim) /* USER CODE END TIM3_MspPostInit 1 */ } + else if(htim->Instance==TIM16) + { + /* USER CODE BEGIN TIM16_MspPostInit 0 */ + + /* USER CODE END TIM16_MspPostInit 0 */ + + __HAL_RCC_GPIOB_CLK_ENABLE(); + /**TIM16 GPIO Configuration + PB6 ------> TIM16_CH1N + */ + GPIO_InitStruct.Pin = GPIO_PIN_6; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Pull = GPIO_NOPULL; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW; + GPIO_InitStruct.Alternate = GPIO_AF2_TIM16; + HAL_GPIO_Init(GPIOB, &GPIO_InitStruct); + + /* USER CODE BEGIN TIM16_MspPostInit 1 */ + + /* USER CODE END TIM16_MspPostInit 1 */ + } + else if(htim->Instance==TIM17) + { + /* USER CODE BEGIN TIM17_MspPostInit 0 */ + + /* USER CODE END TIM17_MspPostInit 0 */ + + __HAL_RCC_GPIOA_CLK_ENABLE(); + /**TIM17 GPIO Configuration + PA7 ------> TIM17_CH1 + */ + GPIO_InitStruct.Pin = GPIO_PIN_7; + GPIO_InitStruct.Mode = GPIO_MODE_AF_PP; + GPIO_InitStruct.Pull = GPIO_NOPULL; + GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW; + GPIO_InitStruct.Alternate = GPIO_AF5_TIM17; + HAL_GPIO_Init(GPIOA, &GPIO_InitStruct); + + /* USER CODE BEGIN TIM17_MspPostInit 1 */ + + /* USER CODE END TIM17_MspPostInit 1 */ + } } /** @@ -305,6 +369,28 @@ void HAL_TIM_Base_MspDeInit(TIM_HandleTypeDef* htim_base) /* USER CODE END TIM3_MspDeInit 1 */ } + else if(htim_base->Instance==TIM16) + { + /* USER CODE BEGIN TIM16_MspDeInit 0 */ + + /* USER CODE END TIM16_MspDeInit 0 */ + /* Peripheral clock disable */ + __HAL_RCC_TIM16_CLK_DISABLE(); + /* USER CODE BEGIN TIM16_MspDeInit 1 */ + + /* USER CODE END TIM16_MspDeInit 1 */ + } + else if(htim_base->Instance==TIM17) + { + /* USER CODE BEGIN TIM17_MspDeInit 0 */ + + /* USER CODE END TIM17_MspDeInit 0 */ + /* Peripheral clock disable */ + __HAL_RCC_TIM17_CLK_DISABLE(); + /* USER CODE BEGIN TIM17_MspDeInit 1 */ + + /* USER CODE END TIM17_MspDeInit 1 */ + } } @@ -376,5 +462,3 @@ void HAL_UART_MspDeInit(UART_HandleTypeDef* huart) /* USER CODE BEGIN 1 */ /* USER CODE END 1 */ - -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ diff --git a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_it.c b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_it.c index 45a5780317..6d0064105b 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_it.c +++ b/bsp/stm32/stm32f072-st-nucleo/board/CubeMX_Config/Src/stm32f0xx_it.c @@ -157,4 +157,3 @@ void SysTick_Handler(void) /* USER CODE BEGIN 1 */ /* USER CODE END 1 */ -/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/ diff --git a/bsp/stm32/stm32f072-st-nucleo/board/Kconfig b/bsp/stm32/stm32f072-st-nucleo/board/Kconfig index bb8a44c42a..8f8fe8b8c7 100644 --- a/bsp/stm32/stm32f072-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f072-st-nucleo/board/Kconfig @@ -17,6 +17,7 @@ menu "Onboard Peripheral Drivers" config BSP_USING_ARDUINO bool "Support Arduino" select RT_USING_ARDUINO + select ARDUINO_USING_SERVO select RT_USING_PIN select BSP_USING_ADC select BSP_USING_ADC1 @@ -27,7 +28,10 @@ menu "Onboard Peripheral Drivers" select BSP_USING_PWM3 select BSP_USING_PWM3_CH1 select BSP_USING_PWM3_CH2 - select BSP_USING_I2C + select BSP_USING_PWM16 + select BSP_USING_PWM16_CH1 + select BSP_USING_PWM17 + select BSP_USING_PWM17_CH1 default n endmenu @@ -74,13 +78,13 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH2 @@ -93,7 +97,7 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 @@ -104,6 +108,24 @@ menu "On-chip Peripheral Drivers" bool "Enable PWM3 channel2" default n endif + + menuconfig BSP_USING_PWM16 + bool "Enable timer16 output PWM" + default n + if BSP_USING_PWM16 + config BSP_USING_PWM16_CH1 + bool "Enable PWM16 channel1" + default n + endif + + menuconfig BSP_USING_PWM17 + bool "Enable timer17 output PWM" + default n + if BSP_USING_PWM17 + config BSP_USING_PWM17_CH1 + bool "Enable PWM17 channel1" + default n + endif endif menuconfig BSP_USING_I2C diff --git a/bsp/stm32/stm32f091-st-nucleo/board/Kconfig b/bsp/stm32/stm32f091-st-nucleo/board/Kconfig index 69c4d15d75..3fc3dbc78f 100644 --- a/bsp/stm32/stm32f091-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f091-st-nucleo/board/Kconfig @@ -107,12 +107,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH4 diff --git a/bsp/stm32/stm32f103-atk-nano/board/Kconfig b/bsp/stm32/stm32f103-atk-nano/board/Kconfig index 150a2a3119..39caa5b0ba 100644 --- a/bsp/stm32/stm32f103-atk-nano/board/Kconfig +++ b/bsp/stm32/stm32f103-atk-nano/board/Kconfig @@ -95,12 +95,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 diff --git a/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig b/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig index 2d7d944504..cdcde48156 100644 --- a/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig +++ b/bsp/stm32/stm32f103-atk-warshipv3/board/Kconfig @@ -108,12 +108,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 diff --git a/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig b/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig index 5ca802adca..7fefaae909 100644 --- a/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig +++ b/bsp/stm32/stm32f103-fire-arbitrary/board/Kconfig @@ -220,12 +220,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH2 diff --git a/bsp/stm32/stm32f103-yf-ufun/board/Kconfig b/bsp/stm32/stm32f103-yf-ufun/board/Kconfig index 2d5952ca4c..77bd279089 100644 --- a/bsp/stm32/stm32f103-yf-ufun/board/Kconfig +++ b/bsp/stm32/stm32f103-yf-ufun/board/Kconfig @@ -77,7 +77,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH1 diff --git a/bsp/stm32/stm32f407-armfly-v5/board/Kconfig b/bsp/stm32/stm32f407-armfly-v5/board/Kconfig index 5073e6e7a4..035bf7210d 100644 --- a/bsp/stm32/stm32f407-armfly-v5/board/Kconfig +++ b/bsp/stm32/stm32f407-armfly-v5/board/Kconfig @@ -135,12 +135,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM10 - bool "Enable timer10 output pwm" + bool "Enable timer10 output PWM" default n if BSP_USING_PWM10 config BSP_USING_PWM10_CH1 diff --git a/bsp/stm32/stm32f407-atk-explorer/board/Kconfig b/bsp/stm32/stm32f407-atk-explorer/board/Kconfig index 615109cef6..3eddc0a442 100644 --- a/bsp/stm32/stm32f407-atk-explorer/board/Kconfig +++ b/bsp/stm32/stm32f407-atk-explorer/board/Kconfig @@ -255,12 +255,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH4 diff --git a/bsp/stm32/stm32f411-st-nucleo/board/Kconfig b/bsp/stm32/stm32f411-st-nucleo/board/Kconfig index 5bdb69b4e6..3f9a2ae1bc 100644 --- a/bsp/stm32/stm32f411-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f411-st-nucleo/board/Kconfig @@ -82,12 +82,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 diff --git a/bsp/stm32/stm32f413-st-nucleo/board/Kconfig b/bsp/stm32/stm32f413-st-nucleo/board/Kconfig index 33e896d598..c8e546399f 100644 --- a/bsp/stm32/stm32f413-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f413-st-nucleo/board/Kconfig @@ -104,12 +104,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH4 diff --git a/bsp/stm32/stm32f427-robomaster-a/board/Kconfig b/bsp/stm32/stm32f427-robomaster-a/board/Kconfig index 1d7a7aa9d8..11adc5d196 100644 --- a/bsp/stm32/stm32f427-robomaster-a/board/Kconfig +++ b/bsp/stm32/stm32f427-robomaster-a/board/Kconfig @@ -89,12 +89,12 @@ menu "On-chip Peripheral Drivers" default n menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM12 - bool "Enable timer12 output pwm" + bool "Enable timer12 output PWM" default n if BSP_USING_PWM12 config BSP_USING_PWM12_CH1 @@ -103,7 +103,7 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM4 - bool "Enable timer4 output pwm" + bool "Enable timer4 output PWM" default n if BSP_USING_PWM4 config BSP_USING_PWM4_CH1 @@ -121,7 +121,7 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM5 - bool "Enable timer5 output pwm" + bool "Enable timer5 output PWM" default n if BSP_USING_PWM5 config BSP_USING_PWM5_CH1 diff --git a/bsp/stm32/stm32f429-armfly-v6/board/Kconfig b/bsp/stm32/stm32f429-armfly-v6/board/Kconfig index 82d21c44b1..be917b6e88 100644 --- a/bsp/stm32/stm32f429-armfly-v6/board/Kconfig +++ b/bsp/stm32/stm32f429-armfly-v6/board/Kconfig @@ -160,12 +160,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH1 diff --git a/bsp/stm32/stm32f429-atk-apollo/board/Kconfig b/bsp/stm32/stm32f429-atk-apollo/board/Kconfig index b444252787..636d50d99e 100644 --- a/bsp/stm32/stm32f429-atk-apollo/board/Kconfig +++ b/bsp/stm32/stm32f429-atk-apollo/board/Kconfig @@ -223,12 +223,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH4 diff --git a/bsp/stm32/stm32f429-fire-challenger/board/Kconfig b/bsp/stm32/stm32f429-fire-challenger/board/Kconfig index 67060c697a..7cb8370d9b 100644 --- a/bsp/stm32/stm32f429-fire-challenger/board/Kconfig +++ b/bsp/stm32/stm32f429-fire-challenger/board/Kconfig @@ -156,12 +156,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM5 - bool "Enable timer5 output pwm" + bool "Enable timer5 output PWM" default n if BSP_USING_PWM5 config BSP_USING_PWM5_CH1 diff --git a/bsp/stm32/stm32f746-st-nucleo/board/Kconfig b/bsp/stm32/stm32f746-st-nucleo/board/Kconfig index 83868f1a5d..ba0ea4a1e5 100644 --- a/bsp/stm32/stm32f746-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32f746-st-nucleo/board/Kconfig @@ -158,12 +158,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH2 diff --git a/bsp/stm32/stm32f767-atk-apollo/board/Kconfig b/bsp/stm32/stm32f767-atk-apollo/board/Kconfig index cda9c0dfef..c371b353f2 100644 --- a/bsp/stm32/stm32f767-atk-apollo/board/Kconfig +++ b/bsp/stm32/stm32f767-atk-apollo/board/Kconfig @@ -148,12 +148,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH3 diff --git a/bsp/stm32/stm32g070-st-nucleo/board/Kconfig b/bsp/stm32/stm32g070-st-nucleo/board/Kconfig index 2b6bdf2b46..4b7368b1a4 100644 --- a/bsp/stm32/stm32g070-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32g070-st-nucleo/board/Kconfig @@ -72,12 +72,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 diff --git a/bsp/stm32/stm32g071-st-nucleo/board/Kconfig b/bsp/stm32/stm32g071-st-nucleo/board/Kconfig index f129b01c43..6eccd19184 100644 --- a/bsp/stm32/stm32g071-st-nucleo/board/Kconfig +++ b/bsp/stm32/stm32g071-st-nucleo/board/Kconfig @@ -72,12 +72,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH1 diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig b/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig index 0f3d798f71..98431741e4 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig +++ b/bsp/stm32/stm32h750-armfly-h7-tool/board/Kconfig @@ -90,12 +90,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH2 diff --git a/bsp/stm32/stm32l433-ali-startkit/board/Kconfig b/bsp/stm32/stm32l433-ali-startkit/board/Kconfig index 38bf6a5dae..9df03f45d4 100644 --- a/bsp/stm32/stm32l433-ali-startkit/board/Kconfig +++ b/bsp/stm32/stm32l433-ali-startkit/board/Kconfig @@ -171,12 +171,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH2 diff --git a/bsp/stm32/stm32l475-atk-pandora/board/Kconfig b/bsp/stm32/stm32l475-atk-pandora/board/Kconfig index 3c4deae943..9bde85c5e5 100644 --- a/bsp/stm32/stm32l475-atk-pandora/board/Kconfig +++ b/bsp/stm32/stm32l475-atk-pandora/board/Kconfig @@ -22,6 +22,8 @@ menu "Onboard Peripheral Drivers" config BSP_USING_ARDUINO bool "Support Arduino" select RT_USING_ARDUINO + select ARDUINO_USING_SERVO + select ARDUINO_USING_WIRE select BSP_USING_PWM select BSP_USING_PWM1 select BSP_USING_PWM1_CH1 diff --git a/bsp/stm32/stm32l496-ali-developer/board/Kconfig b/bsp/stm32/stm32l496-ali-developer/board/Kconfig index 840210dc2c..1e347f4653 100644 --- a/bsp/stm32/stm32l496-ali-developer/board/Kconfig +++ b/bsp/stm32/stm32l496-ali-developer/board/Kconfig @@ -171,12 +171,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM3 - bool "Enable timer3 output pwm" + bool "Enable timer3 output PWM" default n if BSP_USING_PWM3 config BSP_USING_PWM3_CH2 diff --git a/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig b/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig index 36ba61a584..d09a30ea4e 100644 --- a/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig +++ b/bsp/stm32/stm32mp157a-st-discovery/board/Kconfig @@ -169,12 +169,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM4 - bool "Enable timer4 output pwm" + bool "Enable timer4 output PWM" default n if BSP_USING_PWM4 config BSP_USING_PWM4_CH2 diff --git a/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig b/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig index 9957aff4e1..f5d81d5f15 100644 --- a/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig +++ b/bsp/stm32/stm32mp157a-st-ev1/board/Kconfig @@ -223,12 +223,12 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM4 - bool "Enable timer4 output pwm" + bool "Enable timer4 output PWM" default n if BSP_USING_PWM4 config BSP_USING_PWM4_CH2 diff --git a/bsp/tae32f5300/drivers/Kconfig b/bsp/tae32f5300/drivers/Kconfig index 6e7d491d04..f0c6036df7 100644 --- a/bsp/tae32f5300/drivers/Kconfig +++ b/bsp/tae32f5300/drivers/Kconfig @@ -188,7 +188,7 @@ menu "On-chip Peripheral Drivers" select RT_USING_PWM if BSP_USING_PWM menuconfig BSP_USING_PWM1 - bool "Enable timer1 output pwm" + bool "Enable timer1 output PWM" default n if BSP_USING_PWM1 config BSP_USING_PWM1_CH1 @@ -209,7 +209,7 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM2 - bool "Enable timer2 output pwm" + bool "Enable timer2 output PWM" default n if BSP_USING_PWM2 config BSP_USING_PWM2_CH1 diff --git a/bsp/tm4c123bsp/board/Kconfig b/bsp/tm4c123bsp/board/Kconfig index f6136621de..be749799ea 100644 --- a/bsp/tm4c123bsp/board/Kconfig +++ b/bsp/tm4c123bsp/board/Kconfig @@ -228,7 +228,7 @@ menu "On-chip Peripheral Drivers" endif menuconfig BSP_USING_PWM - bool "Enable pwm" + bool "Enable PWM" default n select RT_USING_PWM if BSP_USING_PWM diff --git a/bsp/w60x/drivers/Kconfig b/bsp/w60x/drivers/Kconfig index e38a312b65..4682a88151 100644 --- a/bsp/w60x/drivers/Kconfig +++ b/bsp/w60x/drivers/Kconfig @@ -133,43 +133,43 @@ menu "On-chip Peripheral Drivers" if BSP_USING_PWM config USING_PWM_CH1 - bool "Enable pwm channel 1" + bool "Enable PWM channel 1" default n if USING_PWM_CH1 config WM_PWM_CH1_PIN - int "wm pwm channel 1 pin number" + int "wm PWM channel 1 pin number" default 23 endif config USING_PWM_CH2 - bool "Enable pwm channel 2" + bool "Enable PWM channel 2" default n if USING_PWM_CH2 config WM_PWM_CH2_PIN - int "wm pwm channel 2 pin number" + int "wm PWM channel 2 pin number" default 22 endif config USING_PWM_CH3 - bool "Enable pwm channel 3" + bool "Enable PWM channel 3" default n if USING_PWM_CH3 config WM_PWM_CH3_PIN - int "wm pwm channel 3 pin number" + int "wm PWM channel 3 pin number" default 21 endif config USING_PWM_CH4 - bool "Enable pwm channel 4" + bool "Enable PWM channel 4" default n if USING_PWM_CH4 config WM_PWM_CH4_PIN - int "wm pwm channel 4 pin number" + int "wm PWM channel 4 pin number" default 37 endif config USING_PWM_CH5 - bool "Enable pwm channel 5" + bool "Enable PWM channel 5" default n if USING_PWM_CH5 config WM_PWM_CH5_PIN - int "wm pwm channel 5 pin number" + int "wm PWM channel 5 pin number" default 19 endif endif diff --git a/bsp/wch/arm/ch32f103c8-core/board/Kconfig b/bsp/wch/arm/ch32f103c8-core/board/Kconfig index eb26adf300..41ae4bcb64 100644 --- a/bsp/wch/arm/ch32f103c8-core/board/Kconfig +++ b/bsp/wch/arm/ch32f103c8-core/board/Kconfig @@ -101,7 +101,7 @@ config BSP_USING_TIM if BSP_USING_TIM1 choice - prompt "using TIM1 as hwtimer or pwm mode" + prompt "using TIM1 as hwtimer or PWM mode" default BSP_USING_TIM1_HWTIMER config BSP_USING_TIM1_HWTIMER @@ -109,7 +109,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM1_PWM - bool "using TIM1 as pwm mode" + bool "using TIM1 as PWM mode" select BSP_USING_PWM endchoice @@ -139,7 +139,7 @@ config BSP_USING_TIM if BSP_USING_TIM2 choice - prompt "using TIM2 as hwtimer or pwm mode" + prompt "using TIM2 as hwtimer or PWM mode" default BSP_USING_TIM2_HWTIMER config BSP_USING_TIM2_HWTIMER @@ -147,7 +147,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM2_PWM - bool "using TIM2 as pwm mode" + bool "using TIM2 as PWM mode" select BSP_USING_PWM endchoice @@ -177,7 +177,7 @@ config BSP_USING_TIM if BSP_USING_TIM3 choice - prompt "using TIM3 as hwtimer or pwm mode" + prompt "using TIM3 as hwtimer or PWM mode" default BSP_USING_TIM3_HWTIMER config BSP_USING_TIM3_HWTIMER @@ -185,7 +185,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM3_PWM - bool "using TIM3 as pwm mode" + bool "using TIM3 as PWM mode" select BSP_USING_PWM endchoice @@ -215,7 +215,7 @@ config BSP_USING_TIM if BSP_USING_TIM4 choice - prompt "using TIM4 as hwtimer or pwm mode" + prompt "using TIM4 as hwtimer or PWM mode" default BSP_USING_TIM4_HWTIMER config BSP_USING_TIM4_HWTIMER @@ -223,7 +223,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM4_PWM - bool "using TIM4 as pwm mode" + bool "using TIM4 as PWM mode" select BSP_USING_PWM endchoice diff --git a/bsp/wch/arm/ch32f203r-evt/board/Kconfig b/bsp/wch/arm/ch32f203r-evt/board/Kconfig index 7bb98f7102..74ef7c3dcf 100644 --- a/bsp/wch/arm/ch32f203r-evt/board/Kconfig +++ b/bsp/wch/arm/ch32f203r-evt/board/Kconfig @@ -125,7 +125,7 @@ config BSP_USING_TIM if BSP_USING_TIM1 choice - prompt "using TIM1 as hwtimer or pwm mode" + prompt "using TIM1 as hwtimer or PWM mode" default BSP_USING_TIM1_HWTIMER config BSP_USING_TIM1_HWTIMER @@ -133,7 +133,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM1_PWM - bool "using TIM1 as pwm mode" + bool "using TIM1 as PWM mode" select BSP_USING_PWM endchoice @@ -163,7 +163,7 @@ config BSP_USING_TIM if BSP_USING_TIM2 choice - prompt "using TIM2 as hwtimer or pwm mode" + prompt "using TIM2 as hwtimer or PWM mode" default BSP_USING_TIM2_HWTIMER config BSP_USING_TIM2_HWTIMER @@ -171,7 +171,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM2_PWM - bool "using TIM2 as pwm mode" + bool "using TIM2 as PWM mode" select BSP_USING_PWM endchoice @@ -201,7 +201,7 @@ config BSP_USING_TIM if BSP_USING_TIM3 choice - prompt "using TIM3 as hwtimer or pwm mode" + prompt "using TIM3 as hwtimer or PWM mode" default BSP_USING_TIM3_HWTIMER config BSP_USING_TIM3_HWTIMER @@ -209,7 +209,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM3_PWM - bool "using TIM3 as pwm mode" + bool "using TIM3 as PWM mode" select BSP_USING_PWM endchoice @@ -239,7 +239,7 @@ config BSP_USING_TIM if BSP_USING_TIM4 choice - prompt "using TIM4 as hwtimer or pwm mode" + prompt "using TIM4 as hwtimer or PWM mode" default BSP_USING_TIM4_HWTIMER config BSP_USING_TIM4_HWTIMER @@ -247,7 +247,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM4_PWM - bool "using TIM4 as pwm mode" + bool "using TIM4 as PWM mode" select BSP_USING_PWM endchoice @@ -277,7 +277,7 @@ config BSP_USING_TIM if BSP_USING_TIM4 choice - prompt "using TIM5 as hwtimer or pwm mode" + prompt "using TIM5 as hwtimer or PWM mode" default BSP_USING_TIM5_HWTIMER config BSP_USING_TIM5_HWTIMER @@ -285,7 +285,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM5_PWM - bool "using TIM5 as pwm mode" + bool "using TIM5 as PWM mode" select BSP_USING_PWM endchoice @@ -339,7 +339,7 @@ config BSP_USING_TIM if BSP_USING_TIM8 choice - prompt "using TIM8 as hwtimer or pwm mode" + prompt "using TIM8 as hwtimer or PWM mode" default BSP_USING_TIM8_HWTIMER config BSP_USING_TIM8_HWTIMER @@ -347,7 +347,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM8_PWM - bool "using TIM8 as pwm mode" + bool "using TIM8 as PWM mode" select BSP_USING_PWM endchoice @@ -377,7 +377,7 @@ config BSP_USING_TIM if BSP_USING_TIM9 choice - prompt "using TIM9 as hwtimer or pwm mode" + prompt "using TIM9 as hwtimer or PWM mode" default BSP_USING_TIM9_HWTIMER config BSP_USING_TIM9_HWTIMER @@ -385,7 +385,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM9_PWM - bool "using TIM9 as pwm mode" + bool "using TIM9 as PWM mode" select BSP_USING_PWM endchoice @@ -415,7 +415,7 @@ config BSP_USING_TIM if BSP_USING_TIM10 choice - prompt "using TIM10 as hwtimer or pwm mode" + prompt "using TIM10 as hwtimer or PWM mode" default BSP_USING_TIM10_HWTIMER config BSP_USING_TIM10_HWTIMER @@ -423,7 +423,7 @@ config BSP_USING_TIM select BSP_USING_HWTIMER config BSP_USING_TIM10_PWM - bool "using TIM10 as pwm mode" + bool "using TIM10 as PWM mode" select BSP_USING_PWM endchoice -- GitLab