MDK:ARM M451M:exceed the range of code meory, continue to erase or not?

问题: 代码空间超限

几天前就遇到:exceed the range of code meory, continue to erase or not?

如下所示:

MDK:ARM M451M:exceed the range of code meory, continue to erase or not?

解决过程

开始以为中MDK软件的128KB限制,如是就不能生成HEX文件,应该链接时有提示。不是这个原因。

又想是不是NU-LINK的问题。

后使用优化3将代码缩小了。

但昨天代码增加后又出现这个问题,代码优化无能为力了。想可能是MDK烧写的问题,于是就想用NUVOTON原厂的ICP工具烧写试试,这一试发现了原因,如下图所示:M451M出厂时的FLASH配置是代码只有120KB,数据136KB

MDK:ARM M451M:exceed the range of code meory, continue to erase or not?

解决方法

如下图所示,减小数据FLASH空间为16KB后,代码空间就有240KB了,本问题全美解决。

MDK:ARM M451M:exceed the range of code meory, continue to erase or not?

 

MDK:ARM M451M:exceed the range of code meory, continue to erase or not?

 

遗留问题

在代码中是否可以进行配置。

转载于:https://my.oschina.net/SamXIAO/blog/3053887