Gitee keil工程

软件下载和安装:

链接:https://pan.baidu.com/s/1PWDAU0EhVZ6J8h6xH_uw5g
提取码:b343
 

MDK526.exe

Keil.STM32F4xx_DFP.2.17.1.pack

keygen_2032.exe

JLink_Windows_V640.exe

en.stsw-stm32065_v1-7-1_STM32F4 (DSP和标准外设库)

创建STM32F4工程:

Method One:

使用keil5和std library

(1) Uncompress en.stsw-stm32065_v1-7-1_STM32F4.zip to STM32F4xx_DSP_StdPeriph_Lib_V1.7.1

(2) Make directory 000 and copy files  to file 000

(3) Delete file system_stm32f4xx.c in GPIO_IOToggle

(4)Create a new project (STM32F429VETx)

 Do not select  anything, cause we use std library not Keil.STM32F4xx_DFP.2.17.1.pack

 

(5) Add files and modify main.c and main.h

(6) Configure include path and Defines(USE_STDPERIPH_DRIVER,STM32F429_439xx)

(7)Modify frequency of external crystal oscillator

and configure clock tree

SYSCLK=(HSE_VALUE / PLL_M) * PLL_N / PLL_P

                =(8M / 8) * 336 / 2

                =168M

(8) Download

(9)Debug

The program is blocked in the while loop

We can comment the selected code to solve this problem

(10)Rebuild, download and debug again to get the right result

(12)

Using this method, the program can run on both STM32F407 and STM32F429.

Because of the flexible configuration, we usually use this method to create a STM32 keil5 project based on the Stdandard Peripheral Library.

======================

======================

======================

Method Two(We usually use method one):

使用keil5和pack固件包

 

 

Logo

有“AI”的1024 = 2048,欢迎大家加入2048 AI社区

更多推荐