5 - STM32 Clock and Configuration
5 - STM32 Clock and Configuration
2
★Objectives:
3
STM32 Clock System
There are 5 clock sources in STM32F103:
HSI (High Speed Internal)
HSE (High Speed External)
LSI (Low Speed Internal)
LSE (Low Speed External)
PLL(Phase Locked Loop)
4
STM32F103 Clock System
5
Fig.5-1 Clock tree
STM32F103 Clock System
6
Fig.5-1 Clock tree
STM32F103 Clock System
7
Fig.5-1 Clock tree
There are several clocks for MCU core and
different peripherals. Why?
9
First reason
High speed clock is used for high speed
devices, like CPU, and low speed clock is used
for low speed devices like peripherals.
Second reason
This mode of clock is helpful to realize low
power consumption.
10
Enable clock out
11
Clock configuration of STM32
In general, an embedded system should be initialized
before it works.
12
Clock configuration of STM32
The flow chart of clock setup is shown in Fig.5-2.
Enable HSE clock
They can be viewed in STM32 Reference Manual (RM) from page 121
14
‘7.3 RCC registers’