EasyManuals Logo

ST STM32F10 Series User Manual

ST STM32F10 Series
519 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #121 background imageLoading...
Page #121 background image
UM0306 Real-Time Clock (RTC)
121/519
8 Real-Time Clock (RTC)
8.1 Introduction
The Real-Time Clock is an independent timer. The RTC provides a set of continuously-
running counters which can be used, with suitable software, to provide a clock-calendar
function. The counter values can be written to set the current time/date of the system.
8.2 Main features
Programmable prescaler: division factor up to 2
20
32-bit programmable counter for long-term measurement
Two separate clocks: PCLK1 for the APB1 interface and RTC clock (must be at least
four times slower than the PCLK1 clock)
Two separate reset types:
The APB1 interface is reset by system reset
The RTC Core (Prescaler, Alarm, Counter and Divider) is reset only by a Backup
domain reset (see Section 4.1.3: Backup domain Reset on page 46).
Three dedicated maskable interrupt lines:
Alarm interrupt, for generating a software programmable alarm interrupt.
Seconds interrupt, for generating a periodic interrupt signal with a programmable
period length (up to 1 second).
Overflow interrupt, to detect when the internal programmable counter rolls over to
zero.
8.3 Functional description
8.3.1 Overview
The RTC consists of two main units (see Figure 18 on page 122). The first one (APB1
Interface) is used to interface with the APB1 bus. This unit also contains a set of 16-bit
registers accessible from the APB1 bus in read or write mode (for more information refer to
Section 8.4: RTC register description on page 125). The APB1 interface is clocked by the
APB1 bus clock in order to interface with the APB1 bus.
The other unit (RTC Core) consists of a chain of programmable counters made of two main
blocks. The first block is the RTC prescaler block, which generates the RTC time base
TR_CLK that can be programmed to have a period of up to 1 second. It includes a 20-bit
programmable divider (RTC Prescaler). Every TR_CLK period, the RTC generates an
interrupt (Second Interrupt) if it is enabled in the RTC_CR register. The second block is a
32-bit programmable counter that can be initialized to the current system time. The system
time is incremented at the TR_CLK rate and compared with a programmable date (stored in
the RTC_ALR register) in order to generate an alarm interrupt, if enabled in the RTC_CR
control register.
www.BDTIC.com/ST

Table of Contents

Other manuals for ST STM32F10 Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the ST STM32F10 Series and is the answer not in the manual?

ST STM32F10 Series Specifications

General IconGeneral
BrandST
ModelSTM32F10 Series
CategoryMicrocontrollers
LanguageEnglish

Related product manuals