移植汉字显示程序,提示内存空间不够?

2019-07-21 01:01发布

程序编译之后出现多条关于内存空间不够的报错,主芯片是STM32F103C8T6,MDK->Target里的默认设置IROM1 size: 0x10000, IRAM1 size: 0x5000
把IROM1/IRAM1 size分别改成0x40000/0x10000(显然与实际不符)后编译通过,请问不做这项改动的情况下有什么办法通过编译吗?

.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching malloc.o(.bss).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching flash.o(.bss).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching startup_stm32f10x_md.o(STACK).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching exfuns.o(.data).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching usart.o(.bss).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching malloc.o(.data).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching stm32f10x_rcc.o(.data).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching rtc.o(.bss).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching ff.o(.data).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching usart.o(.data).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching rtc.o(.data).
.ObjectsTM.axf: Error: L6406E: No space in execution regions with .ANY selector matching mmc_sd.o(.data).
.ObjectsTM.axf: Error: L6407E: Sections of aggregate size 0xaae4 bytes could not fit into .ANY selector(s).
Not enough information to list image symbols.
Not enough information to list load addresses in the image map.

友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
该问题目前已经被作者或者管理员关闭, 无法添加新回复
5条回答
245925587
1楼-- · 2019-07-21 05:37
malloc.h这个文件里面的东西,你可以修改的
awsawzj
2楼-- · 2019-07-21 07:58
 精彩回答 2  元偷偷看……
yklstudent
3楼-- · 2019-07-21 08:11
实际芯片硬件资源就没有那么多,那改动编译够不能运行也没什么用,想办法优化代码,要么就换芯片
candylife9
4楼-- · 2019-07-21 13:41
 精彩回答 2  元偷偷看……
袁超
5楼-- · 2019-07-21 18:25
245925587 发表于 2019-5-22 11:46
malloc.h这个文件里面的东西,你可以修改的

目前将MEM_MAX_SIZE设到10k可以用了,谢谢!就是不知道后面工程变大会不会还是不够

一周热门 更多>