金牌会员
 
- 积分
- 2097
- 金钱
- 2097
- 注册时间
- 2014-3-7
- 在线时间
- 491 小时
|
本帖最后由 ssssssssssss 于 2018-7-11 11:49 编辑
stm32f0 iap 进入app函数用了一分钟!谁遇到过?
- int main(void)
- {
- uint32_t i = 0;
-
- /*!< At this stage the microcontroller clock setting is already configured,
- this is done through SystemInit() function which is called from startup
- file (startup_stm32f0xx.s) before to branch to application main.
- To reconfigure the default setting of SystemInit() function, refer to
- system_stm32f0xx.c file
- */
-
- /* Relocate by software the vector table to the internal SRAM at 0x20000000 ***/
-
- /* Copy the vector table from the Flash (mapped at the base of the application
- load address 0x08003000) to the base address of the SRAM at 0x20000000. */
- for(i = 0; i < 48; i++)
- {
- VectorTable = *(__IO uint32_t*)(APPLICATION_ADDRESS + (i<<2));
- }
-
- /* Enable the SYSCFG peripheral clock*/
- //RCC_APB2PeriphResetCmd(RCC_APB2Periph_SYSCFG, ENABLE);
- RCC_APB2PeriphClockCmd(RCC_APB2Periph_SYSCFG, ENABLE); //需要修改成这样
- /* Remap SRAM at 0x00000000 */
- SYSCFG_MemoryRemapConfig(SYSCFG_MemoryRemap_SRAM);
-
- /...
- }
|
|