Functions
Collaboration diagram for RTC_Exported_Functions:

Functions

void RTC_ClearFlag (uint16_t RTC_FLAG)
 Clears the RTC's pending flags. More...
 
void RTC_ClearITPendingBit (uint16_t RTC_IT)
 Clears the RTC's interrupt pending bits. More...
 
void RTC_EnterConfigMode (void)
 Enters the RTC configuration mode. More...
 
void RTC_ExitConfigMode (void)
 Exits from the RTC configuration mode. More...
 
uint32_t RTC_GetCounter (void)
 Gets the RTC counter value. More...
 
uint32_t RTC_GetDivider (void)
 Gets the RTC divider value. More...
 
FlagStatus RTC_GetFlagStatus (uint16_t RTC_FLAG)
 Checks whether the specified RTC flag is set or not. More...
 
ITStatus RTC_GetITStatus (uint16_t RTC_IT)
 Checks whether the specified RTC interrupt has occurred or not. More...
 
void RTC_ITConfig (uint16_t RTC_IT, FunctionalState NewState)
 Enables or disables the specified RTC interrupts. More...
 
void RTC_SetAlarm (uint32_t AlarmValue)
 Sets the RTC alarm value. More...
 
void RTC_SetCounter (uint32_t CounterValue)
 Sets the RTC counter value. More...
 
void RTC_SetPrescaler (uint32_t PrescalerValue)
 Sets the RTC prescaler value. More...
 
void RTC_WaitForLastTask (void)
 Waits until last write operation on RTC registers has finished. More...
 
void RTC_WaitForSynchro (void)
 Waits until the RTC Time and Date registers (RTC_TR and RTC_DR) are synchronized with RTC APB clock. More...
 

Detailed Description

Function Documentation

void RTC_ClearFlag ( uint16_t  RTC_FLAG)

Clears the RTC's pending flags.

Parameters
RTC_FLAGspecifies the flag to clear. This parameter can be any combination of the following values:
  • RTC_FLAG_RSF: Registers Synchronized flag. This flag is cleared only after an APB reset or an APB Clock stop.
  • RTC_FLAG_OW: Overflow flag
  • RTC_FLAG_ALR: Alarm flag
  • RTC_FLAG_SEC: Second flag
Return values
None

Definition at line 273 of file stm32f10x_rtc.c.

void RTC_ClearITPendingBit ( uint16_t  RTC_IT)

Clears the RTC's interrupt pending bits.

Parameters
RTC_ITspecifies the interrupt pending bit to clear. This parameter can be any combination of the following values:
  • RTC_IT_OW: Overflow interrupt
  • RTC_IT_ALR: Alarm interrupt
  • RTC_IT_SEC: Second interrupt
Return values
None

Definition at line 318 of file stm32f10x_rtc.c.

void RTC_EnterConfigMode ( void  )

Enters the RTC configuration mode.

Parameters
None
Return values
None

Definition at line 111 of file stm32f10x_rtc.c.

void RTC_ExitConfigMode ( void  )

Exits from the RTC configuration mode.

Parameters
None
Return values
None

Definition at line 122 of file stm32f10x_rtc.c.

uint32_t RTC_GetCounter ( void  )

Gets the RTC counter value.

Parameters
None
Return values
RTCcounter value.

Definition at line 133 of file stm32f10x_rtc.c.

uint32_t RTC_GetDivider ( void  )

Gets the RTC divider value.

Parameters
None
Return values
RTCDivider value.

Definition at line 193 of file stm32f10x_rtc.c.

FlagStatus RTC_GetFlagStatus ( uint16_t  RTC_FLAG)

Checks whether the specified RTC flag is set or not.

Parameters
RTC_FLAGspecifies the flag to check. This parameter can be one the following values:
  • RTC_FLAG_RTOFF: RTC Operation OFF flag
  • RTC_FLAG_RSF: Registers Synchronized flag
  • RTC_FLAG_OW: Overflow flag
  • RTC_FLAG_ALR: Alarm flag
  • RTC_FLAG_SEC: Second flag
Return values
Thenew state of RTC_FLAG (SET or RESET).

Definition at line 244 of file stm32f10x_rtc.c.

ITStatus RTC_GetITStatus ( uint16_t  RTC_IT)

Checks whether the specified RTC interrupt has occurred or not.

Parameters
RTC_ITspecifies the RTC interrupts sources to check. This parameter can be one of the following values:
  • RTC_IT_OW: Overflow interrupt
  • RTC_IT_ALR: Alarm interrupt
  • RTC_IT_SEC: Second interrupt
Return values
Thenew state of the RTC_IT (SET or RESET).

Definition at line 291 of file stm32f10x_rtc.c.

void RTC_ITConfig ( uint16_t  RTC_IT,
FunctionalState  NewState 
)

Enables or disables the specified RTC interrupts.

Parameters
RTC_ITspecifies the RTC interrupts sources to be enabled or disabled. This parameter can be any combination of the following values:
  • RTC_IT_OW: Overflow interrupt
  • RTC_IT_ALR: Alarm interrupt
  • RTC_IT_SEC: Second interrupt
NewStatenew state of the specified RTC interrupts. This parameter can be: ENABLE or DISABLE.
Return values
None

Definition at line 90 of file stm32f10x_rtc.c.

void RTC_SetAlarm ( uint32_t  AlarmValue)

Sets the RTC alarm value.

Parameters
AlarmValueRTC alarm new value.
Return values
None

Definition at line 178 of file stm32f10x_rtc.c.

void RTC_SetCounter ( uint32_t  CounterValue)

Sets the RTC counter value.

Parameters
CounterValueRTC counter new value.
Return values
None

Definition at line 145 of file stm32f10x_rtc.c.

void RTC_SetPrescaler ( uint32_t  PrescalerValue)

Sets the RTC prescaler value.

Parameters
PrescalerValueRTC prescaler new value.
Return values
None

Definition at line 160 of file stm32f10x_rtc.c.

void RTC_WaitForLastTask ( void  )

Waits until last write operation on RTC registers has finished.

Note
This function must be called before any write to RTC registers.
Parameters
None
Return values
None

Definition at line 207 of file stm32f10x_rtc.c.

void RTC_WaitForSynchro ( void  )

Waits until the RTC Time and Date registers (RTC_TR and RTC_DR) are synchronized with RTC APB clock.

Note
The RTC Resynchronization mode is write protected, use the RTC_WriteProtectionCmd(DISABLE) before calling this function.
To read the calendar through the shadow registers after Calendar initialization, calendar update or after wakeup from low power modes the software must first clear the RSF flag. The software must then wait until it is set again before reading the calendar, which means that the calendar registers have been correctly copied into the RTC_TR and RTC_DR shadow registers.
Parameters
None
Return values
AnErrorStatus enumeration value:
  • SUCCESS: RTC registers are synchronised
  • ERROR: RTC registers are not synchronised

Waits until the RTC Time and Date registers (RTC_TR and RTC_DR) are synchronized with RTC APB clock.

Note
This function must be called before any read operation after an APB reset or an APB clock stop.
Parameters
None
Return values
None

Definition at line 619 of file stm32f4xx_rtc.c.



rosflight_firmware
Author(s): Daniel Koch , James Jackson
autogenerated on Wed Jul 3 2019 19:59:30