OpenEdv-开源电子网

 找回密码
 立即注册
正点原子全套STM32/Linux/FPGA开发资料,上千讲STM32视频教程免费下载...
查看: 3684|回复: 1

MINI板STM32f103rbt6的内存管理实验出现如下问题:

[复制链接]

24

主题

51

帖子

0

精华

中级会员

Rank: 3Rank: 3

积分
248
金钱
248
注册时间
2015-7-24
在线时间
32 小时
发表于 2016-8-16 23:23:41 | 显示全部楼层 |阅读模式
1金钱
MINI板STM32f103rbt6没有扩展内存,经查STM32f103rbt6的内置内存为20KByte。因此在malloc.h中设置


#define MEM_BLOCK_SIZE                        32                                                            //内存块大小32字节
#define MEM_MAX_SIZE                        20*1024                                                  //整个内存大小20K字节
#define MEM_ALLOC_TABLE_SIZE        MEM_MAX_SIZE/MEM_BLOCK_SIZE         //内存表大小为640



但是编译出错如下
compiling usmart_config.c...
compiling usmart_str.c...
compiling malloc.c...
linking...
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching malloc.o(.bss).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching startup_stm32f10x_md.o(STACK).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching startup_stm32f10x_md.o(HEAP).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching usmart_config.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching usart.o(.bss).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching libspace.o(.bss).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching usmart.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching system_stm32f10x.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching stm32f10x_rcc.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching malloc.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching lcd.o(.bss).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching usart.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching lcd.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching delay.o(.data).
..\OBJ\MALLOC.axf: Error: L6406E: No space in execution regions with .ANY selector matching key.o(.data).
..\OBJ\MALLOC.axf: Error: L6407E: Sections of aggregate size 0x5dc8 bytes could not fit into .ANY selector(s).
Not enough information to list image symbols.
Not enough information to list the image map.
Finished: 2 information, 0 warning and 16 error messages.
"..\OBJ\MALLOC.axf" - 16 Error(s), 0 Warning(s).
Target not created.
Build Time Elapsed:  00:00:14


请问为什么????????????????????????????????

最佳答案

查看完整内容[请看2#楼]

当#define MEM_MAX_SIZE 20*1024 出错 当#define MEM_MAX_SIZE 19*1024 出错 当#define MEM_MAX_SIZE 18*1024 出错 当#define MEM_MAX_SIZE 17*1024 出错 当#define MEM_MAX_SIZE 16*1024 编译通过
正点原子逻辑分析仪DL16劲爆上市
回复

使用道具 举报

24

主题

51

帖子

0

精华

中级会员

Rank: 3Rank: 3

积分
248
金钱
248
注册时间
2015-7-24
在线时间
32 小时
 楼主| 发表于 2016-8-16 23:23:42 | 显示全部楼层
当#define    MEM_MAX_SIZE      20*1024  出错
当#define    MEM_MAX_SIZE      19*1024  出错
当#define    MEM_MAX_SIZE      18*1024  出错
当#define    MEM_MAX_SIZE      17*1024  出错

当#define    MEM_MAX_SIZE      16*1024  编译通过
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则



关闭

原子哥极力推荐上一条 /2 下一条

正点原子公众号

QQ|手机版|OpenEdv-开源电子网 ( 粤ICP备12000418号-1 )

GMT+8, 2025-6-5 12:29

Powered by OpenEdv-开源电子网

© 2001-2030 OpenEdv-开源电子网

快速回复 返回顶部 返回列表