历史上的今天
今天是:2024年09月23日(星期一)
2020年09月23日 | stm32F4各个库文件的作用分析
2020-09-23 来源:eefocus
system_stm32f4xx.c:This file contains the system clock configuration for STM32F4xx devices.
1 /**
2 ******************************************************************************
3 * @file system_stm32f4xx.c
4 * @author MCD Application Team
5 * @version V1.4.0
6 * @date 04-August-2014
7 * @brief CMSIS Cortex-M4 Device Peripheral Access Layer System Source File.
8 * This file contains the system clock configuration for STM32F4xx devices.
9 *
10 * 1. This file provides two functions and one global variable to be called from
11 * user application:
12 * - SystemInit(): Setups the system clock (System clock source, PLL Multiplier
13 * and Divider factors, AHB/APBx prescalers and Flash settings),
14 * depending on the configuration made in the clock xls tool.
15 * This function is called at startup just after reset and
16 * before branch to main program. This call is made inside
17 * the "startup_stm32f4xx.s" file.
18 *
19 * - SystemCoreClock variable: Contains the core clock (HCLK), it can be used
20 * by the user application to setup the SysTick
21 * timer or configure other parameters.
22 *
23 * - SystemCoreClockUpdate(): Updates the variable SystemCoreClock and must
24 * be called whenever the core clock is changed
25 * during program execution.
26 *
27 * 2. After each device reset the HSI (16 MHz) is used as system clock source.
28 * Then SystemInit() function is called, in "startup_stm32f4xx.s" file, to
29 * configure the system clock before to branch to main program.
30 *
31 * 3. If the system clock source selected by user fails to startup, the SystemInit()
32 * function will do nothing and HSI still used as system clock source. User can
33 * add some code to deal with this issue inside the SetSysClock() function.
34 *
35 * 4. The default value of HSE crystal is set to 25MHz, refer to "HSE_VALUE" define
36 * in "stm32f4xx.h" file. When HSE is used as system clock source, directly or
37 * through PLL, and you are using different crystal you have to adapt the HSE
38 * value to your own configuration.
39 *
40 * 5. This file configures the system clock as follows:
41 *=============================================================================
42 *=============================================================================
43 * Supported STM32F40xxx/41xxx devices
44 *-----------------------------------------------------------------------------
45 * System Clock source | PLL (HSE)
46 *-----------------------------------------------------------------------------
47 * SYSCLK(Hz) | 168000000
48 *-----------------------------------------------------------------------------
49 * HCLK(Hz) | 168000000
50 *-----------------------------------------------------------------------------
51 * AHB Prescaler | 1
52 *-----------------------------------------------------------------------------
53 * APB1 Prescaler | 4
54 *-----------------------------------------------------------------------------
55 * APB2 Prescaler | 2
56 *-----------------------------------------------------------------------------
57 * HSE Frequency(Hz) | 25000000
58 *-----------------------------------------------------------------------------
59 * PLL_M | 25
60 *-----------------------------------------------------------------------------
61 * PLL_N | 336
62 *-----------------------------------------------------------------------------
63 * PLL_P | 2
64 *-----------------------------------------------------------------------------
65 * PLL_Q | 7
66 *-----------------------------------------------------------------------------
67 * PLLI2S_N | NA
68 *-----------------------------------------------------------------------------
69 * PLLI2S_R | NA
70 *-----------------------------------------------------------------------------
71 * I2S input clock | NA
72 *-----------------------------------------------------------------------------
73 * VDD(V) | 3.3
74 *-----------------------------------------------------------------------------
75 * Main regulator output voltage | Scale1 mode
76 *-----------------------------------------------------------------------------
77 * Flash Latency(WS) | 5
78 *-----------------------------------------------------------------------------
79 * Prefetch Buffer | ON
80 *-----------------------------------------------------------------------------
81 * Instruction cache | ON
82 *-----------------------------------------------------------------------------
83 * Data cache | ON
84 *-----------------------------------------------------------------------------
85 * Require 48MHz for USB OTG FS, | Disabled
86 * SDIO and RNG clock |
史海拾趣
|
“我们希望尽快摆脱依赖特定半导体厂商的状况”(日立制作所技术人员)。 日本国内厂商开发毫米波通信IC的积极性正与日俱增。就目前所知,日立制作所、松下、东芝三家公司都在独立开发60GHz频带收发IC(RF收发IC)(注1)。各公司都希望为数 ...… 查看全部问答> |
|
2440 读 温度芯片,总是无法触发中断,请教有什么方法呀? BSP包里通过应用层调用IIC文件夹不能正常工作,只好转入到bootloader层去做温度检测了,可是无论如何也不能触发中断,有经验的请指教,先谢谢了。… 查看全部问答> |
|
为什么我的EVC程序在X86上跑没问题!但同样的程序在ARM上跑,菜单触摸屏有用,但在窗口上触屏后没反映,是什么原因啊?????请高手指教!… 查看全部问答> |
|
把adoce31.dll拷贝到Windows, CreateProcess(_T("\RegSvrCe" ,_T("/s \Windows\\adoce31.d 把adoce31.dll拷贝到Windows, CreateProcess(_T(\"\\RegSvrCe\" ,_T(\"/s \\Windows\\\\adoce31.dll\" ,NULL .... 这个在wince.net 4.2以及wm5.0上面还不能正常使用 这个问题如何解决. … 查看全部问答> |
|
手里有个模块wavecom的wismo2c,不能上GPRS,怎么处理下可实现上网 据说要做下软件升级,怎么做啊。请高人指点。 查的资料说这个模块刚上市时不支持GPRS,要支持的话需要软件升级,升级软件到哪里下?… 查看全部问答> |
|
我以前一直用9.1,感觉很不好用,今天换成了9.0,可是编译老有错误,错误如下: Internal Error: Sub-system: AMERGE, File: /quartus/atm/amerge/amerge_kpt_op.cpp, Line: 220cmp_merge_kpt_dbStack Trace:0x3D9B7 : amerge_ ...… 查看全部问答> |
|
【连载】【ALIENTEK 战舰STM32开发板】STM32开发指南--第二十三章 内部温度传感器实验 第二十三章 内部温度传感器实验 本章我们将向大家介绍STM32的内部温度传感器。在本章中,我们将使用STM32的内部温度传感器来读取温度值,并在TFTLCD模块上显示出来。本章分为如下几个部分:23.1 STM32 内部 ...… 查看全部问答> |




