计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc

上传人:文库蛋蛋多 文档编号:2385466 上传时间:2023-02-17 格式:DOC 页数:9 大小:49.50KB
返回 下载 相关 举报
计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc_第1页
第1页 / 共9页
计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc_第2页
第2页 / 共9页
计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc_第3页
第3页 / 共9页
计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc_第4页
第4页 / 共9页
计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc_第5页
第5页 / 共9页
点击查看更多>>
资源描述

《计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc》由会员分享,可在线阅读,更多相关《计算机 外文翻译 外文文献 英文文献 Keil C 简介.doc(9页珍藏版)》请在三一办公上搜索。

1、The introduction of keil CThe Keil Software 8051 development tools listed below are programs you use to compile your C code, assemble your assembly source files, link and locate object modules and libraries, create HEX files, and debug your target program.Vision2 for Windows is an Integrated Develop

2、ment Environment that combines project management, source code editing, and program debugging in one single, powerful environment.The C51 ANSI Optimizing C Cross Compiler creates relocatable object modules from your C source code.The A51 Macro Assembler creates relocatable object modules from your 8

3、051 assembly source code.The BL51 Linker/Locator combines relocatable object modules created by the C51 Compiler and the A51 Assembler into absolute object modules.The LIB51 Library Manager combines object modules into libraries that may be used by the linker.The OH51 Object-HEX Converter creates In

4、tel HEX files from absolute object modules.The RTX-51 Real-time Operating System simplifies the design of complex, time-critical software projects.Software Development CycleWhen you use the Keil Software tools, the project development cycle is roughly the same as it is for any other software develop

5、ment project. 1. Create a project, select the target chip from the device database, and configure the tool settings.2. Create source files in C or assembly.3. Build your application with the project manager.4. Correct errors in source files.5. Test the linked application.Vision2 IDEThe Vision2 IDE c

6、ombines project management, a rich-featured editor with interactive error correction, option setup, make facility, and on-line help. Use Vision2 to create your source files and organize them into a project that defines your target application. Vision2 automatically compiles, assembles, and links you

7、r embedded application and provides a single focal point for your development efforts.LIB51 Library ManagerThe LIB51 library manager allows you to create object library from the object files created by the compiler and assembler. Libraries are specially formatted, ordered program collections of obje

8、ct modules that may be used by the linker at a later time. When the linker processes a library, only those object modules in the library that are necessary to create the program are used.BL51 Linker/LocatorThe BL51 linker creates an absolute object module using the object modules extracted from libr

9、aries and those created by the compiler and assembler. An absolute object file or module contains no relocatable code or data. All code and data reside at fixed memory locations. The absolute object file may be used:To program an EPROM or other memory devices,With the Vision2 Debugger for simulation

10、 and target debugging,With an in-circuit emulator for the program testing.Vision2 DebuggerThe Vision2 symbolic, source-level debugger is ideally suited for fast, reliable program debugging. The debugger includes a high-speed simulator that let you simulate an entire 8051 system including on-chip per

11、ipherals and external hardware. The attributes of the chip you use are automatically configured when you select the device from the Device Database.The Vision2 Debugger provides several ways for you to test your programs onreal target hardware:Install the MON51 Target Monitor on your target system a

12、nd download your program using the Monitor-51 interface built-in to the Vision2 Debugger.Use the Advanced GDI interface to attach use the Vision2 Debugger front end with your target system.Monitor-51The Vision2 Debugger supports target debugging using Monitor-51. The monitor program resides in the m

13、emory of your target hardware and communicates with the Vision2 Debugger using the serial port of the 8051 and a COM port of your PC. With Monitor-51, Vision2 lets you perform source-level, symbolic debugging on your target hardware.RTX51 Real-Time Operating SystemThe RTX51 real-time operating syste

14、m is a multitasking kernel for the 8051 microcontroller family. The RTX51 real-time kernel simplifies the system design, programming, and debugging of complex applications where fast reaction to time critical events is essential. The kernel is fully integrated into the C51 Compiler and is easy to us

15、e. Task description tables and operating system consistency are automatically controlled by the BL51 linker/locator.C51 Optimizing C Cross CompilerThe Keil C51 Cross Compiler is an ANSI C Compiler that was writtenspecifically to generate fast, compact code for the 8051 microcontroller family.The C51

16、 Compiler generates object code that matches the efficiency and speedof assembly programming.Using a high-level language like C has many advantages over assembly languageprogramming:Knowledge of the processor instruction set is not required. Rudimentary knowledge of the memory structure of the 8051

17、CPU is desirable (but not necessary).Details like register allocation and addressing of the various memory types and data types is managed by the compiler.Programs get a formal structure (which is imposed by the C programming language) and can be divided into separate functions. This contributes to

18、source code reusability as well as better overall application structure.The ability to combine variable selection with specific operations improves program readability.Keywords and operational functions that more nearly resemble the human thought process may be used.Programming and program test time

19、 is drastically reduced.The C run-time library contains many standard routines such as: formatted output, numeric conversions, and floating-point arithmetic.Existing program parts can be more easily included into new programs because of modular program construction techniques.The language C is a ver

20、y portable language (based on the ANSI standard) that enjoys wide popular support and is easily obtained for most systems.Existing program investments can be quickly adapted to other processors as needed.Code OptimizationsThe C51 Compiler is an aggressive optimizing compiler that takes numerous step

21、s to ensure that the code generated and output to the object file is the most efficient (smallest and/or fastest) code possible. The compiler analyzes the generated code to produce the most efficient instruction sequences. This ensures that your C program runs as quickly and effectively as possible

22、in the least amount of code space. The C51 Compiler provides nine different levels of optimizing. Each increasing level includes the optimizations of levels below it. The following is a list of all optimizations currently performed by the C51 Compiler.General OptimizationsConstant Folding: Constant

23、values occurring in an expression or address calculation are combined as a single constant.Jump Optimizing: Jumps are inverted or extended to the final target address when the program efficiency is thereby increased.Dead Code Elimination: Code that cannot be reached (dead code) is removed from the p

24、rogram. Register Variables: Automatic variables and function arguments are located in registers whenever possible. No data memory space is reserved for these variables.Parameter Passing Via Registers: A maximum of three function argumentsmay be passed in registers.Global Common Subexpression Elimina

25、tion: Identical subexpressions or address calculations that occur multiple times in a function are recognized and calculated only once whenever possible.Common Tail Merging: Common instruction blocks are merged together using jump instructions.Re-use Common Entry Code: Common instruction sequences a

26、re moved in front of a function to reduce code size.Common Block Subroutines: Multiple instruction sequences are packed into subroutines. Instructions are rearranged to maximize the block size. 中文译文Keil C 简介Keil Software 的8051开发工具提供以下程序,你可以用它们来编译你的C源码,汇编你的汇编源程序,连接和重定位你的目标文件和库文件,创建HEX文件,调试你的目标程序。Wind

27、ows应用程序uVision2是一个集成开发环境,它把项目管理,源代码编辑,程序调试等集成到一个功能强大的环境中。C51美国标准优化C交叉编译器从你的C源代码产生可重定位的目标文件。A51宏汇编器从你的8051汇编源代码产生可重定位的目标文件。BL51连接/重定位器组合你的由C51和A51产生的可重定位的目标文件,生成绝对目标文件。LIB51库管理器组合你的目标文件,生成可以被连接器使用的库文件。OH51目标文件到HEX格式的转换器从绝对目标文件创建Intel HEX 格式的文件。RTX-51实时操作系统简化了复杂和对时间要求敏感的软件项目。软件开发流程当你使用Keil Software工具时

28、,你的项目开发流程和其它软件开发项目的流程极其相似。1. 创建一个项目,从器件库中选择目标器件,配置工具设置。2. 用C语言或汇编语言创建源程序。3. 用项目管理器实现你的应用。4. 修改源程序中的错误。5. 测试,连接应用。uVision2 IDEuVision2 集成开发环境集成了一个项目管理器,一个功能丰富、有错误提示的编辑器,以及设置选项,生成工具,在线帮助。利用uVision2创建你的源代码并把它们组织到一个能确定你的目标应用的项目中去。uVision2自动编译,汇编,连接你的嵌入式应用,并为你的开发提供一个单一的焦点。C51编译器和A51汇编器源代码由uVision2 IDE创建,

29、并被C51编译或A51汇编。编译器和汇编器从源代码生成可重定位的目标文件。Keil C51编译器完全遵照ANSI C语言标准,支持C语言的所有标准特性。另外,直接支持8051结构的几个特性被添加到里面。Keil A51宏汇编器支持8051及其派生系列的全部指令集。LIB51 库管理器LIB51库管理器允许你从由编译器或汇编器生成的目标文件创建目标库。库是一种被特别地组织过并在以后可以被连接重用的对象模块。当连接器处理一个库时,仅仅那些被使用的目标模块才被真正使用。BL51 连接器/定位器BL51 连接器/定位器利用从库中提取的目标模块和由编译器或汇编器生成的目标模块创建一个绝对地址的目标模块。

30、一个绝对地址目标模块或文件包含不可重定位的代码和数据。所有的代码和数据被安置在固定的存储器单元中。此绝对地址目标文件可以用来:写入EPROM或其它存储器件。由uVision2调试器使用来模拟和调试。由仿真器用来测试程序。uVision2 调试器uVision2源代码级调试器是一个理想地快速,可靠的程序调试器。此调试器包含一个高速模拟器,能够让你模拟整个8051系统,包括片上外围器件和外部硬件。当你从器件库中选择器件时,这个器件的特性将自动配置。uVision2调试器为你在实际目标板上测试你的程序提供了几种方法:安装MON51目标监控器到你的目标系统并且通过Monitor-51接口下载你的程序。

31、利用高级的GDI(AGDI)接口,把uVision2调试器绑定到你的目标系统。Monitor-51uVision2调试器支持用Monitor-51进行目标板调试。此监控程序驻留在你的目标板的 存储器里,它利用串口和uVision2调试器进行通信。利用Monitor-51,uVision2调试器 可以对你的目标硬件实行源代码级的调试。RTX51实时操作系统RTX51实时操作系统是一个针对8051系列的多任务核。RTX51实时内核从本质上简化了对实时事件反应速度要求高的复杂应用系统的设计,编程和调试。RTX51实时内核是完全集成到C51编译器中的,从而方便使用。任务描述表和操作系统的连接由BL51

32、连接器/定位器自动控制。C51优化的C语言交叉编译器Keil C51交叉编译器是一个基于ANSI C标准的针对8051系列MCU的C编译器,生成的可执行代码快速、紧凑,在运行效率和速度上可以和汇编程序得到的代码相媲美。 和汇编语言相比,用C语言这样的高级语言有很多优势,比如:对处理器的指令集不必了解,8051 CPU的基本结构可以了解,但不是必须的。寄存器的分配以及各种变量和数据的寻址都由编译器完成。程序拥有了正式的结构(由C语言带来的),并且能被分成多个单独的子函数。这使整个应用系统的结构变得清晰,同时让源代码变得可重复使用。选择特定的操作符来操作变量的能力提高了源代码的可读性。可以运用和人

33、的思维很接近的词汇和算法表达式。编写程序和调试程序的时间得到很大程度的缩短。C运行连接库包含一些标准的子程序,如:格式化输出,数字转换,浮点运算。由于程序的模块结构技术,使得现有的程序段可以很容易的包含到新的程序中去。ANSI 标准的C语言是一种丰常方便的,获得广泛应用的,在绝大部分系统中都能够很容易得到的语言。因此,如果需要,现有的程序可以很快地移植到其他的处理器上,节省投资。代码优化 C51是一个杰出的优化编译器,它通过很多步骤以确保产生的代码是最有效率的(最小和/或最快)。编译器通过分析初步的代码 产生最终的最有效率的代码序列,以此来保证你的C语言程序占用最少空间的同时运行的快而有效。C

34、51编译器提供9个优化级别。每个高一级的优化级别都包括比它低的所有优化级别的优化内容。以下列出的是目前C51编译器提供的所有优化级别的内容:常量折叠:在表达式及寻址过程中出现的常量被综合为一个单个的常量。跳转优化:采用反转跳转或直接指向最终目的的跳转,从而提升了程序的效率。哑码消除:永远不可能执行到的代码将自动从程序中剔除。寄存器变量:只要可能,局部变量和函数参数被放在CPU寄存器中,不需要为这些变量再分配存储器空间。通过寄存器传递参数:最多三个参数通过寄存器传递。消除全局公用的子表达式:只要可能,程序中多次出现的相同的子表达式或地址计算表达式将只计算一次。合并相同代码:利用跳转指令,相同的代码块被合并。重复使用入口代码:需要多次使用的共同代码被移到子程序的前面以缩减代码长度。公共块子程序:需要重复使用的多条指令被提取组成子程序。指令被重新安排以最大化一个共用子程序的长度。

展开阅读全文
相关资源
猜你喜欢
相关搜索
资源标签

当前位置:首页 > 建筑/施工/环境 > 项目建议


备案号:宁ICP备20000045号-2

经营许可证:宁B2-20210002

宁公网安备 64010402000987号