From 25a0aee77e086aa15026c01293630756c8547382 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bora=20=C3=96zgen?= Date: Mon, 15 Feb 2021 09:56:06 +0100 Subject: [PATCH] Support RTC from HSE only for STM32F2/3/4 --- targets/TARGET_STM/rtc_api_hal.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/targets/TARGET_STM/rtc_api_hal.h b/targets/TARGET_STM/rtc_api_hal.h index eaf57fccd9..da5576ad2a 100644 --- a/targets/TARGET_STM/rtc_api_hal.h +++ b/targets/TARGET_STM/rtc_api_hal.h @@ -38,6 +38,10 @@ extern "C" { #endif +#if RTC_FROM_HSE && !(TARGET_STM32F2 || TARGET_STM32F3 || TARGET_STM32F4) +#error "RTC from HSE not supported for this target" +#endif + #if RTC_FROM_HSE #define RTC_CLOCK 1000000U #elif MBED_CONF_TARGET_LSE_AVAILABLE