diff --git a/targets/TARGET_STM/mbed_overrides.c b/targets/TARGET_STM/mbed_overrides.c index 3f51187448..fd5f1287de 100644 --- a/targets/TARGET_STM/mbed_overrides.c +++ b/targets/TARGET_STM/mbed_overrides.c @@ -43,9 +43,9 @@ extern void SetSysClock(void); # define LSE_DRIVE_LOAD_LEVEL MBED_CONF_TARGET_LSE_DRIVE_LOAD_LEVEL # else # if defined(RCC_LSE_HIGHDRIVE_MODE) -# define LSE_DRIVE_LOAD_LEVEL RCC_LSE_HIGHDRIVE_MODE +# define LSE_DRIVE_LOAD_LEVEL RCC_LSE_LOWPOWER_MODE # else -# define LSE_DRIVE_LOAD_LEVEL RCC_LSEDRIVE_MEDIUMHIGH +# define LSE_DRIVE_LOAD_LEVEL RCC_LSEDRIVE_LOW # endif # endif diff --git a/targets/targets.json b/targets/targets.json index 2bb0dee4d7..d02488a6db 100644 --- a/targets/targets.json +++ b/targets/targets.json @@ -1198,6 +1198,11 @@ "help": "Mask value : USE_PLL_HSE_EXTC | USE_PLL_HSE_XTAL (need HW patch) | USE_PLL_HSI", "value": "USE_PLL_HSE_EXTC|USE_PLL_HSI", "macro_name": "CLOCK_SOURCE" + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "macros_add": [ @@ -1407,6 +1412,11 @@ "help": "Mask value : USE_PLL_HSE_EXTC | USE_PLL_HSE_XTAL (need HW patch) | USE_PLL_HSI", "value": "USE_PLL_HSE_EXTC|USE_PLL_HSI", "macro_name": "CLOCK_SOURCE" + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "device_has_add": [ @@ -2116,6 +2126,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "overrides": { @@ -2359,6 +2374,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "extra_labels_add": [ @@ -2462,6 +2482,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "extra_labels_add": [ @@ -2625,6 +2650,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "components_add": [ @@ -2888,6 +2918,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "macros_add": [ @@ -3121,6 +3156,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "macros_add": [ @@ -3641,6 +3681,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "overrides": { @@ -3740,6 +3785,11 @@ "lpticker_lptim": { "help": "This target supports LPTIM. Set value 1 to use LPTIM for LPTICKER, or 0 to use RTC wakeup timer", "value": 1 + }, + "lse_drive_load_level": { + "help": "HSE drive load level RCC_LSEDRIVE_LOW | RCC_LSEDRIVE_MEDIUMLOW | RCC_LSEDRIVE_MEDIUMHIGH | RCC_LSEDRIVE_HIGH", + "value": "RCC_LSEDRIVE_LOW", + "macro_name": "TARGET_LSE_DRIVE_LOAD_LEVEL" } }, "macros_add": [