【正文】
ple delay program is used to handle the time interval between the pulses to obtain different rotational speed. There are two output states for the step motor. One: when the temperature is over the upper value, the motor rotates reversely (to low the temperature), while when lower than the lower limit value, the motor rotates normally (to raise the temperature)。 it also fits the rugged environment. It is mainly used in people39。這樣做的條件溫度等于設(shè)定值,從而達(dá)到溫度的目標(biāo)。開始主要是指 RAM 的內(nèi)存處理。代碼數(shù)據(jù)是通過港口答 11? A8的輸入( ? 的是)的逆變器 74LS04 由 AT89S51 單片機(jī)和反向輸出。當(dāng)溫度超過上限和下限的值, 輸出低電平使晶體管上,然后由一個報警蜂鳴器定 。該系統(tǒng)的功能是由輸入的數(shù)據(jù)接收單片機(jī) AT89S51。在DS1302的服務(wù)于帶有日歷時鐘系統(tǒng),用于監(jiān)測的時間。它是在并行或串行方式連接到外部 CPU[7]。因此,外部電源供應(yīng)使用,而第二個接腳連接到引腳 可單片機(jī) AT89S51。所有的傳感器部分和轉(zhuǎn)換電路集成在一個晶體管集成電路像 [1]。 III. 硬件設(shè)計(jì) A. 微控制器 在 AT89S51單片機(jī)是一種低功耗,高性能 CMOS 8位 4K 的系統(tǒng)內(nèi)可編程閃存字節(jié)微控 制器。 II. 系統(tǒng)總體設(shè)計(jì) 該系統(tǒng)硬件包括微控制器,溫度檢測電路,鍵盤控制電路,時鐘電路,顯示,報警,驅(qū)動電路和外部 RAM。溫度可設(shè)定在一定范圍內(nèi)動任意。如果溫度超過 任意設(shè)置的 上限和下限 值 ,系統(tǒng)將報警并 可以和自動控制的實(shí)現(xiàn),從而達(dá)到溫度監(jiān)測智能一定范圍內(nèi)。譯文基本能夠表達(dá)原文意思,但不是很順暢。隨著生活質(zhì)量的提高,我們可以發(fā)現(xiàn)在酒店,工廠和家庭,以及比賽設(shè)備。這也是通用的,因此它可以方便地?cái)U(kuò)大使用該系統(tǒng)。使用鍵盤接口芯片 HD7279在設(shè)定溫度值,使用微控制器保持一定的溫度,并使用液晶顯示的溫度控制設(shè)定值。它是一個靜態(tài) RAM 芯片,低功耗具有 8K 字節(jié)的內(nèi)存。首先是外部電源供給: DS18B20 的第一腳連接到地面,第二引腳用作信號線,三是連接到電源。 C. LCD 顯示 器電路 液晶顯示 12232F 使用,這可以用來顯示字符,溫度值和時間,并提供一個友好的顯示界面。 CS是用來使能控制,液晶顯示。 備用電源可以連接到 的可充電電池。 F. 報警電路 為了簡化電路,調(diào)試方便,是一個 5V 的蜂鳴器自動報警電路中的應(yīng)用 [8]。二:當(dāng)溫度在兩者之間的某處結(jié)束,等于設(shè)定值時,電機(jī)停止。但對溫度的檢測,可與 TIMER0計(jì)時 1秒,即出現(xiàn)溫度檢測達(dá)到每秒。例如,當(dāng)系統(tǒng)通電后, LCD 應(yīng)該被初始化,啟動顯示器應(yīng)該叫,溫度轉(zhuǎn)換命令時,必須先發(fā)出的時鐘芯片 DS1302也要被初始化。 DS18B20。 besides not equals the preset value. Two: when the temperature is at somewhere between the two ends and equals the preset value, the motor stops. These steps are used to achieve the temperature control. In addition, the motor speed can also be adjusted by relative buttons. As shown in Fig. 8, the code data is input through ports A11~A8 (be ~) of the AT89S51 and inverted output by the inverter 74LS04. Finally it is amplified by the power amplifier 2803A to power the motor. IV. SOFTWARE DESIGN According to the general design requirement and hardware circuit principle of the system, as well as the improvement of the program readability, transferability and the convenient debugging, the software design is modularized. The system flow mainly includes the following 8 steps: POST (Poweron selftest), system initiation, temperature detection, alarm handling, temperature control, clock chip DS1302 operation, LCD and keyboard operation. The main program flow is shown in Fig. 9. Give a little analysis to the above 8 tasks, it is easy to find out that the last five tasks require the real time operation. But to the temperature detection it can be achieved with timer0 timing 1 second, that is to say temperature detection occurs per second. The system initiation includes global variable definition, RAM initiation, special function register initiation and peripheral equipment initiation. Global variable definition mainly finishes the interface definition of external interface chip connected to the AT89S51, and special definition of some memory units. RAM initiation mainly refers to RAM processing. For example when the system is electrified the time code will be stored in the internal unit address or the scintillation flag will be cleared. The special function register initiation includes loading the initial value of timer and o