【正文】
畢業(yè)設(shè)計(論文) 題 目 : 基于單片機的 6 層電梯模擬系統(tǒng)設(shè)計 學(xué) 院: 電子信息學(xué)院 專業(yè)班級: 電氣工程及其自動化 2021 級 2 班 指導(dǎo)教師: 盧嫚 職稱: 助理工程師 學(xué)生姓名: 王力剛 學(xué) 號: 41003040223 西安工程大學(xué) 本科 畢業(yè)設(shè)計(論文) I 西安工程大學(xué) 本科 畢業(yè)設(shè)計(論文) II 摘 要 本文介紹了 以 AT89C52 單片機為核心控制器件的電 梯自動控制系統(tǒng) , 包括課題概述、方案論證、硬件設(shè)計、軟件設(shè)計、系統(tǒng)調(diào)試等幾個部分。 該系統(tǒng)采用單片機作為控制核心,通過掃描內(nèi)外按鍵 按下與否引起的電平的改變,作為用戶請求信息發(fā)送到單片機 ,單片機根據(jù)樓層檢測結(jié)果控制電機停在目標(biāo)樓層。硬件部分主要由單片機最小系統(tǒng)模塊、樓層檢測模塊、 層位數(shù)碼管顯示、按鍵掃描模塊 、 上下行呼叫指示電路 等部分組成 。軟件部分介紹了系統(tǒng)程序設(shè) 計思路、程序功能分析,著重介紹了主程序的邏輯結(jié)構(gòu),還分別介紹了 演示功能、按鍵掃描、層位讀取、顯示、電梯控制邏輯等子程序的結(jié)構(gòu)和功能。 軟件部分使用 C 語言,利 用中斷方式來檢測樓層的檢測信息,并送到數(shù)碼管進行顯示。硬件設(shè)計簡單可靠,結(jié)合軟件,基本實現(xiàn)了六層電梯運行的模擬。 此外,利用單片機控制電梯有 成本低、通用性強 、 靈活性大 及易于實現(xiàn)復(fù)雜控制 等 優(yōu)點。 關(guān)鍵詞 : AT89C52 單片機 ; 仿真調(diào)試 ; 電梯 西安工程大學(xué) 本科 畢業(yè)設(shè)計(論文) III ABSTRACT This paper introduces the AT89C52 microcontroller as the core control device of the elevator control system, including the issues outlined, program feasibility studies, hardware design, software design, system debugging, and several other system uses a microcontroller as the control centre, Firstly, it is by scanning the internal and external level change caused by keyboard to be a user requests information to the microcontroller, The next is that the single chip controls the motor based on test results floors stopped in the target floor. Hardware part mainly are made of the microcontroller, floor detection module, level digital display, electric motor drive module, key scan module, alarm module, circuit directions up and down the line calls and other detection uses optical sensors. When elevator goes to the appropriate floor, Photoelectric sensors produce level changes sent to the microcontroller to determine the floor,.The part of motor control uses H Bridge type circuit to control the DC motor .Software ponents intorduce System programming design ideas, procedures, functional analysis . It is not only focusing on the logical design of the main structure but also separately introduced the warning function, the demonstration function, the pressed key scanning, the position read, the demonstration, the lift control logic small steelyard procedure structure and the function. Software ponents use C language. This realization way is the use of Interrupt mode to detect the information of the floor sent to the Digital tube . The hardware design of the system bined with the software is simple and reliable. So It is basically to achieve simulation of elevator running five addition to this, there are advantages of low cost,strong monality,flexibility and easily to realize plex control and so on to the singlechip microputer control of elevator. Key words:AT89C52 Microcontroller,Digital tube,elevator 西安工程大學(xué) 本科 畢業(yè)設(shè)計(論文) IV 目 錄 第 1 章 緒論 ................................................................. 1 設(shè)計背景 .............................................................. 1 設(shè)計目的 .............................................................. 2 設(shè)計意義 .............................................................. 2 第 2 章 方案論證 ............................................................. 3 設(shè)計要求 .............................................................. 3 系統(tǒng)的結(jié)構(gòu)框圖 ........................................................ 3 電動機的選擇 .......................................................... 4 AT89C52 單片機 ........................................................ 4 電路圖制作軟件 PROTUES ................................................. 5 C51 的程序開發(fā)軟件 KEIL ................................................. 5 第 3 章 硬件系統(tǒng)的設(shè)計 ....................................................... 7 硬件設(shè)計思路 .......................................................... 7 時鐘電路 .............................................................. 8 復(fù)位電路 .............................................................. 8 中斷電路 .............................................................. 9 數(shù)碼管顯示模塊 ........................................................ 9 按鈕控制電路模塊 ..................................................... 10 模擬電路圖 ........................................................... 11 第 4 章 軟件 系統(tǒng)的設(shè)計 ...................................................... 12 程序設(shè)計思路 ......................................................... 12 程序流程圖 ........................................................... 12 第 5 章 電路仿真及調(diào)試 ...................................................... 17 第 6 章 結(jié)束語 .............................................................. 20 西安工程大學(xué) 本科 畢業(yè)設(shè)計(論文) V