STM32F0xx Standard Peripherals Firmware Library: RTC_Calendar

STM32F0xx Standard Peripherals Library

STM32F0xx Standard Peripherals Firmware Library

Defines

#define BKP_VALUE   0x32F0
#define RTC_CLOCK_SOURCE_LSE

Functions

int main (void)
 Main program.
void RTC_AlarmShow (void)
 Display the current time on the Hyperterminal.
static void RTC_Config (void)
 Configure the RTC peripheral by selecting the clock source.
void RTC_TimeRegulate (void)
 Returns the time entered by user, using Hyperterminal.
void RTC_TimeShow (void)
 Display the current time on the Hyperterminal.
uint8_t USART_Scanf (uint32_t value)
 Gets numeric values from the hyperterminal.

Variables

__IO uint32_t AsynchPrediv = 0
__IO uint32_t SynchPrediv = 0

Define Documentation

#define BKP_VALUE   0x32F0

Definition at line 46 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

Referenced by main(), and RTC_TimeRegulate().

#define RTC_CLOCK_SOURCE_LSE

Function Documentation

int main ( void  )

Main program.

Parameters:
None
Return values:
None

< At this stage the microcontroller clock setting is already configured, this is done through SystemInit() function which is called from startup file (startup_stm32f0xx.s) before to branch to application main. To reconfigure the default setting of SystemInit() function, refer to system_stm32f0xx.c file

Definition at line 60 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

References AsynchPrediv, BKP_VALUE, EXTI_InitStructure, NVIC_InitStructure, RTC_AlarmShow(), RTC_Config(), RTC_InitStructure, RTC_TimeRegulate(), RTC_TimeShow(), SynchPrediv, and USART_InitStructure.

void RTC_AlarmShow ( void  )

Display the current time on the Hyperterminal.

Parameters:
None
Return values:
None

Definition at line 359 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

Referenced by EXTI4_15_IRQHandler(), main(), and RTC_TimeRegulate().

static void RTC_Config ( void  ) [static]

Configure the RTC peripheral by selecting the clock source.

Parameters:
None
Return values:
None

Definition at line 191 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

References AsynchPrediv, and SynchPrediv.

Referenced by main().

static void RTC_TimeRegulate ( void  )

Returns the time entered by user, using Hyperterminal.

Parameters:
None
Return values:
None

Definition at line 246 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

References BKP_VALUE, RTC_AlarmShow(), RTC_TimeShow(), and USART_Scanf().

Referenced by EXTI0_1_IRQHandler(), and main().

static void RTC_TimeShow ( void  )

Display the current time on the Hyperterminal.

Parameters:
None
Return values:
None

Definition at line 346 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

Referenced by EXTI4_15_IRQHandler(), main(), and RTC_TimeRegulate().

uint8_t USART_Scanf ( uint32_t  value)

Gets numeric values from the hyperterminal.

Parameters:
None
Return values:
None

Definition at line 373 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

References tmp.

Referenced by RTC_TimeRegulate().


Variable Documentation

__IO uint32_t AsynchPrediv = 0

Definition at line 49 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

Referenced by main(), and RTC_Config().

__IO uint32_t SynchPrediv = 0

Definition at line 49 of file STM32F0xx_StdPeriph_Examples/RTC/RTC_Calendar/main.c.

Referenced by main(), and RTC_Config().

STM32L1xx Standard Peripherals Library: Footer

 

 

 For complete documentation on STM32 Microcontrollers visit www.st.com/STM32