急:scatter file ERROR!!!(keil-ARM)

wo_happy 2010-07-03 11:36:53

; *************************************************************
; *** Scatter-Loading Description File generated by uVision ***
; *************************************************************

LR_IROM1 0x00000000 0x10000000 { ; load region size_region
ER_IROM1 0x00000000 0x10000000 { ; load address = execution address
*.o (RESET, +First)
*(InRoot$$Sections)
.ANY (+RO)
}
RW_IRAM1 0x30000000 0x04000000 { ; RW data
.ANY (+RW +ZI)
}
}

连接时错误:
.\Obj\Success.sct(7): error: L6236E: No section matches selector - no section to be FIRST/LAST.
.\Obj\Success.sct: Not enough information to list image symbols.
.\Obj\Success.sct: Not enough information to list the image map.
请问这是怎么回事呀?我把ROM,RAM空间都配置好了呀!

还有,请问在keil下|Image$$...|的这个变量是keil生成的吗,还是需要自己定义?
...全文
1326 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
wo_happy 2010-07-11
  • 打赏
  • 举报
回复
[Quote=引用 6 楼 appadd2008 的回复:]
在startup.s文件中添加如下:
PRESERVE8
AREA RESET, CODE, READONLY
ARM
RESET是什么无所谓,只要和sct文件一致即可
[/Quote]
那样改了,还是不行,我定义了:__EVAL,有用了scatterfile ,没错了,但寄存器又不让写入,不知道怎么了?

IF :LNOT::DEF:__EVAL
IMPORT ||Image$$ER_ROM1$$RO$$Length||
IMPORT ||Image$$RW_RAM1$$RW$$Length||
ENDIF
wo_happy 2010-07-11
  • 打赏
  • 举报
回复


IF WT_SETUP != 0
LDR R0, =WT_BASE
LDR R1, =WTCON_Val
LDR R2, =WTDAT_Val
STR R2, [R0, #WTCNT_OFS] ;被执行时,不允许写
STR R2, [R0, #WTDAT_OFS]
STR R1, [R0, #WTCON_OFS]
ENDIF


*** error 65: access violation at 0x53000008 : no 'write' permission
yoyowar 2010-07-09
  • 打赏
  • 举报
回复
楼上正解
appadd2008 2010-07-08
  • 打赏
  • 举报
回复
在startup.s文件中添加如下:
PRESERVE8
AREA RESET, CODE, READONLY
ARM
RESET是什么无所谓,只要和sct文件一致即可

wo_happy 2010-07-06
  • 打赏
  • 举报
回复
[Quote=引用 2 楼 yashi 的回复:]
先把你的问题说清楚了,你的代码是要做什么?什么环境?

这样无头无脑的问题,谁能解答你?
[/Quote]
scatter file ,烧写时用的,linker生成的。我是在keil下做的。keil下生成的变量有:

Image$$region_name$$Base Execution address of the region.
Image$$region_name$$Length Execution region length in bytes excluding ZI length.
Image$$region_name$$Limit Address of the byte beyond the end of the non-ZI part of the execution region.
Image$$region_name$$RO$$Base Execution address of the RO output section in this region.
Image$$region_name$$RO$$Length Length of the RO output section in bytes.
Image$$region_name$$RO$$Limit Address of the byte beyond the end of the RO output section in the execution region.
Image$$region_name$$RW$$Base Execution address of the RW output section in this region.
Image$$region_name$$RW$$Length Length of the RW output section in bytes.
Image$$region_name$$RW$$Limit Address of the byte beyond the end of the RW output section in the execution region.
Image$$region_name$$ZI$$Base Execution address of the ZI output section in this region.
Image$$region_name$$ZI$$Length Length of the ZI output section in bytes.
Image$$region_name$$ZI$$Limit Address of the byte beyond the end of the ZI output section in the execution region.



我不懂在init.s的文件中import这些变量时,region_name用什么来代替。

keil帮助里还有这么一段话,我不懂是什么意思:
Region name values when not scatter-loading
If you are not using scatter-loading, the linker uses region_name values of:

ER_RO, for read-only execution regions

ER_RW, for read-write execution regions

ER_ZI, for zero-initialized execution regions.

这时import时,应import什么





沈兄:那样改,还是不对
yashi 2010-07-05
  • 打赏
  • 举报
回复
先把你的问题说清楚了,你的代码是要做什么?什么环境?

这样无头无脑的问题,谁能解答你?
shenmou 2010-07-05
  • 打赏
  • 举报
回复
*.o (RESET, +First)

改成

*.o (Init, +First)

也是可以的。
shenmou 2010-07-05
  • 打赏
  • 举报
回复
[Quote=引用 1 楼 wo_happy 的回复:]
2440init.s的代码段名字必须是RESET吗?我把Init改成RESET后,又有新的错误了呀。不就是不懂在keil下是怎样实现程序分散下载的。大侠帮忙,小弟感激涕零!!!
[/Quote]

又出来什么错误?
wo_happy 2010-07-04
  • 打赏
  • 举报
回复
2440init.s的代码段名字必须是RESET吗?我把Init改成RESET后,又有新的错误了呀。不就是不懂在keil下是怎样实现程序分散下载的。大侠帮忙,小弟感激涕零!!!

19,502

社区成员

发帖
与我相关
我的任务
社区描述
硬件/嵌入开发 嵌入开发(WinCE)
社区管理员
  • 嵌入开发(WinCE)社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧