最近在用51单片机SD卡+VS1003来做MP3
可是在调试的时候遇到一个很郁闷的问题,我在main函数里只是调用了一个简短的函数,还有好多函数只是定义了调试过了,还没使用到,但是我这些都放在一个工程里编译就会报错,说是
ADDRESS SPACE OVERFLOW
SPACE: DATA
...
郁闷了,我的main函数里只调用了一个简单的函数啊为什么没调用的函数KEIL也把它给塞进HEX文件里去。。。
请大虾们解决一下小弟这个问题...
(我试过把Memory Model设置为Large (我的STC12C5A60S2内部有1280的XDATA), 可以用,但是考虑到队友那里这样设置的时候不能使用红外的功能了,不知道是为什么。。。,所以不想改Memory Model。更不想手动注释这些没调用的函数,那样太麻烦了。。。)
友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
如下图:
(原文件名:0.jpg)
(原文件名:1.jpg)
如果我把main写成mian。。。
Build target 'Target 1'
compiling main.c...
linking...
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?MIAN?MAIN
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?SD_WAITREADY?MMC_SD
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?_SD_GETCID?MMC_SD
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?SD_GETCAPACITY?MMC_SD
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?_SD_WRITESINGLEBLOCK?MMC_SD
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?_SD_READ_BYTES?MMC_SD
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?_DELAY14_6US?UTILITIES
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?VS_SOFTRESET?VS1003
*** WARNING L16: UNCALLED SEGMENT, IGNORED FOR OVERLAY PROCESS
SEGMENT: ?PR?_VS1003B_WRITEDAT?VS1003
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_GETSECTORADDR?FAT_FS
LENGTH: 0003H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_SETNEXTSECTOR?FAT_FS
LENGTH: 0003H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_SETNEXTCLUSTER?FAT_FS
LENGTH: 0003H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_FILEFIRSTSECTOR?FAT_FS
LENGTH: 0003H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_SD_GETCID?MMC_SD
LENGTH: 0003H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_SD_GETCSD?MMC_SD
LENGTH: 0003H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_VS_WRITEREG?VS1003
LENGTH: 0003H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?MIAN?MAIN
LENGTH: 0001H
*** ERROR L107: ADDRESS SPACE OVERFLOW
SPACE: DATA
SEGMENT: ?DT?_VS_SINTEST?VS1003
LENGTH: 0001H
*** WARNING L1: UNRESOLVED EXTERNAL SYMBOL
SYMBOL: MAIN
MODULE: D:PROGRAM FILESKEILC51LIBC51S.LIB (?C_INIT)
*** WARNING L2: REFERENCE MADE TO UNRESOLVED EXTERNAL
SYMBOL: MAIN
MODULE: D:PROGRAM FILESKEILC51LIBC51S.LIB (?C_INIT)
ADDRESS: 5772H
Program Size: data=152.0 xdata=838 code=24081
Target not created
还能有什么原因???求解答啊。。。。。。。。。。。。。。。。。。。
(原文件名:1.png)
(原文件名:2.png)
我看过网上有文章说加编译开关,可是如果自己的函数库大了的话这也太麻烦了,这明明就是一个很简单的问题,为什么keil公司就是这么笨呢?
-----------------------------------------------------------------------
感谢你的帮助,问题圆满解决了
(希望我下面的内容会对网友有帮助)
首先我一开始照你的意思设置了以后遇到了错误,说要我升级到PK51,我用的是KEIL uvision 4,可能是因为当初没破_解好,去网上找个注_册机就解决了
然后我发现原来这个指令在KEIL的帮助文档里有的,所以说一定要学会看帮助文档才行啊。。。
(原文件名:a.png)
(原文件名:b.png)
(原文件名:c.png)
呵呵,设置成功以后效果不错~
data的大小少了很多了~
一周热门 更多>