参考

MDK-ARM Linker

Scatter File的用法(转载)

keil报错

Rebuild target 'Target 1'
assembling test1.s...
linking...
.\Objects\pro.axf: Error: L6630E: Invalid token start expected number or ( but found n at position 5 on line 5
.\Objects\pro.axf: Error: L6629E: Unmatched parentheses expecting ) but found n at position 5 on line 5
.\Objects\pro.axf: Error: L6226E: Missing base address for region LR_.
.\Objects\pro.sct(5): error: L6292E: Ignoring unknown attribute 'null' specified for region LR_.
.\Objects\pro.sct(5): error: L6228E: Expected '{', found ')...'.
.\Objects\pro.sct: Error: L6372E: Image needs at least one load region.
Not enough information to list image symbols.
Not enough information to list the image map.
Finished: 2 information, 0 warning and 6 error messages.
".\Objects\pro.axf" - 6 Error(s), 0 Warning(s).
Target not created.
Build Time Elapsed: 00:00:00

解决

在options 的Linker选项卡中不要选择Use Memory Layout from Target Dialog

并且把下边自动生成的Scatter file文本框清空。

原因

scatter文件提供内存映象中各个区​​域的分组和放置详细信息。The Memory Areas settings in Target can be used to create a linker scatter file. This requires enabling Use Memory Layout from Target Dialog in the dialog Options for Target - Linker. 勾选了Use Memory Layout from Target Dialog时使用的是The Memory Areas settings in Target Dialog自动生成的scatter文件,不勾选时使用的是scatter file框里的scatter file,你可以对它进行自定义编辑,它的内容一般来说是由取消勾选前由The Memory Areas settings in Target Dialog自动生成的。当你情空scatter框后会在链接命令后指明ro、rw的基地址

--cpu ARM920T *.o
--ro-base 0x00000000 --entry 0x00000000 --rw-base 0x40000000 --strict --summary_stderr --info summarysizes --map --xref --callgraph --symbols
--info sizes --info totals --info unused --info veneers
--list ".\Listings\pro.map"
-o .\Objects\pro.axf



Read/Only Memory Areas中的起始地址和大小对应的是scatter文件中的映像文件的加载地址和加载存储区域的大小;映像文件中RO部分的加载地址等于运行地址;而Read/Write Memory Areas中的地址即RW部分的运行地址。

Use Memory Layout from Target Dialog Scatter File的更多相关文章

  1. Memory Layout for Multiple and Virtual Inheritance

    Memory Layout for Multiple and Virtual Inheritance(By Edsko de Vries, January 2006)Warning. This art ...

  2. Memory Layout (Virtual address space of a C process)

    Memory Layout (Virtual address space of a C process) 分类: C语言基础2012-12-06 23:16 2174人阅读 评论(0) 收藏 举报 f ...

  3. Memory Layout of C Programs

    Memory Layout of C Programs   A typical memory representation of C program consists of following sec ...

  4. Kernel Memory Layout on ARM Linux

    这是内核自带的文档,讲解ARM芯片的内存是如何布局的!比较简单,对于初学者可以看一下!但要想深入理解Linux内存管理,建议还是找几本好书看看,如深入理解Linux虚拟内存,嵌入系统分析,Linux内 ...

  5. 【ARM-Linux开发】Linux内存管理:ARM Memory Layout以及mmu配置

    原文:Linux内存管理:ARM Memory Layout以及mmu配置 在内核进行page初始化以及mmu配置之前,首先需要知道整个memory map. 1. ARM Memory Layout ...

  6. Memory layout of x86_64 in Linux

    Blue : User Space 128TBRed : Kernel Space 512MBThe rest of the address space goes to various parts o ...

  7. C/C++ Memory Layout

    参考 http://www.cnblogs.com/skynet/archive/2011/03/07/1975479.html

  8. C Memory Layout C语言中的内存布局

    在C语言中,内存的主要分为下列几部分: 1. Text/Code Segment 文本/代码区 2. Initialized Data Segments 初始化的数据区 3. Uninitialize ...

  9. Memory layout

    Text Segment       Text Segment,通常也被称为代码段. 为了防止 heap 或是 stack 的溢出,text 段常被安排在 heap 或是 stack 之后. Text ...

随机推荐

  1. 刨根究底字符编码之—UTF-16编码方式

    在网上已经转悠好几天了, 这篇文章让我知道了UTF-16的前世今生, 感谢作者https://cloud.tencent.com/developer/article/1384687 1. UTF-16 ...

  2. MQ的使用场景

    一.消息队列概述消息队列中间件是分布式系统中重要的组件,主要解决应用解耦,异步消息,流量削锋等问题,实现高性能,高可用,可伸缩和最终一致性架构.目前使用较多的消息队列有ActiveMQ,RabbitM ...

  3. vue组件通信之任意级组件之间的通信

    <div id="app"> <comp1></comp1> <comp2></comp2> </div> ...

  4. 51nod 1130 N的阶乘的长度 V2(斯特林近似)

    输入N求N的阶乘的10进制表示的长度.例如6! = 720,长度为3.   Input 第1行:一个数T,表示后面用作输入测试的数的数量.(1 <= T <= 1000) 第2 - T + ...

  5. C/C++编译、链接、运行的基础知识

    0.C/C++从源文件在编译器的作用下先编译成.s的汇编,然后在汇编器的作用下变成.o的可重定向目标文件,然后在链接器的作用下变成可执行文件 1.在项目中设置的编译寻找目录中的.h文件(一般就是inc ...

  6. IDEA添加作者和时间信息

  7. The Little Prince-12/11

    The Little Prince-12/11 最后一段话!!!hha,傻傻的我们...... 成人们对数字情有独钟.如果你为他们介绍一个朋友,他们从不会问你“他的嗓子怎么样?他爱玩什么游戏?他会采集 ...

  8. logger日志模块

    简单配合模式: import logging#简单配置logging.basicConfig(level=logging.DEBUG, format='%(asctime)s %(filename)s ...

  9. javaweb项目中errorPage的问题

    我们的请求找不到时,会跳到错误页面,tomcat提供了一个错误页面,但是不太好.分析:tomcat自带错误页面不好的原因:有一下两点: 1.不好看: 2.不能为seo做出贡献.思考:如何解决以上问题? ...

  10. java321 面向对象编程