Anda di halaman 1dari 5

The Design of Control Node of Temperature in Greenhouse based on the Fuzzy Control Technology

GAO Liang1,LI Aifeng2 1 Office of Scientific and Technological Management, Agricultural University of Hebei, Baoding ,071001, P.R.China 2 Baoding Beiheng Jibao Technology Co., Ltd. , Baoding ,071051, P.R.China zyhbddy@126.com Abstract Temperature is an important environmental parameter in greenhouse, how to control the temperature accurately with a unified method is an important task in greenhouse automatic control system. This paper introduces the design of the fuzzy control node of temperature in greenhouse based on a MCS196 Micro-computer and the component of the greenhouse control system. The fuzzy control principle and method are presented. The hardware structure and the fuzzy control rules and output table are expatiated. The diagram of the node hardware function is also presented. By practical work in many greenhouses, the results present it runs well, the temperature control node has many advantages, such as convenient installation, easy debugging, and it has strong robustness. So, it has a better practicality and deserves to have more widespread application. Keywords greenhouses, fuzzy control, temperature, micro-computer Environmental control in modern greenhouses is of great significance to improving economic benefit of agricultural production. It can create proper growth condition for plants and make crops obtain high yield. Temperature is an important environmental parameter in greenhouse, how to control the temperature accurately with a unified method is an important task in greenhouse automatic control system, especially in the variant conditions of greenhouse structure and environment. There are two main factors affect greenhouse temperature : (1) the impact of greenhouse structure and regions, which includes greenhouses volume, wall thickness, transparent area, the heat capacity of heating, temperature and infiltration of outdoor environment, etc. (2) the effect of the adjustment of other environmental parameters on the temperature in greenhouse, these parameters include humidity, light illumination, CO2, etc. So, greenhouse environment system is a multivariable, large inertia, and nonlinear system, and also has the phenomenon of time delay. Accordingly, it is difficult to set up accurate and unified mathematical models to solve the problem of this kind of system, also traditional or modern control method is unable to realize the control. Whereas, fuzzy control needs not the precise mathematical model of the controlled object, the system has strong robustness, and it is suitable for nonlinear, time varying and hysteretic system control. Consequently, fuzzy control is the proper method to analyze the greenhouse environment system. This paper develops the fuzzy control node of parameters in greenhouse based on a MCS196 Microcomputer, and a more thorough research of the control rules, design and implementation of the hardware which are based on the Micro- computer fuzzy control system are made.

1 Fuzzy control algorithm


The node is a fuzzy control device of double-input and multi output. The input variables include the temperature deviation in the greenhouse and its change rate; the output variables include the temperature controlled variables and different combinations of air-venting, air-entraining and humidification. The core of the control is the fuzzy controller, after the fuzzy processing of the measured environment parameters and input variables, then is the processing of fuzzy inference and anti-fuzzy, the output of fuzzy control is obtained. The principle is shown in Fig. 1. 1.1 Fuzzification of temperature and temperature deviation Temperature deviation e is the difference between the measured temperature and its set value. The
421

node divides the temperature control region into two parts: fuzzy control region and confirmed control region. For the temperature control, temperature deviation of set value is within 4 is fuzzy control region, the others is confirmed control region. In fuzzy control region, the fuzzy control node regulates temperature automatically by the rules of fuzzy control; in confirmed control region, the node makes forced cooling or heating control, and emits alarm signal when the temperature exceeding standard. In fuzzy control region, to the convenience for the realization of single chip computer, select the domain of linguistic variable e and e x={-4,-3,-2,-1,0,1,2,3,4},here, e is the deviation between the measured temperature and its set value e is the change rate of e, it can be obtained by e=e(kT)-e[(k-1)T] to make the regulation more easy, quantization factor k and k are introduced, and e and e are made to be dots in the domain. In this domain, the language true value set of e and e is A and B separately, their domains are both {NB NS ZE PS PB},in other words, the temperature deviation, error rate of change and the output all can be divided into 5 fuzzy sub-status, separately is PB(positive big), PS (positive small),ZE (zero),NS (negative small),NB (negative big). The attribute function of e and e is shown in Fig. 2.


Fuzzy Fuzzy Controller

K1

K3

Object

1 NB NS ZE

PS
1 2

PB 3 4

Fuzzy

K2

-4 -3

-2 -1 0

Fig. 1 Diagram of fuzzy control system

Fig. 2 Attribute function of e and e

1.2 The rules and decisions of fuzzy control The principle of fuzzy control rules is to make the dynamic and static characteristics of output response to be the best. For example, when the temperature deviation e is much bigger,in order to eliminate the deviation as quickly as possible, the controlled variable should change rapidly, no matter how the temperature changes. If it is NB, in other words, the deviation of temperature in the greenhouse and the set value is negative biggest at the moment, the temperature decreases to the lowest, now in order to eliminate the deviation as quickly as possible, the controlled variable should increase faster, so the node of fuzzy control take the bigger controlled variable; if the temperature deviation e is NS or ZE, the main problem transforms to stability. In order to prevent overshoot, and to make the system stable as soon as possible, the change of the controlled variable is confirmed according to the concrete conditions of the changed temperature, and chooses the corresponding control rules. If e is positive,it indicates that the change of temperature has a decrease trend, so the fuzzy control system should take the smaller controlled variable in other cases, the fuzzy control rules under different situations of the change of temperature can be deduced by analogy. By the analysis of various possible cases and the corresponding control decision in the process of control, 25 control rules can be obtained as Table 1. The control rules can be described as the following condition sentence: IF e=Ai AND e=Bj THEN u=Cij ( i =1, 2, ,n; j=1,2,, n ) Here, Ai is the language variable value of e, Bj is the language variable value of e, Cij is the language variable value of controlled variable u which corresponds to Ai and Bj. That is A1=B1=NB,A2=B2=NS,A3=B3=ZE,A4=B4=PS,A5=B5=PB Cij can be found in Table 1, n is the number of language true value set A, B and C,here, n=5.According to the method of f fuzzy reasoning, the fuzzy condition sentence above can be described with a fuzzy relation matrix Rl Rl=AiBjCij (l=1,2,,t) Here, t=25 is the number of fuzzy condition sentences. The membership function of each element in Rl is:

422

e NB NS ZE PS PB

Table 1 Fuzzy control rulers e NB PB PB PB PB PB


Cij

NS PB PS PS ZE NS

ZE PB PS ZE NS NB

PS PS ZE NS NS NB

PB NB NB NB NB NB

R = A B
l i

The fuzzy relation matrix which corresponds to the master control rule is R. when e and e take fuzzy vector A and B separately, according to the combination rule of fuzzy reasoning, fuzzy subset of output controlled variable can be obtained: U=(AB)R The node adopts gravity method, and by means of anti- fuzzy to U, the exact output is obtained. According to the above analysis, the off-line calculation of the values of e and e are made. Then the output controlled variable u corresponding to different e and e are obtained, the collection of fuzzy control is shown in Table 2. Make this table fix in the program memory of 80C196, e and e are multiplied by k1 and k2 separately in every period, and rounding is made after getting the results, then the controller obtains the value of input domain, then the domain value of controlled variable is gained by lookup table, and then the actual controlled variable is obtained according to the present status of the greenhouse actuator, at last, the output controls the controlled object. As it has certain coupling between temperature control and humidity control, in practical control, temperature is the prime consideration target, because the fuzzy control has the advantage of insensitivity of the parameter perturbation and noise, actually, it implicates the thought of decoupling when the fuzzy rules is instituted, this weakens the influence of coupling to some extent.
e -4 -3 -2 -1 0 1 2 3 4 Table 2 Control results output e -4 4 3 3 3 2 2 2 0 0 -3 4 3 3 2 2 1 1 0 0 -2 3 3 2 2 1 1 0 0 0 -1 2 2 2 1 1 0 -1 -2 -3 0 2 2 1 1 0 -1 -1 -2 -2 1 3 2 1 0 -1 -1 -2 -2 -2 2 0 0 0 -1 -1 -2 -2 -3 -3 3 0 0 -1 -1 -2 -2 -3 -3 -3 4 0 0 -1 -2 -2 -3 -3 -3 -4

2 The hardware design of the node


The Diagram of the node hardware function is shown in Fig. 3. 80C196 micro-computer is the control center of the node. The micro-computer has many characteristics, such as reliable performance, high integrity, and its word-length, operation speed, instruction system and interruption function could satisfy the needs of fuzzy control. CPU peripheral chip adopts PSD311 programmable chip, it has 32kEPROM and programmable gate array inside the chip, and makes the whole system has the characteristics of compact structure and programming flexibility. 12 bit A/D converter with high precision and pre-multiplexer.

423

Monitoring machine

Interface circuit 80C196 Single chip mocro

Controlling machine Drive interface of optical-electrical isolation

PSD 311 Conditioning circuit

Temperature sensor

LED display in small keyboard

compu ter

A/D

Humidity sensor

Light intensity sensor

Fig. 3 Diagram of node

When the node works, the sensor converts the greenhouse environmental parameters to electrical signal, then sends to conditioning circuit, after the treatment of amplification and linearization, it is inputted into Micro-computer by A/D converter, compares the measured temperature with its set value, the deviation and change rate is figured out, then call the program of fuzzy control algorithm, the output of controlled variable is gained by fuzzy controller, after photoelectric isolation, the controlled variable drive the external equipment by driving circuit and regulates the temperature in greenhouse automatically. Meanwhile, for the micro-computer, the data of environmental parameters and the value of time provided by real-time clock is stored in NVRAM every 5min , and the capacity of NVRAM is 32 k bytes, it can store 72h` s history data; The characteristic of NVRAM is the data will not be lost when power off. So, at the inner of NVRAM, besides storing the history data, it stores the set value of all parameters to guarantee the system still running according to the original set value when power supply comes back. The keyboard and display constitute input and display board, and are used to realize the real-time display of environmental parameters and the input of parameter settings. The output circuit adopts the serial transmission mode, the line can be saved and it is convenient for isolation. By means of photoelectric isolation, it can eliminate interference from external circuit effectively. In order to improve the reliability, the circuit adopts optically coupled isolation, moreover, the controller takes some measures: (1) adopting software watchdog and hardware watchdog; (2) providing power supply for micro-computer with precision DC/DC converter; (3) adopting hybrid software digital filter to suppress periodic and pulsed interference. Humidity sensor, light intensity sensor and CO2 sensor are added in the node, and so the node of different parameters can be constituted. This is shown in the dashed-line frame in Fig. 3.

3 Composition of greenhouse control system


The structure of greenhouse control system which is composed of control nodes is shown in Fig. 4. PC computer, as the center of monitoring and control system, can realize the management of several greenhouse environmental parameters: sub-sectional setting and real time monitoring for the environmental parameters; storing, display, analyzing and printing the historical data; managing the equipment statue in greenhouse and providing it to the controller; the setting of the control parameter of control algorithms can be made. The connection between PC and the controller adopts RS-485 communication protocol, the range of RS-485 communication protocol is more than 1km,the number of
Monitoring center computer (PC) RS-485

Node 1

Node 2

Node n

Fig. 4 Diagram of control system

424

nodes can reach 256, so it can administer multiple greenhouse control nodes.

Conclusion

Because of the diversity of greenhouse structure and the complexity of its surrounding environment, it is difficult to set up accurate mathematical models, therefore, the precision control can not be realized with traditional or modern control method. According to the practical requirement, this paper develops the fuzzy controller based on micro-computer, the system needs not the precise mathematical model of the controlled object, and has strong robustness. Consequently, it is the proper method to control the temperature of the greenhouse environment. The temperature control node has many advantages, such as convenient installation, easy debugging, etc. By practical work in many greenhouses, the results present it runs well, so, it has a better practicality and deserves to have more widespread application.

Reference
[1] Zhang Zengke, Application of Fuzzy Mathematics to Automatic Technology[M], Beijing: Tsinghua University Press,1996 [2]Zhang Weiguo, Yang Xiangzhong, Theory and Application of Fuzzy Mathematics [M], XiAn:Northwestern Polytechnical University Press, 2004 [3]Ren Zhenhui, Zhang Shuguang, Xie Jingxin, Development of Intelligent Monitoring and Managing System of Environment Parameters for Solar Greenhouse [J]. Transactions of the Chinese Society of Agricultural Engineering, 2001, 17(2):101-104 [4] Xie Songhe, Gan Yong, Design and Application Examples of Fuzzy Controlling System on Single-chip Computer[M], Beijing: Publishing House of Electronics Industry,1999

425

Anda mungkin juga menyukai