導航:首頁 > 源碼編譯 > c語言編譯器畢業設計

c語言編譯器畢業設計

發布時間:2024-10-07 05:04:46

1. 單片機的畢業論文怎麼寫

一、畢業設計題目及要求 (2個) 1、基於單片機控制的電動機Y-△啟動的設計 要求:1)控制器為單片機,電動機為三相非同步電動機;2)啟動時間為3秒;3)由按鍵設置電動機Y-△運行、停止。 2、基於單片機控制的可調直流穩壓電源的設計 要求:1)控制器為單片機,電壓輸出范圍為0-10V,電壓精度為0.1V;2)通過數碼管顯示電壓值;3)由按鍵設置電壓值。 二、畢業設計用到的主要軟體(及功能) 畢業設計用到的主要軟體(及功能):Keil 51(源程序編譯),Proteus(電路模擬),AutoCAD(繪圖), Visio(繪流程圖), Protel 99SE(原理圖電路設計,PCB板製作) 三、單片機方面畢業設計要求 1、學會編寫程序(用C語言或匯編語言),用Keil 51軟體對源程序進行編譯。 2、學會用Proteus電路模擬軟體對所設計的硬體電路進行模擬。 3、在寫畢業論文時,學會用Word、AutoCAD, Visio,Protel 99SE等軟體對程序流程圖、電路原理圖等進行繪制。 相關答案 ↓位朋友,以51單片機為例。51現在很多都是用模擬器來進行在線調試的,而每個公司的模擬器都會有自帶的編程軟體,當然,跟keil是差不了多少的。 步驟大體如下: 1.新建,進行程序的編寫 2.連上模擬器或燒寫器,這一步有可能要對模擬器或燒寫器進行設置,具體可看它們的使用說明 3.對程序進行編譯,這一步會自動檢測你的程序有沒錯,如果有錯,是不能進入下一步的.如果你用的是模擬器,這一步編譯成功後就可以直接運行進行在線調試了。 4.如果用的是燒寫器,那就進行燒寫 各個軟體和調試方法會有些不同,但大體就是這樣,一些調試工具的說明書也有很詳細的說明。 學參數測量技術涉及范圍廣,特別是微電壓、微電流、高電壓以及待測信號強弱相差極大的情況下,既要保證弱信號的測量精度又要兼顧強信號的測量范圍,在技術上有一定的難度。傳統的低成本儀表在測量電壓、電阻時都採用手動選擇檔位的方法來轉換量程。在使用中,當忘記轉換檔位時,會造成儀表測量精度下降或損壞。 現代電子測量對系統的精度要求越來越高且智能化程度也越來越高。全量程無檔自動量程轉換電壓表和電阻表是在保證測量精度不下降的前提條件下省去手動轉換量程的工作,得到了廣泛應用。 本文介紹了一種基於AT89S52 單片機 的智能多用表。該表能在單片機的控制下完成直流電壓、電阻和直流電流的測量。測量電流部分採用了簡單的I/V轉換電路完成測試;測量電壓部分結合模擬開關CD4051和運算放大器OP07構成程式控制放大器,實現了自動量程轉換;測量電阻部分也由模擬開關CD4051和運算放大器OP07相結合,在單片機控制下完成了自動量程轉換。電流、電壓和電阻的最終測量信號都在單片機的控制下由12位A/D轉換器TLC2543進行採集,採集的信號經單片機數據處理後通過LCD(12864)顯示出來,測量結果還可以由帶有串列EEPROM的CPU存儲器和監控器的X25045進行多個數據保存。 關鍵詞:TLC2543 自動量程轉換 程式控制增益放大器 電壓 電阻 電流 目錄 摘要1 Abstract 2 第一章 緒論 5 1. 1 概述 5 1. 2 智能儀器/儀表國內外發展概況 5 1. 3 課題研究目的及意義 6 第二章 系統結構及功能介紹 8 2. 1 系統功能和性能指標 8 2. 1. 1 儀表功能 8 2. 1. 2 性能指標 8 2. 1. 3 本機特色 8 2. 1. 4 系統使用說明 9 2. 2 系統工作原理概述 9 第三章 方案設計與論證 11 3. 1 量程選擇的設計與論證 11

2. 學習編譯原理之前,除了需要學習c語言外,還需要學什麼

主要是會數學邏輯,你可以看看離散數學,其實話說回來 主要看你學編譯原理用來干什麼了,如果只學理論 你會發現你學完以後依然不知道怎麼具體運用,只能知道大概的程序編譯過程, 如果你想可以自己也能寫出詞法分析器語法分析器 甚至語義分析 那麼 你最重要的是學好數據結構,我的畢業設計是C語言編譯器 剛開始我覺得自動機什麼的 是難點 可是到後來我才發現 最重要的是要有良好的數據結構的運用能力 數據結構是一切程序的靈魂!沒有合理的存儲結構 程序就像沒有根基的浮萍

3. 用C語言編程預測身高的畢業設計怎麼做

每個做父母的都關心自己孩子成人後的身高,據有關生理衛生知識與數理統計分析表明:影響小孩成人後的身高的因素包括遺傳,飲食習慣與體育鍛煉等,小孩成人後的身高與其父母和身高和自身的性別密切相關.
設faHeight為其父身高,moHeight為其母身高
身高預測公式為:
男性成人時身高=(faHeight+moHeight)×0.54cm
女性成人時身高=(faHight×0.923+moHeight)/2cm
此外如果喜愛體育鍛煉,那麼可增加身高2%,如果有良好的衛生飲食習慣,那麼可增加身高1.5%.
編程從鍵盤輸入用戶的性別(用字元型變數 ----存儲,輸入字元F表示為女性.輸入字元M表示男性),父母身高用實型變數存儲.faHight為其父身高,moHeight為其母身高.是否愛體育鍛煉(用字元型變數sport存儲,輸入字元Y表示喜愛,輸入字元N表示不喜愛)是否有良好的飲食習慣等條件(用字元型變數diet存儲,輸入字元Y表示良好,輸入字元N表示不好)利用公給定公式和身高預測方法去對身高進行預測.

4. 求助如何找到關於單片機的外文文獻翻譯,用於畢業設計

Getting Started with µVision2
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 moles and libraries, create HEX files, and debug your target program.
 µVision2 for Windows™ is an Integrated Development 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 moles from your C source code.
 The A51 Macro Assembler creates relocatable object moles from your 8051 assembly source code.
 The BL51 Linker/Locator combines relocatable object moles created by the C51 Compiler and the A51 Assembler into absolute object moles.
 The LIB51 Library Manager combines object moles into libraries that may be used by the linker.
 The OH51 Object-HEX Converter creates Intel HEX files from absolute object moles.
 The RTX-51 Real-time Operating System simplifies the design of complex, time-critical software projects.
Software Development Cycle
When you use the Keil Software tools, the project development cycle is roughly the same as it is for any other software development 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 IDE
The µVision2 IDE combines 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 your embedded application and provides a single focal point for your development efforts.
LIB51 Library Manager
The 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 object moles that may be used by the linker at a later time. When the linker processes a library, only those object moles in the library that are necessary to create the program are used.
BL51 Linker/Locator
The BL51 linker creates an absolute object mole using the object moles extracted from libraries and those created by the compiler and assembler. An absolute object file or mole 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 and target debugging,
 With an in-circuit emulator for the program testing.
µVision2 Debugger
The µ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 peripherals 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 on
real target hardware:
 Install the MON51 Target Monitor on your target system and 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-51
The µVision2 Debugger supports target debugging using Monitor-51. The monitor program 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, symbolic debugging on your target hardware.
RTX51 Real-Time Operating System
The RTX51 real-time operating system 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 use. Task description tables and operating system consistency are automatically controlled by the BL51 linker/locator.
C51 Optimizing C Cross Compiler
The Keil C51 Cross Compiler is an ANSI C Compiler that was written
specifically to generate fast, compact code for the 8051 microcontroller family.
The C51 Compiler generates object code that matches the efficiency and speed
of assembly programming.
Using a high-level language like C has many advantages over assembly language
programming:
 Knowledge of the processor instruction set is not required. Rudimentary knowledge of the memory structure of the 8051 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 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 is drastically reced.
 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 molar program construction techniques.
 The language C is a very 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 Optimizations
The C51 Compiler is an 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 code to proce 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.
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 Optimizations
 Constant Folding: Constant 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 program.
 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 arguments
 may be passed in registers.
 Global Common Subexpression Elimination: 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 are moved in front of a function to rece 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文件,調試你的目標程序。
Windows應用程序uVision2是一個集成開發環境,它把項目管理,源代碼編輯,程序調試等集成到一個功能強大的環境中。
 C51美國標准優化C交叉編譯器從你的C源代碼產生可重定位的目標文件。
 A51宏匯編器從你的8051匯編源代碼產生可重定位的目標文件。
 BL51連接/重定位器組合你的由C51和A51產生的可重定位的目標文件,生成絕對目標文件。
 LIB51庫管理器組合你的目標文件,生成可以被連接器使用的庫文件。
 OH51目標文件到HEX格式的轉換器從絕對目標文件創建Intel HEX 格式的文件。
 RTX-51實時操作系統簡化了復雜和對時間要求敏感的軟體項目。
軟體開發流程
當你使用Keil Software工具時,你的項目開發流程和其它軟體開發項目的流程極其相似。
1. 創建一個項目,從器件庫中選擇目標器件,配置工具設置。
2. 用C語言或匯編語言創建源程序。
3. 用項目管理器實現你的應用。
4. 修改源程序中的錯誤。
5. 測試,連接應用。
uVision2 IDE
uVision2 集成開發環境集成了一個項目管理器,一個功能豐富、有錯誤提示的編輯器,以及設置選項,生成工具,在線幫助。利用uVision2創建你的源代碼並把它們組織到一個能確定你的目標應用的項目中去。uVision2自動編譯,匯編,連接你的嵌入式應用,並為你的開發提供一個單一的焦點。
C51編譯器和A51匯編器
源代碼由uVision2 IDE創建,並被C51編譯或A51匯編。編譯器和匯編器從源代碼生成可重定位的目標文件。Keil C51編譯器完全遵照ANSI C語言標准,支持C語言的所有標准特性。另外,直接支持8051結構的幾個特性被添加到裡面。Keil A51宏匯編器支持8051及其派生系列的全部指令集。
LIB51 庫管理器
LIB51庫管理器允許你從由編譯器或匯編器生成的目標文件創建目標庫。庫是一種被特別地組織過並在以後可以被連接重用的對象模塊。當連接器處理一個庫時,僅僅那些被使用的目標模塊才被真正使用。
BL51 連接器/定位器
BL51 連接器/定位器利用從庫中提取的目標模塊和由編譯器或匯編器生成的目標模塊創建一個絕對地址的目標模塊。一個絕對地址目標模塊或文件包含不可重定位的代碼和數據。所有的代碼和數據被安置在固定的存儲器單元中。此絕對地址目標文件可以用來:
 寫入EPROM或其它存儲器件。
 由uVision2調試器使用來模擬和調試。
 由模擬器用來測試程序。
uVision2 調試器
uVision2源代碼級調試器是一個理想地快速,可靠的程序調試器。此調試器包含一個高速模擬器,能夠讓你模擬整個8051系統,包括片上外圍器件和外部硬體。當你從器件庫中選擇器件時,這個器件的特性將自動配置。
uVision2調試器為你在實際目標板上測試你的程序提供了幾種方法:
 安裝MON51目標監控器到你的目標系統並且通過Monitor-51介面下載你的程序。
 利用高級的GDI(AGDI)介面,把uVision2調試器綁定到你的目標系統。
Monitor-51
uVision2調試器支持用Monitor-51進行目標板調試。此監控程序駐留在你的目標板的 存儲器里,它利用串口和uVision2調試器進行通信。利用Monitor-51,uVision2調試器 可以對你的目標硬體實行源代碼級的調試。
RTX51實時操作系統
RTX51實時操作系統是一個針對8051系列的多任務核。RTX51實時內核從本質上簡化了對實時事件反應速度要求高的復雜應用系統的設計,編程和調試。RTX51實時內核是完全集成到C51編譯器中的,從而方便使用。任務描述表和操作系統的連接由BL51連接器/定位器自動控制。
C51優化的C語言交叉編譯器
Keil C51交叉編譯器是一個基於ANSI C標準的針對8051系列MCU的C編譯器,生成的可執行代碼快速、緊湊,在運行效率和速度上可以和匯編程序得到的代碼相媲美。
和匯編語言相比,用C語言這樣的高級語言有很多優勢,比如:
 對處理器的指令集不必了解,8051 CPU的基本結構可以了解,但不是必須的。
 寄存器的分配以及各種變數和數據的定址都由編譯器完成。
 程序擁有了正式的結構(由C語言帶來的),並且能被分成多個單獨的子函數。這使整個應用系統的結構變得清晰,同時讓源代碼變得可重復使用。
 選擇特定的操作符來操作變數的能力提高了源代碼的可讀性。
 可以運用和人的思維很接近的詞彙和演算法表達式。
 編寫程序和調試程序的時間得到很大程度的縮短。
 C運行連接庫包含一些標準的子程序,如:格式化輸出,數字轉換,浮點運算。
 由於程序的模塊結構技術,使得現有的程序段可以很容易的包含到新的程序中去。
 ANSI 標準的C語言是一種豐常方便的,獲得廣泛應用的,在絕大部分系統中都能夠很容易得到的語言。
因此,如果需要,現有的程序可以很快地移植到其他的處理器上,節省投資。
代碼優化
C51是一個傑出的優化編譯器,它通過很多步驟以確保產生的代碼是最有效率的(最小和/或最快)。編譯器通過分析初步的代碼 產生最終的最有效率的代碼序列,以此來保證你的C語言程序佔用最少空間的同時運行的快而有效。
C51編譯器提供9個優化級別。每個高一級的優化級別都包括比它低的所有優化級別的優化內容。以下列出的是目前C51編譯器提供的所有優化級別的內容:
 常量折疊:在表達式及定址過程中出現的常量被綜合為一個單個的常量。
 跳轉優化:採用反轉跳轉或直接指向最終目的的跳轉,從而提升了程序的效率。
 啞碼消除:永遠不可能執行到的代碼將自動從程序中剔除。
 寄存器變數:只要可能,局部變數和函數參數被放在CPU寄存器中,不需要為這些變數再分配存儲器空間。
 通過寄存器傳遞參數:最多三個參數通過寄存器傳遞。
 消除全局公用的子表達式:只要可能,程序中多次出現的相同的子表達式或地址計算表達式將只計算一次。
 合並相同代碼:利用跳轉指令,相同的代碼塊被合並。
 重復使用入口代碼:需要多次使用的共同代碼被移到子程序的前面以縮減代碼長度。
公共塊子程序:需要重復使用的多條指令被提取組成子程序。指令被重新安排以最大化一個共用子程序的長度。

閱讀全文

與c語言編譯器畢業設計相關的資料

熱點內容
條件加密 瀏覽:628
androidstudio設置中文 瀏覽:641
汽車換壓縮機能提升製冷 瀏覽:628
安卓開發配什麼電腦 瀏覽:607
linux下php模塊 瀏覽:78
阿里雲伺服器終端在哪裡 瀏覽:146
app紙有什麼用 瀏覽:223
cuteftp命令 瀏覽:506
最開始的編程語言是什麼 瀏覽:759
at遠程命令 瀏覽:492
雲伺服器哪家好點 瀏覽:213
android系統源碼閱讀 瀏覽:931
dumpjava分析工具 瀏覽:680
怎麼下載cpu源碼 瀏覽:156
代碼加密怎麼取消 瀏覽:890
編譯原理代碼在哪裡運行 瀏覽:586
解密攝影pdf 瀏覽:76
演算法編程中級題目 瀏覽:253
c語言編譯器畢業設計 瀏覽:718
醫保卡申請app哪個好 瀏覽:950