摘 要
本设计是基于西门子可编程逻辑控制器S7-200的温室温度控制系统,它实现了对某兽医研究所多个温室的温度控制。具体方法是:可编程控制器通过每个温室中的温度变送器来采集温度,通过与实际要求的设定值作比较来控制每个温室中的加热器的运行状态。
本设计对象共分二个控制区,其中,二区和四区为控制1区,三区和冷库为控制2区。其中,控制的方式又分为手动控制和自动控制。并实现故障报警和温度设定值的独立设定。
在温室温度控制系统的硬件设计中,给出了主电路的设计方案和主电路的线路图,进行了控制1区和控制2区的选型计算,并且给出了控制回路的设计以及线路图。
在温室温度控制系统的软件设计中,上位机是基于组态软件MCGS来实现人机界面的设计,既直观又方便地实现了操作窗口的制作和变量的连接。下位机则通过程序设计实现了温度控制的自动控制功能。
本设计由于采用工控组态软件和可编程序控制器PLC作为控制核心,使温室控制系统具有界面友好、易于操作、运行可靠、便于更改、扩充、升级等优点。经现场测试证明性价比高、运行可靠,具有很强的应用性。
关键词:温室控制;组态软件;PLC控制
I
Abstract
This system is a greenhouse automatic control project controlled on the basis of SIEMENS S7-200 PLC. It realizes the temperature control for every greenhouse since having powerful function. Specific method is that: may programming controller changes through the temperature in every greenhouse send ware gathered temperature, by asking with reality set temperature make a comparison for every greenhouse in the operating condition of heater.
In which, the objects of design are two control areas.No.2 and No.4 are the first control area; No.3 and refrigeratory are the second control area. The control mode classified as the automatic control and control of by hand. And implement malfunction alarm and enactment of the TEMP SV alone.
In the design of hardware software of the regulation the greenhouse temperature,there are the design proposal and the circuit diagram of the main circuit. To calculate lectotype of the first control area and the second control area and provide the design proposal and main circuit of duct pilot.
In the design of hardware software of the regulation the greenhouse temperature, up position has adopted group form software MCGS to complete the design of man-machine interface,It is convenient and directviewing to make the Operation Windows and to attach the variable Machine-under through the design process to achieve a temperature-controlled automatic control functions.
As a result of industrial design of the configuration software and PLC control as the core of the PLC, the greenhouse control system has a user-friendly, easy to operate, reliable and easy to change, expand, upgrade, and other advantages. After field testing to prove cost-effective, reliable operation, has a strong application.
Keywords: Greenhouse automatic control , configuration software, PLC control
II
武汉理工大学工程硕士学位论文
目 录
第1章 绪 论 ........................................................................................ 1
1.1 课题来源及研究意义 ..................................................................................... 1 1.2 相关技术国内外研究现状 ............................................................................. 1 1.3 本文主要研究内容 ......................................................................................... 2
第2章 温室自动温度控制系统 ............................................................. 1
2.1 温室自动温度控制系统组成简介 ................................................................. 1
2.1.1 上位机监控系统 ................................................................................... 1 2.1.2 硬件控制线路的设计 ........................................................................... 4 2.1.3 下位机程序设计要求 ........................................................................... 6 2.2 温室自动温度控制系统控制要求 ................................................................. 6
2.2.1 工作方式的描述 ................................................................................... 6 2.2.2 温度控制的工艺描述 ........................................................................... 8 2.2.3 故障报警 ............................................................................................... 9 2.2.4 八个固定及活动冷库的温度检测,高温报警。 ............................... 9 2.2.5 设定值的独立设定 ............................................................................... 9
第3章 温室自动温度控制系统硬件系统设计 ................................... 11
3.1 主电路的设计 ............................................................................................... 11
3.1.1 主电路的设计方案 ............................................................................. 11 3.2 选型计算 ....................................................................................................... 11
3.2.1 控制1区的选型计算 ......................................................................... 11 3.2.2 控制区二的选型计算 ......................................................................... 13 3.3 控制回路设计 ............................................................................................... 15
3.3.1 控制回路的设计思想 ......................................................................... 15 3.3.2 控制回路的设计 ................................................................................. 19
第4章 温室自动温度控制系统软件系统设计 .................................. 23
4.1 上位软件的设计 ........................................................................................... 23
4.1.1上位机说明 .......................................................................................... 23
i
武汉理工大学工程硕士学位论文
4.1.2 窗口的实现 ......................................................................................... 23 4.1.3 报表和数据连接 ................................................................................. 43 4.2 下位机程序的设计 ....................................................................................... 45
4.2.1 下位机程序说明 ................................................................................. 45 4.2.2 上位机与下位机变量对应表 ............................................................. 46 4.2.3 变量设定 ............................................................................................. 51
第5章 总结与展望 ............................................. 错误!未定义书签。
参考文献 .................................................................................................. 52 致 谢 ..................................................................... 错误!未定义书签。
ii
第1章 绪 论
1.1 课题来源及研究意义
温室控制系统是一种以节约能源,提高产品质量为目的的高效工业发展技术。温室控制系统主要通过计算机控制和外部执行机构具体操作,创造与季节无关的适宜特殊工业产品的人为环境,实现产品的质量,降低能耗的大规模生产。目前温室生产现场使用的温室控制系统普遍为集中式控制,这种结构中的现场设施和通信接口距离较远,系统的可扩充性差,不能顺应温室大型化的发展趋势。本设计在消化吸收了国内外技术的基础上,采用PLC和组态软件设计了分布式温室控制系统。
本设计是基于西门子S7-200PLC的温室的温度控制。它具有强大的功能来实现对每个温室的温度控制。具体方法是:可编程控制器通过每个温室中的温度变送器来采集温度,通过与实际要求的设定值作比较来实现对每个温室中加热器的控制。
在设计中,上位采用了组态软件MCGS来完成人机界面的设计,既直观又方便地实现了上位的控制。整个设计中,主电路、控制回路、上位和下位的连接主要是通过各个环节的相关变量的连接来实现整个系统的正常运行。所以,其中的控制变量是整个系统设计的一条主线。
该系统由于采用工控组态软件和可编程序控制器PLC作为控制核心,使温室控制系统具有界面友好,易于操作,运行可靠,便于更改、扩充、升级等优点。经现场测试证明性价比高、运行可靠,具有很强的应用性。
1.2 相关技术国内外研究现状
国内外传统的温室小气候建模,多是基于传热学、传质学等物理学定律和蒸腾作用、呼吸作用等作物生理学原理进行机理分析,通过能量平衡和物质平衡建立温室小气候机理模型。机理模型未知参数多,测量这些参数需要昂贵的仪器,试验成本高;有些参数的测量费时费力,测量方法不易掌握;由于温室材料老化或损坏等原因,很多模型参数随时间变化,模型本身也是时变的。因
1