計(jì)算機(jī)外文翻譯 --keil c 簡(jiǎn)介_(kāi)第1頁(yè)
已閱讀1頁(yè),還剩8頁(yè)未讀 繼續(xù)免費(fèi)閱讀

下載本文檔

版權(quán)說(shuō)明:本文檔由用戶(hù)提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)

文檔簡(jiǎn)介

1、<p>  The introduction of keil C</p><p>  The 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 m

2、odules and libraries, create HEX files, and debug your target program.</p><p>  µVision2 for Windows? is an Integrated Development Environment that combines project management, source code editing, and

3、program debugging in one single, powerful environment.</p><p>  The C51 ANSI Optimizing C Cross Compiler creates relocatable object modules from your C source code.</p><p>  The A51 Macro Assemb

4、ler creates relocatable object modules from your 8051 assembly source code.</p><p>  The BL51 Linker/Locator combines relocatable object modules created by the C51 Compiler and the A51 Assembler into absolut

5、e object modules.</p><p>  The LIB51 Library Manager combines object modules into libraries that may be used by the linker.</p><p>  The OH51 Object-HEX Converter creates Intel HEX files from ab

6、solute object modules.</p><p>  The RTX-51 Real-time Operating System simplifies the design of complex, time-critical software projects.</p><p>  Software Development Cycle</p><p> 

7、 When you use the Keil Software tools, the project development cycle is roughly the same as it is for any other software development project. </p><p>  1. Create a project, select the target chip from the de

8、vice database, and configure the tool settings.</p><p>  2. Create source files in C or assembly.</p><p>  3. Build your application with the project manager.</p><p>  4. Correct er

9、rors in source files.</p><p>  5. Test the linked application.</p><p>  µVision2 IDE</p><p>  The µVision2 IDE combines project management, a rich-featured editor with int

10、eractive 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 c

11、ompiles, assembles, and links your embedded application and provides a single focal point for your development efforts.</p><p>  LIB51 Library Manager</p><p>  The LIB51 library manager allows y

12、ou to create object library from the object files created by the compiler and assembler. Libraries are specially formatted, ordered program collections of object modules that may be used by the linker at a later time. Wh

13、en the linker processes a library, only those object modules in the library that are necessary to create the program are used.</p><p>  BL51 Linker/Locator</p><p>  The BL51 linker creates an ab

14、solute object module using the object modules extracted from libraries 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

15、fixed memory locations. The absolute object file may be used:</p><p>  To program an EPROM or other memory devices,</p><p>  With the µVision2 Debugger for simulation and target debugging,&

16、lt;/p><p>  With an in-circuit emulator for the program testing.</p><p>  µVision2 Debugger</p><p>  The µVision2 symbolic, source-level debugger is ideally suited for fast,

17、reliable program debugging. The debugger includes a high-speed simulator that let you simulate an entire 8051 system including on-chip peripherals and external hardware. The attributes of the chip you use are automatical

18、ly configured when you select the device from the Device Database.</p><p>  The µVision2 Debugger provides several ways for you to test your programs on</p><p>  real target hardware:</p

19、><p>  Install the MON51 Target Monitor on your target system and download your program using the Monitor-51 interface built-in to the µVision2 Debugger.</p><p>  Use the Advanced GDI interfac

20、e to attach use the µVision2 Debugger front end with your target system.</p><p>  Monitor-51</p><p>  The µVision2 Debugger supports target debugging using Monitor-51. The monitor prog

21、ram resides in the memory 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

22、, symbolic debugging on your target hardware.</p><p>  RTX51 Real-Time Operating System</p><p>  The RTX51 real-time operating system is a multitasking kernel for the 8051 microcontroller family

23、. 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

24、 and is easy to use. Task description tables and operating system consistency are automatically controlled by the BL51 linker/locator.</p><p>  C51 Optimizing C Cross Compiler</p><p>  The Keil

25、C51 Cross Compiler is an ANSI C Compiler that was written</p><p>  specifically to generate fast, compact code for the 8051 microcontroller family.</p><p>  The C51 Compiler generates object cod

26、e that matches the efficiency and speed</p><p>  of assembly programming.</p><p>  Using a high-level language like C has many advantages over assembly language</p><p>  programming

27、:</p><p>  Knowledge of the processor instruction set is not required. Rudimentary knowledge of the memory structure of the 8051 CPU is desirable (but not necessary).</p><p>  Details like regis

28、ter allocation and addressing of the various memory types and data types is managed by the compiler.</p><p>  Programs get a formal structure (which is imposed by the C programming language) and can be divid

29、ed into separate functions. This contributes to source code reusability as well as better overall application structure.</p><p>  The ability to combine variable selection with specific operations improves p

30、rogram readability.</p><p>  Keywords and operational functions that more nearly resemble the human thought process may be used.</p><p>  Programming and program test time is drastically reduced

31、.</p><p>  The C run-time library contains many standard routines such as: formatted output, numeric conversions, and floating-point arithmetic.</p><p>  Existing program parts can be more easil

32、y included into new programs because of modular program construction techniques.</p><p>  The language C is a very portable language (based on the ANSI standard) that enjoys wide popular support and is easil

33、y obtained for most systems.</p><p>  Existing program investments can be quickly adapted to other processors as needed.</p><p>  Code Optimizations</p><p>  The C51 Compiler is an

34、aggressive optimizing compiler that takes numerous steps 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

35、code to produce the most efficient instruction sequences. This ensures that your C program runs as quickly and effectively as possible in the least amount of code space. </p><p>  The C51 Compiler provides n

36、ine 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.</p><p>  General

37、 Optimizations</p><p>  Constant Folding: Constant values occurring in an expression or address calculation are combined as a single constant.</p><p>  Jump Optimizing: Jumps are inverted or ext

38、ended to the final target address when the program efficiency is thereby increased.</p><p>  Dead Code Elimination: Code that cannot be reached (dead code) is removed from the program.</p><p>  

39、Register Variables: Automatic variables and function arguments are located in registers whenever possible. No data memory space is reserved for these variables.</p><p>  Parameter Passing Via Registers: A ma

40、ximum of three function arguments</p><p>  may be passed in registers.</p><p>  Global Common Subexpression Elimination: Identical subexpressions or address calculations that occur multiple time

41、s in a function are recognized and calculated only once whenever possible.</p><p>  Common Tail Merging: Common instruction blocks are merged together using jump instructions.</p><p>  Re-use Co

42、mmon Entry Code: Common instruction sequences are moved in front of a function to reduce code size.</p><p>  Common Block Subroutines: Multiple instruction sequences are packed into subroutines. Instructions

43、 are rearranged to maximize the block size.</p><p><b>  中文譯文</b></p><p><b>  Keil C 簡(jiǎn)介</b></p><p>  Keil Software 的8051開(kāi)發(fā)工具提供以下程序,你可以用它們來(lái)編譯你的C源碼,匯編你的匯編源程序,連接

44、和重定位你的目標(biāo)文件和庫(kù)文件,創(chuàng)建HEX文件,調(diào)試你的目標(biāo)程序。</p><p>  Windows應(yīng)用程序uVision2是一個(gè)集成開(kāi)發(fā)環(huán)境,它把項(xiàng)目管理,源代碼編輯,程序調(diào)試等集成到一個(gè)功能強(qiáng)大的環(huán)境中。</p><p>  C51美國(guó)標(biāo)準(zhǔn)優(yōu)化C交叉編譯器從你的C源代碼產(chǎn)生可重定位的目標(biāo)文件。</p><p>  A51宏匯編器從你的8051匯編源代碼產(chǎn)生可重定

45、位的目標(biāo)文件。</p><p>  BL51連接/重定位器組合你的由C51和A51產(chǎn)生的可重定位的目標(biāo)文件,生成絕對(duì)目標(biāo)文件。</p><p>  LIB51庫(kù)管理器組合你的目標(biāo)文件,生成可以被連接器使用的庫(kù)文件。</p><p>  OH51目標(biāo)文件到HEX格式的轉(zhuǎn)換器從絕對(duì)目標(biāo)文件創(chuàng)建Intel HEX 格式的文件。</p><p>  

46、RTX-51實(shí)時(shí)操作系統(tǒng)簡(jiǎn)化了復(fù)雜和對(duì)時(shí)間要求敏感的軟件項(xiàng)目。</p><p><b>  軟件開(kāi)發(fā)流程</b></p><p>  當(dāng)你使用Keil Software工具時(shí),你的項(xiàng)目開(kāi)發(fā)流程和其它軟件開(kāi)發(fā)項(xiàng)目的流程極其相似。</p><p>  1. 創(chuàng)建一個(gè)項(xiàng)目,從器件庫(kù)中選擇目標(biāo)器件,配置工具設(shè)置。</p><p>

47、;  2. 用C語(yǔ)言或匯編語(yǔ)言創(chuàng)建源程序。</p><p>  3. 用項(xiàng)目管理器實(shí)現(xiàn)你的應(yīng)用。</p><p>  4. 修改源程序中的錯(cuò)誤。</p><p>  5. 測(cè)試,連接應(yīng)用。</p><p>  uVision2 IDE</p><p>  uVision2 集成開(kāi)發(fā)環(huán)境集成了一個(gè)項(xiàng)目管理器,一個(gè)功能豐富

48、、有錯(cuò)誤提示的編輯器,以及設(shè)置選項(xiàng),生成工具,在線幫助。利用uVision2創(chuàng)建你的源代碼并把它們組織到一個(gè)能確定你的目標(biāo)應(yīng)用的項(xiàng)目中去。uVision2自動(dòng)編譯,匯編,連接你的嵌入式應(yīng)用,并為你的開(kāi)發(fā)提供一個(gè)單一的焦點(diǎn)。</p><p>  C51編譯器和A51匯編器</p><p>  源代碼由uVision2 IDE創(chuàng)建,并被C51編譯或A51匯編。編譯器和匯編器從源代碼生成可重定位

49、的目標(biāo)文件。Keil C51編譯器完全遵照ANSI C語(yǔ)言標(biāo)準(zhǔn),支持C語(yǔ)言的所有標(biāo)準(zhǔn)特性。另外,直接支持8051結(jié)構(gòu)的幾個(gè)特性被添加到里面。Keil A51宏匯編器支持8051及其派生系列的全部指令集。</p><p>  LIB51 庫(kù)管理器</p><p>  LIB51庫(kù)管理器允許你從由編譯器或匯編器生成的目標(biāo)文件創(chuàng)建目標(biāo)庫(kù)。庫(kù)是一種被特別地組織過(guò)并在以后可以被連接重用的對(duì)象模塊。當(dāng)

50、連接器處理一個(gè)庫(kù)時(shí),僅僅那些被使用的目標(biāo)模塊才被真正使用。</p><p>  BL51 連接器/定位器</p><p>  BL51 連接器/定位器利用從庫(kù)中提取的目標(biāo)模塊和由編譯器或匯編器生成的目標(biāo)模塊創(chuàng)建一個(gè)絕對(duì)地址的目標(biāo)模塊。一個(gè)絕對(duì)地址目標(biāo)模塊或文件包含不可重定位的代碼和數(shù)據(jù)。所有的代碼和數(shù)據(jù)被安置在固定的存儲(chǔ)器單元中。此絕對(duì)地址目標(biāo)文件可以用來(lái):</p><

51、p>  寫(xiě)入EPROM或其它存儲(chǔ)器件。</p><p>  由uVision2調(diào)試器使用來(lái)模擬和調(diào)試。</p><p>  由仿真器用來(lái)測(cè)試程序。</p><p>  uVision2 調(diào)試器</p><p>  uVision2源代碼級(jí)調(diào)試器是一個(gè)理想地快速,可靠的程序調(diào)試器。此調(diào)試器包含一個(gè)高速模擬器,能夠讓你模擬整個(gè)8051系統(tǒng),

52、包括片上外圍器件和外部硬件。當(dāng)你從器件庫(kù)中選擇器件時(shí),這個(gè)器件的特性將自動(dòng)配置。</p><p>  uVision2調(diào)試器為你在實(shí)際目標(biāo)板上測(cè)試你的程序提供了幾種方法:</p><p>  安裝MON51目標(biāo)監(jiān)控器到你的目標(biāo)系統(tǒng)并且通過(guò)Monitor-51接口下載你的程序。</p><p>  利用高級(jí)的GDI(AGDI)接口,把uVision2調(diào)試器綁定到你的目

53、標(biāo)系統(tǒng)。</p><p>  Monitor-51</p><p>  uVision2調(diào)試器支持用Monitor-51進(jìn)行目標(biāo)板調(diào)試。此監(jiān)控程序駐留在你的目標(biāo)板的 存儲(chǔ)器里,它利用串口和uVision2調(diào)試器進(jìn)行通信。利用Monitor-51,uVision2調(diào)試器 可以對(duì)你的目標(biāo)硬件實(shí)行源代碼級(jí)的調(diào)試。</p><p>  RTX51實(shí)時(shí)操作系統(tǒng)</p&g

54、t;<p>  RTX51實(shí)時(shí)操作系統(tǒng)是一個(gè)針對(duì)8051系列的多任務(wù)核。RTX51實(shí)時(shí)內(nèi)核從本質(zhì)上簡(jiǎn)化了對(duì)實(shí)時(shí)事件反應(yīng)速度要求高的復(fù)雜應(yīng)用系統(tǒng)的設(shè)計(jì),編程和調(diào)試。RTX51實(shí)時(shí)內(nèi)核是完全集成到C51編譯器中的,從而方便使用。任務(wù)描述表和操作系統(tǒng)的連接由BL51連接器/定位器自動(dòng)控制。</p><p>  C51優(yōu)化的C語(yǔ)言交叉編譯器</p><p>  Keil C51交叉編

55、譯器是一個(gè)基于ANSI C標(biāo)準(zhǔn)的針對(duì)8051系列MCU的C編譯器,生成的可執(zhí)行代碼快速、緊湊,在運(yùn)行效率和速度上可以和匯編程序得到的代碼相媲美。 </p><p>  和匯編語(yǔ)言相比,用C語(yǔ)言這樣的高級(jí)語(yǔ)言有很多優(yōu)勢(shì),比如:</p><p>  對(duì)處理器的指令集不必了解,8051 CPU的基本結(jié)構(gòu)可以了解,但不是必須的。</p><p>  寄存器的分配以及各種變量

56、和數(shù)據(jù)的尋址都由編譯器完成。</p><p>  程序擁有了正式的結(jié)構(gòu)(由C語(yǔ)言帶來(lái)的),并且能被分成多個(gè)單獨(dú)的子函數(shù)。這使整個(gè)應(yīng)用系統(tǒng)的結(jié)構(gòu)變得清晰,同時(shí)讓源代碼變得可重復(fù)使用。</p><p>  選擇特定的操作符來(lái)操作變量的能力提高了源代碼的可讀性。</p><p>  可以運(yùn)用和人的思維很接近的詞匯和算法表達(dá)式。</p><p>  

57、編寫(xiě)程序和調(diào)試程序的時(shí)間得到很大程度的縮短。</p><p>  C運(yùn)行連接庫(kù)包含一些標(biāo)準(zhǔn)的子程序,如:格式化輸出,數(shù)字轉(zhuǎn)換,浮點(diǎn)運(yùn)算。</p><p>  由于程序的模塊結(jié)構(gòu)技術(shù),使得現(xiàn)有的程序段可以很容易的包含到新的程序中去。</p><p>  ANSI 標(biāo)準(zhǔn)的C語(yǔ)言是一種豐常方便的,獲得廣泛應(yīng)用的,在絕大部分系統(tǒng)中都能夠很容易得到的語(yǔ)言。</p>

58、<p>  因此,如果需要,現(xiàn)有的程序可以很快地移植到其他的處理器上,節(jié)省投資。</p><p><b>  代碼優(yōu)化 </b></p><p>  C51是一個(gè)杰出的優(yōu)化編譯器,它通過(guò)很多步驟以確保產(chǎn)生的代碼是最有效率的(最小和/或最快)。編譯器通過(guò)分析初步的代碼 產(chǎn)生最終的最有效率的代碼序列,以此來(lái)保證你的C語(yǔ)言程序占用最少空間的同時(shí)運(yùn)行的快而有效。

59、</p><p>  C51編譯器提供9個(gè)優(yōu)化級(jí)別。每個(gè)高一級(jí)的優(yōu)化級(jí)別都包括比它低的所有優(yōu)化級(jí)別的優(yōu)化內(nèi)容。以下列出的是目前C51編譯器提供的所有優(yōu)化級(jí)別的內(nèi)容:</p><p>  常量折疊:在表達(dá)式及尋址過(guò)程中出現(xiàn)的常量被綜合為一個(gè)單個(gè)的常量。</p><p>  跳轉(zhuǎn)優(yōu)化:采用反轉(zhuǎn)跳轉(zhuǎn)或直接指向最終目的的跳轉(zhuǎn),從而提升了程序的效率。</p>&

60、lt;p>  啞碼消除:永遠(yuǎn)不可能執(zhí)行到的代碼將自動(dòng)從程序中剔除。</p><p>  寄存器變量:只要可能,局部變量和函數(shù)參數(shù)被放在CPU寄存器中,不需要為這些變量再分配存儲(chǔ)器空間。</p><p>  通過(guò)寄存器傳遞參數(shù):最多三個(gè)參數(shù)通過(guò)寄存器傳遞。</p><p>  消除全局公用的子表達(dá)式:只要可能,程序中多次出現(xiàn)的相同的子表達(dá)式或地址計(jì)算表達(dá)式將只計(jì)

溫馨提示

  • 1. 本站所有資源如無(wú)特殊說(shuō)明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶(hù)所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒(méi)有圖紙預(yù)覽就沒(méi)有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 眾賞文庫(kù)僅提供信息存儲(chǔ)空間,僅對(duì)用戶(hù)上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶(hù)上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶(hù)因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。

評(píng)論

0/150

提交評(píng)論