26#define RTC_BKP_DOMAIN_RST_INDICATOR_BKPxR 0
35#define RTC_BKP_DOMAIN_RST_INDICATOR_PATTERN 0xABCD
190 else if(en_status ==
DISABLE) {
Common utility module public API.
System-wide error code definitions.
#define DEC_TO_BCD(DEC)
Converts a decimal value to its BCD-encoded byte equivalent.
#define BCD_TO_DEC(BCD)
Converts a BCD-encoded byte to its decimal equivalent.
EN_STATUS_te
Represents an enabled or disabled state.
ERR_te
Standard return type used by all public API functions.
@ ERR_MODULE_ALREADY_INITIALIZED
void rcc_set_pclk_apb1(RCC_APB1ENR_te periph_position, EN_STATUS_te en_status)
Enables or disables the peripheral clock for an APB1 peripheral.
static void rtc_set_write_protection(EN_STATUS_te en_status)
Enables or disables write protection of the RTC registers.
void rtc_get_time(TIME_ts *time)
Reads the current time from the RTC.
void rtc_set_calendar(CALENDAR_ts const *date)
Sets the RTC calendar (date and weekday).
void rtc_set_time(TIME_ts const *time)
Sets the RTC time (hours, minutes, seconds).
ERR_te rtc_init(void)
Initializes the RTC peripheral.
STM32F401RE MCU-specific peripheral register definitions and bit position enumerations.
STM32F401RE RCC driver public API.
#define RTC_BKP_DOMAIN_RST_INDICATOR_PATTERN
Sentinel value written to BKP0R after successful RTC initialization.
#define RTC_BKP_DOMAIN_RST_INDICATOR_BKPxR
Backup register index used to store the initialization sentinel pattern.
bool initialized
True after rtc_init has completed successfully in this boot session.
STM32F401RE RTC driver public API.
Holds a calendar date (year, month, day, weekday).
Holds a time-of-day value (hours, minutes, seconds).