ARM Tachnology:Chapter 3 STM32 Clock and Configuration

ARM Tachnology STM32 ST32
1 ARM Tachnology

Chapter 3 STM32 Clock and configuration Cortex Intelligent Processors by ARM
2 Chapter 3 STM32 Clock and Configuration

CONTENTS Objectives Clock System of STM32F103 Clock Configuration of STM32 sTM32 functions related to clock
3 CONTENTS • Objectives • Clock System of STM32F103 • Clock Configuration of STM32 • STM32 functions related to clock

3.1 Objectives All STM32 peripherals are driven by the clock, and every module uses independent clock to meet the low-power requirement. So STM32 clock system must be studied in detail to use peripherals properl
4 • 3.1 Objectives All STM32 peripherals are driven by the clock, and every module uses independent clock to meet the low-power requirement. So STM32 clock system must be studied in detail to use peripherals properly

3.2 STM32 Clock System There 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) Where, HIS, HSE, and pll can be used as system clock LSi and lse are second level clock The clock tree of stM32F103 is shown in Fig 11 on page 115 of the STM32 Reference Manual(RM)
5 3.2 STM32 Clock System There 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) Where, HIS, HSE, and PLL can be used as System Clock. LSI and LSE are second level clock. The clock tree of STM32F103 is shown in Fig.11 on page 115 of the STM32 Reference Manual (RM)

The clock tree of stM32F103 is shown in Fig 11 on page 115 of the STM32 Reference Manual(RM) Figure 11. Clock tre KA加 A co memory and DM wm回a 123As
6 The clock tree of STM32F103 is shown in Fig.11 on page 115 of the STM32 Reference Manual (RM)

There are several clocks for mcu core and different peripherals. Why?
8 There are several clocks for MCU core and different peripherals. Why?

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
9 Second reason This mode of clock is helpful to realize low power. 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

Enable clock out Due to the requirement of low power, every module of stm32 microcontroller uses the clocks independently So, when we use a peripheral, we must enable its clock firstly. Otherwise, it will not work 10
10 Enable clock out Due to the requirement of low power, every module of STM32 microcontroller uses the clocks independently. So, when we use a peripheral, we must enable its clock firstly. Otherwise, it will not work

3.3 Clock configuration of stM32 In general, an embedded system should be initialized before it works In embedded system initialization, the system should be set up. The clock source should be considered in clock setup and PLL Should also be considered then the internal bus external bus and peripherals clock should be set up. The flow chart of clock setup is shown in Fig 3-1 Enable hse clock Set up AB clock according to the system clock RCC HCLK Config Set up APB2 clock according to AHB clock RCC HCLK2 Config Set up aPbl clock according to AHB clock RCC HCLKIConfig Select HIS, HSE or PLL as the system Set up system clock clock Enable peripherals ig. 3-1 Flow chart of clock setup RCC AHBPeriphClock Cmd
11 In general, an embedded system should be initialized before it works. In embedded system initialization, the system should be set up. The clock source should be considered in clock setup, and PLL should also be considered. Then the internal bus, external bus and peripherals clock should be set up. The flow chart of clock setup is shown in Fig.3-1. 3.3 Clock configuration of STM32 Enable HSE clock Set up AHB clock according to the system clock RCC_HCLKConfig Set up APB2 clock according to AHB clock RCC_HCLK2Config Set up APB1 clock according to AHB clock RCC_HCLK1Config Set up system clock Enable peripherals RCC_AHBPeriphClockCmd Select HIS, HSE or PLL as the system clock Fig. 3-1 Flow chart of clock setup
按次数下载不扣除下载券;
注册用户24小时内重复下载只扣除一次;
顺序:VIP每日次数-->可用次数-->下载券;
- 《汇编语言程序设计》课程教学资源(PPT课件讲稿)循环与分支程序设计.ppt
- 香港科技大学:Latent Tree Models.pptx
- Network and System Security Risk Assessment(PPT讲稿)Introduction.ppt
- 复旦大学:Trapping in scale-free networks with hierarchical organization of modularity.pptx
- 电子工业出版社:《计算机网络》课程教学资源(第五版,PPT课件讲稿)第十章 下一代因特网.ppt
- 卷积码的概率译码(PPT讲稿).ppt
- 《ASP动态网页设计实用教程》教学资源(PPT课件讲稿)第8章 Web数据库基础.ppt
- Lower bound for sorting, radix sort.ppt
- 数据传送类指令(PPT讲稿).ppt
- 长春工业大学:《电子商务》课程教学资源(PPT课件)第9章 网络鞋城前台页面.ppt
- 因特网多媒体技术(PPT讲稿).ppt
- International Trade Forms.ppt
- 香港理工大学:Building Robust Wireless LAN for Industrial Control with DSSS-CDMA Cell Phone Network Paradigm.ppt
- 香港浸会大学:《Experiencing Cluster Computing》Class 8 Case Studies.ppt
- 中国科学技术大学:《计算机体系结构》课程教学资源(PPT课件讲稿)动态调度(Cont)、推断执行和ILP.ppt
- 《多媒体教学软件设计》课程PPT教学课件:第13章 多媒体教学软件中脚本编程技巧.ppt
- 山西国际商务职业学院:《网页设计与制作》课程教学资源(PPT课件)第一章 网页设计基础知识.ppt
- 《算法设计技巧与分析》课程教学资源(PPT讲稿)Lecture 8 贪婪法则 Greedy Approach.ppt
- 山东大学:《计算机图形学》课程PPT教学课件(Programming with OpenGL)Part 3:Three Dimensions.ppt
- Integrated analysis of regulatoryand metabolic networks revealsnovel regulatory mechanisms inSaccharomyces cerevisiae.ppt
- 《软件工程简介》课程PPT教学课件(可行性研究、需求分析、总体设计、详细设计).ppt
- 利用NetRiver实验系统实现IP协议交互和TCP协议交互.ppt
- 江苏海洋大学(淮海工学院):《Java面向对象程序设计》课程教学资源(PPT课件讲稿)第3章 Java 面向对象编程 3.1 面向对象软件开发概述.pptx
- 《数字图像处理 Digital Image Processing》课程教学资源(PPT课件讲稿)第2章 图像的基本知识及运算.ppt
- 西安电子科技大学:《操作系统 Operating Systems》课程教学资源(PPT课件讲稿)Chapter 02 进程和线程 Processes and Threads.ppt
- 《计算机辅助设计 Computer Aided Design》课程PPT教学课件:第一篇 CAD技术 第一章 几何造型方法介绍和分类.ppt
- 清华大学:高校信息门户建设(PPT讲稿).ppt
- 《汇编语言》课程PPT教学课件:第三章 80x86寻址方式和指令系统.ppt
- 《网站设计与建设 Website design and developments》课程教学资源(PPT课件讲稿)第一部分 Web基础知识 第3章 图形与Web设计.ppt
- 香港城市大学:Introduction to Real-Time Systems(Design and Analysis of Algorithms).pptx
- 《编译原理》课程教学资源(PPT课件讲稿)第五章 语法分析——自下而上分析.ppt
- 香港科技大学:Advanced Topics in NextGeneration Wireless Networks.ppt
- 复旦大学:《数据库基础与应用》课程PPT教学课件(Access案例教程)第1章 数据库基础知识.pptx
- Transport Layer Identification of P2P Traffic.ppt
- 上海交通大学:Basic Raster Graphics Algorithms for Drawing 2D Primitives.ppt
- 《编译原理》课程教学资源(PPT课件讲稿)第七章 中间代码生成.ppt
- 《MATLAB应用基础》课程教学资源(PPT课件讲稿)第4章 MATLAB的数值计算.ppt
- 安徽广播影视职业技术学院:《ASP动态网页设计实用教程》课程教学资源(PPT讲稿)第1章 ASP基础(贾海陶).ppt
- 白城师范学院:《数据库系统概论 An Introduction to Database System》课程教学资源(PPT课件讲稿)第六章 关系数据理论.pptx
- 中国科学技术大学:《数据结构及其算法》课程电子教案(PPT课件讲稿)第三章 栈和队列.pps