大棚温度自动控制系统的设计 下载本文

摘 要

随着大棚技术的普及,温室大棚数量不断增多,对于蔬菜大棚来说,最重要的是一个管理因素是温湿度控制。温湿度太低,蔬菜就会被冻或者停止生长,所以要将温湿度始终控制在适合蔬菜生长的方位内。传统的温度控制是在温室大棚内部悬挂温度计,工人依据读取的温度值来调节大棚内的温度。如果仅人工控制既耗人力,有容易发生差错。现在,随着农业产生规模的提高,对于数量较多的大棚,传统的温度控制措施就显现出很大的局性。为此,在现代化的蔬菜大棚管理中通常有温湿度自动控制系统,以控制蔬菜大棚温度,适应生产需要。

本论文主要阐述了基于AT89C51单片机的温室大棚温湿度控制系统设计原理,主要电路设计及软件设计等。该系统采用AT89C51单片机作为控制器,SHT11作为温湿数据采集系统,可对执行机构发出指令实现大棚温湿度数据调节,根据实际需求设计了单片机硬件系统,该系统能够实现数据采集,数据处理,数值显示,键盘扫描等功能。同时介绍了温湿度传感器,单片机接口,记起应用软件的设计,该基于单片机和SHT11温湿度传感器的大棚温湿度控制系统,该系统性能可靠,结构简单,能够实现对温室内温湿度的自动调节。

关键词:AT89C51 湿度 控制系统 传感器 单片机

Abstract

With the popularization of trellis technology, greenhouse trellis an ever-growing number, for vegetable shed speaking, one of the most important management factor is the temperature and humidity control. Temperature is too low, the vegetables will freeze to death or stop growing, so will always control temperature and humidity in a suitable vegetable growth range. Traditional temperature control is in greenhouse trellis internal hanging a thermometer, workers according to regulate the temperature reading the temperature inside the shelter. If only by artificial control both consumption manpower , and easy to place regular orders. Now, with the improvement of agricultural industry scale, for larger quantity of trellis,tradition temperature control measures will show great bureau sex. Therefore, in modern vegetable shed management zhongtong often temperature and humidity automatic control system, in order to control the temperature the temperature, adapt to the trellis vegetable production needs.

This thesis mainly elaborated based on AT89C51 tomatoes canopy temperature and humidity control system design principle, main circuit design and software design, etc. This system USES AT89C51 single chip microcomputer as controller, SHT10 as controller, SHT10 as temperature and humidity data acquisition system, may to the actuator directives realize trellis temperature and humidity parameters adjustment, has the upper and lower level computer directly set temperature range ,temperature and humidity real-time display, and other functions. According to the actual demand design the microcontroller hardware system, this system can realize data acquisition, data processing, the numerical display, keyboard scan function. At the same time, temperature and humidity sensor is introduced, and its application software interface chip design, this based on SCM and SHT10 temperature and humidity sensor shelter, temperature and humidity control system reliable performance, the system structure is simple, can realize the automatic adjustment of the temperature is simple, can realize the automatic adjustment of the temperature and hum dimity in a greenhouse.

KEY WORD:AT89C51 Temperature Control System Single-chip microcomputer

目录

第一章 绪言 ......................................................................................................................... 1

第一节 系统设计背景 .................................................................................................. 1 第二节 系统功能、优势及特点 .................................................................................. 1 第二章 大棚温度自动控制系统的相理论及设计 ............................................................. 3

第一节 总体方案的设计 .............................................................................................. 3 第二节 系统主要电路设计 .......................................................................................... 4 第三章 硬件设计 ................................................................................................................. 9

第一节 温湿度测量电路 .............................................................................................. 9 第二节 LCD显示电路 ................................................................................................. 10 第三节 键盘扫描电路 ................................................................................................ 11 第四节 输出接口控制电路 ...................................................................................... 11 第五节 单片机与X25045接口电路 ........................................................................ 12 第四章 系统软件的设计 ................................................................................................... 13

第一节 系统主程序 .................................................................................................... 13 第二节 键盘扫描子程序,消抖程序流程图 .......................................................... 14 第三节 1602LCD液晶显示程序流程图 ..................................................................... 15 第四节 温湿度读取子程序 ........................................................................................ 15 第五节 键盘扫描源程序 ............................................................................................ 16 第六节 显示程序 ........................................................................................................ 19 第七节 温湿度采集程序 .......................................................................................... 26 结论 ..................................................................................................................................... 28 致谢 ..................................................................................................................................... 29 参考文献 ............................................................................................................................. 30