【正文】
構(gòu)簡單、價(jià)格便宜、制造方便 和容易維護(hù),但是它的良好啟動(dòng)、制動(dòng)性能以及在廣泛的范圍內(nèi)平滑的調(diào)速使得它就在當(dāng)今依然是自動(dòng)調(diào)速的系統(tǒng)的主要形式。運(yùn)用低成本的自動(dòng)化技術(shù)不僅有益于獲得經(jīng)濟(jì)效益,而且還能提高生產(chǎn)率。 關(guān)鍵字 : 單片機(jī); PWM; 直流電機(jī) II Abstract In this paper, it is designed by using PWM speed control system to control the speed of DCmotor based microcontroller. PWM speed control system can improve the speed range and speed accuracy, it also can improved speed performance, power and power factor. Controlled object in the design of the system is a 5V DCmotor controlled by MCS51 microcontroller as the core, using LCD1602 as the display device. Based which we can begin the hardware and software design. The hardware circuit is designed by the software of Protel which contains the circuit design of the liquid crystal display, the keyboard control circuit, clock circuit and reset circuit, the Hallspeed circuit and drive circuit. Software development platform used in the Keil C language, the program is modular in design, including liquid crystal display program, the keyboard control program and clock interrupt routine. The system uses voltage DCmotor PWM speed control method. Overall design includes two parts of software and hardware design. The DCmotor is controlled through the use of single chip PWM control signal, and detailed pulsewidth modulation (PWM) control theory, the working principle of DCmotor and mathematical models and Hbridge circuit with the basic principles of design of the drive circuit. Hardware circuit simulations, indicates that the system is operating normally and each functional module is feasible, especially control precision is relatively high. The system can meet the basic requirements. Key words: Single Chip Microcontroller; PWM; DCmotor III 目 錄 緒 論 ........................................................................................................................................ 1 1 系統(tǒng)的總體分析與器件的選擇 .......................................................................................... 3 本系統(tǒng)的設(shè)計(jì)方案 .................................................................................................... 3 單片機(jī)電路的介紹 .................................................................................................... 3 2 系統(tǒng)硬件結(jié)構(gòu)的設(shè)計(jì) .......................................................................................................... 7 時(shí)鐘電路 的設(shè)計(jì) ........................................................................................................ 7 復(fù)位電路的設(shè)計(jì) ........................................................................................................ 8 液晶顯示器電路的設(shè)計(jì) ............................................................................................ 9 液晶顯示元件的選擇 ...................................................................................... 9 液晶顯示元件 1602 ......................................................................................... 9 液晶顯示電路設(shè)計(jì) ........................................................................................ 11 鍵盤控制電路的設(shè)計(jì) .............................................................................................. 12 霍爾測速電路的設(shè)計(jì) .............................................................................................. 13 驅(qū)動(dòng)電路的設(shè)計(jì) ...................................................................................................... 14 直流電機(jī)簡介 ................................................................................................ 14 直流電機(jī)調(diào)速 ................................................................................................ 16 H 型橋驅(qū)動(dòng)電路 ............................................................................................ 16 3 系統(tǒng)軟件程序的設(shè)計(jì) ........................................................................................................ 19 系統(tǒng)的軟件主程序設(shè)計(jì) .......................................................................................... 19 系統(tǒng)初始化子程序設(shè)計(jì) .......................................................................................... 20 LCD 液晶驅(qū)動(dòng)子程序設(shè)計(jì) ..................................................................................... 21 鍵盤控制子程序設(shè)計(jì) .............................................................................................. 22 時(shí)鐘中斷子程序設(shè)計(jì) .............................................................................................. 22 4 系統(tǒng)的調(diào)試 ........................................................................................................................ 24 硬件調(diào)試 .................................................................................................................. 24 軟件調(diào)試 .................................................................................................................. 25 系統(tǒng)的編譯器和燒錄軟件 ...................................................................................... 26 結(jié) 論 ...................................................................................................................................... 34 IV 致 謝 ...................................................................................................................................... 35 參考文獻(xiàn) .................................................................................................................................. 36 附錄 A 英文原文 .................................................................................................................. 37 附錄 B 漢語翻譯 ................................................................................................................... 45 附錄 C 直流電機(jī) PWM 控制系統(tǒng)原理圖 ........................................................................... 52 附錄 D 直流電機(jī) PWM 控制系統(tǒng)程序 ............................................................................... 53 附錄 E 元件清單 ................................................................................................................... 59