blob: 0e1268557df120eb68a2e42c064c0638039b3963 [file] [log] [blame]
# STM32 Cube LL RTC
# Copyright (c) 2018, Linaro Limited
# SPDX-License-Identifier: Apache-2.0
menuconfig COUNTER_RTC_STM32
bool "STM32 Counter RTC driver"
default y if !RTC
depends on DT_HAS_ST_STM32_RTC_ENABLED
select USE_STM32_LL_RTC
select USE_STM32_LL_PWR
select USE_STM32_LL_RCC
select USE_STM32_LL_EXTI
help
Build RTC driver for STM32 SoCs.
Tested on STM32 C0, F0, F2, F3, F4, F7, G0, G4, H7, L1, L4, L5, U5 series
if COUNTER_RTC_STM32
choice COUNTER_RTC_STM32_CLOCK_SRC
bool "RTC clock source"
optional
depends on COUNTER_RTC_STM32
config COUNTER_RTC_STM32_CLOCK_LSI
bool "LSI"
select DEPRECATED
help
Use LSI as RTC clock
Deprecated in favor of device tree secondary domain clock
config COUNTER_RTC_STM32_CLOCK_LSE
bool "LSE"
select DEPRECATED
help
Use LSE as RTC clock
Deprecated in favor of device tree secondary domain clock
endchoice #COUNTER_RTC_STM32_CLOCK_SRC
config COUNTER_RTC_STM32_SAVE_VALUE_BETWEEN_RESETS
bool "Save rtc time value between resets"
default n
help
Keep the counter value after each reset.
config COUNTER_RTC_STM32_SUBSECONDS
bool "Use the subseconds as a basic tick."
depends on !SOC_SERIES_STM32F1X
help
Use the subseconds as the basic time tick. It increases resolution
of the counter. The frequency of the time is RTC Source Clock divided
by 2. It is the clock after the first asynchronous prescaler.
The config increases power consumption.
endif # COUNTER_RTC_STM32