# Research on Automatic Irrigation Algorithm of Strawberry Greenhouse Based on PLC

Wang Jianlun, Wang Shuting, Chen Jianshu, Liu Hao, Xu Dongbo

► To cite this version:

Wang Jianlun, Wang Shuting, Chen Jianshu, Liu Hao, Xu Dongbo. Research on Automatic Irrigation Algorithm of Strawberry Greenhouse Based on PLC. 7th International Conference on Computer and Computing Technologies in Agriculture (CCTA), Sep 2013, Beijing, China. pp.41-51, 10.1007/978-3-642-54344-9_6. hal-01220669

HAL Id: hal-01220669

https://inria.hal.science/hal-01220669

Submitted on 26 Oct 2015

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
Research on Automatic Irrigation Algorithm of
Strawberry Greenhouse based on PLC

Wang Jianlun<fnref n="1" />,<fnref n="2" />*, Wang Shuting<fnref n="1" />*, Chen Jianshu<fnref n="1" />, Liu Hao<fnref n="1" />, Xu Dongbo<fnref n="1" />

¹College of Information and Electrical Engineering, China Agricultural University, Beijing

100083, P. R. China

wangjianlun@cau.edu.cn

**Abstract.** In order to realize efficient water-saving irrigation of strawberry greenhouse in precision agriculture, the paper proposed an automatic irrigation algorithm based on fuzzy comprehensive evaluation irrigation based on PLC and the configuration software, and build a remote control system. By measuring the greenhouse soil parameters and strawberry soil moisture data to determine the upper and lower limits of irrigation and set buried position of moisture sensors. Use fuzzy comprehensive evaluation method to handle multi-sensor data, and develop an automatic irrigation control algorithm that depends on the strawberry irrigation system. Set up a C / S mode of automatic irrigation control system through the 3G network and the remote computer. The experimental results show that the algorithm is reasonable and reliable, and can be well adapted to the strawberry greenhouse. The automatic irrigations meet the steady demands for real-time performance and high scalability. The irrigation automation of strawberry greenhouse provides a theoretical and practical basis for intelligent irrigation of strawberry greenhouse.

**Keywords:** Strawberry greenhouse, Irrigation Control, Fuzzy Comprehensive Evaluation, Programmable Logic Controller

<footnote n="1">¹* Wang Jianlun, the first author</footnote>

<footnote n="2">² Corresponding author, Email: wangjianlun@cau.edu.cn</footnote>
# 1 Introduction

Strawberry is a nutritious and high economic value crop, adaptability, with advantages of strong adaptability, precocity fruiting, short-term growth cycle, and considerable benefits. Since 1980s, the strawberry industry has expanded rapidly in China, and its cultivated area and output also expanded to a great extent, as the diversification of its cultivated form. Although the strawberry production in China ranks first in the world, the production management level is still very limited, especially the fertilization irrigation management, which restricts the economic value of the strawberry severely in its growing process. There is no doubt that it's effective to improve facility agriculture of strawberry greenhouse to promote strawberry water-saving irrigation.

Wang Jian[1] and others propose that the implementation of strawberries facilities development of drip fertilization can significantly increase the production of strawberries; Wang Lingxiang [2] hold the point that strawberry fertilizer management is effective and feasible under clay planting conditions by using drip irrigation and semi-matrix irrigation manner. As for the automated management of irrigation, Kuang Qiuming[3] and others design a set of water-saving irrigation automatic control system, which includes moisture content of the plant irrigation threshold to realize the automatic irrigation system. According to low levels of irrigation management in the present development of strawberry production, a suitable organic strawberry greenhouse irrigation algorithm is proposed based on the strawberry irrigation threshold, and it can be achieved by using Wi-Fi technology, 3G network and remote server. The automatic control system can monitor the real-time situation remotely, collect sensor data and even send irrigation demands, which provide theoretical and practical experience for the sustainable development of the organic strawberry greenhouse production.

# 2 Strawberry greenhouse environment

## 2.1 Greenhouse environment

The experiment is conducted in organic strawberry greenhouse on Shangzhuang Town, Haidian District, Beijing, which located in north latitude 40 °08 ', east
longitude 116 °22', and belongs to the temperate humid monsoon climate zone, with climates of cold and dry in winter, Spring and Autumn-arid, much rain in summer while the prevalence of the northwesterly wind is blowing. The strawberry variety in this study is called HongYan, with high yield and big fruits.

Drip irrigation is applied in strawberry greenhouse, and the cultured soil mainly consists of peat soil, vermiculite and clay. This kind of soil includes favorable permeability, water retention and rich multi-nutrient content, even the soil temperature change is slow. The culture ridge shape is trapezoidal, and its width are 30 and 50cm respectively, with ridge height 30cm. Irrigation in plastic film greenhouses is seldom affected. The length of strawberry greenhouse is 80m, and height 7m. Strawberry can be planted once every year in this greenhouse. The ridge distance in planting specifications is 80cm, spacing is 20cm, and the dripper spacing is 20 cm. Each ridge arranged a drip tape, with emitter flow rate at 1.1 L/h.

Use the cutting ring method to test the soil bulk density and field capacity, calculation formula as follows:

$$r = \frac{W}{V} \qquad (1)$$

In the formula r —soil bulk density (g/cm³);

W —the soil quality in circular knife after drying (g);

V —circular knife volume (cm³).

Formula for calculating the field capacity as follows:

$$l = \frac{M_2 - M_1}{M_1} \times 100 \qquad (2)$$

In the formula l —Soil field capacity (%);

M₁ —mass of dry soil in circular knife (g);

M₂ —mass of moist soil in circular knife (g).

Repeat the test at least three times and take an average of value as the final result. Because of the soil that consists of peat soil, vermiculite and clay is uniformly mixed before planting, the soil bulk density and field capacity are basically the same, with average value of 1.03 g/cm³ and 50.72% respectively.
## 2.2 The irrigation upper and lower limits

### A. The soil profile and humidity data

The distribution of greenhouse strawberry roots is mainly in 0~25cm in the test, so this range of soil moisture can be used as control measures. Taking delay of the penetration of moisture into account, the mean value of parameters measured at different developmental stages before irrigation is needed to make the upper and lower control limits. According to the statistical data in the test, irrigation limit is developed depends on the mean of the whole soil profile from the experimental data.

<table><caption>**Table 1.** Statistics pre-irrigation soil moisture data / (m³ / m³)</caption><thead><tr><th>depth</th><th>1</th><th>2</th><th>3</th><th>4</th><th>5</th><th>6</th><th>7</th><th>8</th><th>9</th><th>10</th><th>Mean Value</th></tr></thead><tbody><tr><td>15cm</td><td>0.235</td><td>0.217</td><td>0.206</td><td>0.204</td><td>0.212</td><td>0.245</td><td>0.255</td><td>0.249</td><td>0.255</td><td>0.238</td><td>0.235</td></tr><tr><td>25cm</td><td>0.261</td><td>0.246</td><td>0.235</td><td>0.241</td><td>0.264</td><td>0.275</td><td>0.241</td><td>0.237</td><td>0.263</td><td>0.254</td><td>0.250</td></tr></tbody></table>

Average field capacity of the soil in the greenhouse is 50.72%, the soil moisture capacity is strong and uneasy to evaporate due to the covered film. In order to ensure the fruits growth rise superior to the plant growth, the humidity in the greenhouse must be reasonable. According to the results in Table 2-6, set the mean lower irrigation as 0.235m³/m³ and 0.250m³/m³ in the irrigation algorithm. The upper limit is 1 in theory, but during the actual irrigation process, the maximum is 80% field capacity at most, and it seldom happens, so set the upper limit as 0.330m³/m³, which takes 65% of the field capacity.

### B. Sensors buried position

Since the cultivation formulation soil in greenhouse is mixed with different ingredients, organic matter mix uneven may occur in an individual case. So the test needs to collect much data of several irrigation processes and the saturated soil layers profile data. Calculate the mean of each layer and its overall mean for comparison, reflecting the mean value of about 15cm is typical of the mean of the entire range of the closest. Though this position can reflect the overall soil moisture, it's treated as the best laying position for sensor. In addition, because of the greenhouse cultivation soil at about 25cm deep is the border of the formulation soil and clay; it is used to bury another humidity sensor. The two positions can determine irrigated conditions.
accurately.

# 3 Automatic irrigation fuzzy control algorithm

Because of major factors such as the temperature and humidity can't be defined entirely by mathematical model, the fuzzy control algorithm that combined qualitative analysis and quantitative analysis is proposed in this article to make the automatic irrigation control algorithm. Fuzzy comprehensive evaluation results are used as humidity sensor output, and ultimately decision making depends on membership results.

## 3.1 Fuzzy Comprehensive Evaluation

The fuzzy comprehensive evaluation is based on fuzzy mathematics, which provides integrated solutions to specific practical problems. Fuzzy comprehensive evaluation is based on fuzzy math actually, and according to fuzzy relation principles of synthesis of the corresponding, situations of the boundary is not clear and is not easy to quantitative determinants can be evaluated. Evaluation objects can be evaluated from several factors by using comprehensive evaluation. Comprehensive evaluation can get non-negative real numbers on each object according to the given conditions, judging indexes can also be sorted merit.

<figure><img src="image_2.png" /><figcaption>Fig 3-1. Fuzzy comprehensive evaluation steps</figcaption></figure>
In greenhouse irrigation control process, the need for irrigation is mainly decided by factors such as in-situ soil moisture and temperature in strawberry greenhouse. Temperature indoor is used to as precondition of whether it's suitable to start irrigation, but specifically when to start irrigation is required from analysis of soil moisture sensor data. For data fusion of multiple sensors, this paper used fuzzy comprehensive evaluation method for analysis.

<figure><img src="image_3.png" /><figcaption>Fig 3-2. Schematic basic model of fuzzy comprehensive evaluation</figcaption></figure>

Fuzzy relation matrix element is set as a fuzzy converter, and each set of input and output weight vector correspond its evaluation results. The basic model is shown in Fig 3-2.

## 3.2 The fuzzy comprehensive evaluation calculation

First, establish evaluation factors. This evaluation factors set all of the humidity values, and distributed at different distances at different depths. Eight sensor value integrated decision-making has a very good representation. Factor set matrix as follows

$$U = \begin{bmatrix} u_{11} & u_{12} & u_{13} & u_{14} \\ u_{21} & u_{22} & u_{23} & u_{24} \end{bmatrix} \qquad (3)$$

From $u_{11}$ to $u_{24}$ correspond to the sensors 1 to 8, represents respectively four sensors at 15cm and four sensors at 25cm.

Secondly, establish fuzzy relationship matrix of 8 humidity sensors, the matrix as follows

$$R = \begin{bmatrix} r_{11} & r_{12} & r_{13} & r_{14} \\ r_{21} & r_{22} & r_{23} & r_{24} \end{bmatrix} \qquad (4)$$

Where $r_{11}$ to $r_{24}$ respectively correspond to the ratio of the measured values and the threshold value. Based on analysis of the humidity data, set irrigation lower limit at 15cm, 25cm irrigation limit as $l_{10}$ and $l_{20}$, the measured values are 0.235 m³/m³ and
0.250 m³/m³, then

$$r_{1i} = \frac{\text{sensor values}}{\text{lower irrigation limit at 15cm}} \qquad (5)$$

$$r_{2i} = \frac{\text{sensor values}}{\text{lower irrigation limit at 25cm}} \qquad (6)$$

Next, establish the weight set. A reasonable weight value for the fuzzy comprehensive evaluation result has great influence on the finally results. In the evaluation system, because of functions of severity of different factors on the ultimate goals is different, the weight becomes the important information in evaluation process. It's necessary to consider its importance and identify its scale factor. Commonly there are many methods used to determine the weight, for example, the Delphi method with qualitative nature, principal component analysis with quantitative analysis method, and qualitative and quantitative analysis method. Based on practical irrigation experience, weight of the humidity sensor data is determined subjectively.

In actual greenhouse soil environment, the sensors at different depth locate in vertical position. Since the lower sensor is inserted in the junction of formulation soil and clay, and the humidity changes slowly under normal circumstances. According to the professional experience of planters and the actual measured data, weights of the upper and lower sensors are respectively 0.7 and 0.3. Expressed as

$$A = [a_{11} \ a_{12}] = [0.7 \ 0.3] \qquad (7)$$

Finally, execute fuzzy comprehensive evaluation. Factor set to review set fuzzy transformation is realized by the fuzzy relation matrix, evaluation results can be get by the corresponding weight vector of input factor. The fuzzy operator used in this paper contains the most information, as follows

$$B = AR = [a_{11} \ a_{12}] \begin{bmatrix} r_{11} & r_{12} & r_{13} & r_{14} \\ r_{21} & r_{22} & r_{23} & r_{24} \end{bmatrix} \qquad (8) \\ = [b_{11} \ b_{12} \ b_{13} \ b_{14}]$$

Select the maximum membership degree method to determine the evaluation results.

Accordingly, the lower limit is used to decide whether to begin irrigation.

Compare $max(b_{1j})$ with 1.
If $\max(b_{1j}) > 1$, there is no need to irrigate;

If $\max(b_{1j}) \le 1$, then need to begin irrigate immediately.

Similarly, based on the irrigation upper limit to decide whether to stop irrigation.

$$r_{1i} = \frac{\text{\textit{sensor values}}}{\text{\textit{upper irrigation limit}}} \qquad (9)$$

$$r_{2i} = \frac{\text{\textit{sensor values}}}{\text{\textit{upper irrigation limit}}} \qquad (10)$$

Compare $\max(b_{1j})$ with 1 to decide whether to stop irrigation.

If $\max(b_{1j}) > 1$, then stop irrigation;

If $\max(b_{1j}) \le 1$, then continue irrigation.

### 3.3 Automatic irrigation control algorithm

The entire basic idea of control algorithm is: PC machine collects humidity data for fuzzy comprehensive evaluation, and the output is sent to PLC; according to the irrigation experience, set a fixed irrigation cycle with PLC, which begin irrigation cycle after planting. Air temperature of the greenhouse is taken as the premise of irrigation. Only air temperature is within the allowable range, can irrigation operations can be executed. In the fixed irrigation period, execute irrigation operations regularly; outside the irrigation cycle, irrigation decision about whether to stop irrigation and irrigation mainly depends on the sensor data. Set the maximum irrigation time as 3h, which is prior to the humidity data to stop irrigation.
<figure><img src="image_4.png" /><figcaption>Fig 3. Automatic irrigation algorithm flowchart</figcaption></figure>

## 4 Realize automatic irrigation control algorithm

Based on study of greenhouse strawberry and soil profile data, this paper sums up an automatic irrigation algorithm that suits the greenhouse, which makes decisions by the feedback sensors data.

The algorithm is based on PLC and configuration software to implement. Field operations can be controlled by PLC program, and the remote control can rely on the configuration software. Computer sends instructions to operate the actuator, to adjust the soil moisture to keep it suitable for strawberry growth.

### 4.1 Fuzzy control algorithm based on PLC

PLC mainly is used in the scene control and get data from PC to make judgments based on automatic irrigation algorithm to decide whether begin or stop irrigation.

Input port of the control system include such as solenoid valve A switch button (X10), the solenoid valve B switch button (X11), the pump switch button (X12), the system manual/automatic button (X13/X15); output device of the control system include such as solenoid valve A(Y14), solenoid valve B (Y15), and the total pump (Y16), system alarm display (Y17).Beside, data includes humidity sensor and temperature sensor
data. PLC can also complete irrigation time setting. Fig.4 is the flow chart of a PLC-based automatic irrigation control algorithm.

<figure><img src="image_5.png" /><figcaption>Fig.4 Flow chart of automatic irrigation control algorithm based on PLC</figcaption></figure>

## 4.2 Automatic irrigation Control System Structure

The system configuration in control process is shown in Fig.5. System is composed with the central monitoring computer, a programmable logic controller, soil moisture sensors and solenoid valves.

<figure><img src="image_6.png" /><figcaption>Fig.5 Structure diagram of control system
In irrigation control system(Fig.5), the sensor uses Decagon ECH2O upgrade 5TE soil</figcaption></figure>
moisture sensor is used to measure soil moisture, three points need to be controlled, coupled with the temperature and humidity control, so the PLC selects Delta DVP series PLC, the experimental for other experiments vacated control communication channel and subsequent functional expansion choose to use DVP60ES200R Model. The whole solenoid valve actuator control circuit, optional 24 V AC drive form, to 2 W. PC as the control system of the host computer using the configuration software to communicate between the PLC to complete the exchange of data, that is controlled via a PC input parameters, data uploaded regularly monitored by the PLC and stored in the PC, provide data for later analysis and processing.

## 4.3 System control working principle

The hardware part of the irrigation system PLC control solenoid valve start, enter start and stop switch for irrigation, output via solid state relays, control solenoid valve opening and power to control the opening of the drip off. The greenhouse irrigation can also be based on changes in soil moisture dynamic feedback control.

Changes in soil moisture, temperature data collected in accordance with the soil moisture sensor to pass information to the PLC control program, and continue to query fuzzy control rule table to determine each irrigation solenoid valve is open or not, to maintain a constant soil moisture. According to the fuzzy control rules, when the real-time acquisition of soil moisture than the set humidity value, the solenoid valve without opening; collected in real time soil moisture than the set humidity value hours, the solenoid valve to open a certain period of time, the irrigation time; when measured value equal to the set value, according to the trend of the measured values to decide whether or irrigation, soil moisture until the real-time acquisition is equal to the set humidity value or within the permissible error range, the end of the first irrigation. The important prerequisite irrigation indoor temperature must reach the irrigation permissible range. Irrigation has been guided by the principle: soil moisture is maintained under suitable for the growth of strawberry constant soil moisture environment.

## 5 Conclusions

In this paper, the statistical analysis of data on strawberry growth and development of
irrigation, to determine the lower limit of the strawberry irrigation, developed a the
strawberries irrigation fuzzy control strategy, the fuzzy control and PLC control
system combined, while demonstrating the PLC reliable, flexible and adaptable strong
features, and can better adapt to the strawberry growth cycle of water, greatly
increased the level of intelligence of the irrigation and irrigation efficiency. Based on
PLC fuzzy control system is suitable for many occasions, the control program can be
easily modularity, standardization, also has some reference value of other crops,
irrigation control or control of industrial applications.

References

1. Wang Jian, Zhang Jianqing. Effect of strawberry in greenhouse fertigation research [J]. Chinese soil and fertilizer, 2008 (1): 78-79.

2. Wang Lingxiang. The problem of the development and production of strawberry and corresponding countermeasure [J]. JOURNAL OF ANHUI AGRICULTURAL SCIENCES, 2010, 38 (33): 18707-18708.

3. Kuang qiuming, hao Yandong, Bai Chenxiang. Automatic monitor and control system of water saving irrigation [J]. Transaction of the CSAE, 2007, 26(6):136-139(in Chinese with English abstract).

4. Qian xiaoqin. Effect of Irrigation Modes on Production,Quality and Water Metabolism of Strawberry[D]. Hefei: Anhui Agriculture University, 2009.

5. Susan A. O'Shaughnessy, Steven R. Evett, Paul D. Colaizzi, etc. Howell. A crop water stress index and time threshold for automatic irrigation scheduling of grain sorghum [J]. Agricultural Water Management, 2012(107):122-132.

6. L.L.Pfitscher,D.P.Bernardon,L.M.Kopp,etc.Automatic Control of Irrigation Systems Aiming at High Energy Efficiency in Rice Crops.8th International Caribbean Conference on Devices, Circuits and Systems,2012:1-4.

7. HE Wuquan, CAI Mingke, WANG Yubao,etc. Automatic Water Supply Control System of Graded Constant Pressure by Variable Frequency Speed and Its Application to Pipeline Irrigation .2010 Second WRI Global Congress on Intelligent Systems:385-388.

8. Yuan, B.Z., Sun, J., Nishiyama, S. Effect of irrigation on strawberry growth and yield inside a plastic greenhouse. Biosystems Engineering, 2004, 87 (2), 237-245.
9. Zhaoyu Zhang, Yanqiu Huang, Enting Gao. A Fuzzy and Comprehensive Evaluation Model for Developing Teaching Evaluation. 2nd International Conference on Consumer Electronics, Communications and Networks (CECNet), 2012: 774-777.

10. Dai Jianmin. Fuzzy Comprehensive Evaluation on Water Resources Bearing Capacity of Boertala River Basin. Desert and Oasis Meteorology, 2010, (4):35-39.

11. Ren Xiaoli, Wang Shuji, Hu Haoyun. Index weight of evaluation of water-saving irrigation project with the contrary problem of fuzzy comprehensive evaluation method [J]. China rural water and hydropower, 2005, 5:40-42.

12. Chen Dachun, Lei Xiaoyun, Cao Wei, etc. Research on Irrigation Decision Support System of Drip Irrigation Cotton. China rural water and hydropower, 2012, 11:72-75(in Chinese with English abstract).

13. He Hui, Zhao Heng, high strength, Han Shumin. Experimental study on drip irrigation index for Greenhouse Tomato [J].water saving irrigation, 2005, 4: 22-25.

14. Lv Yongbo, Hu Tianjun, Lei Li. Systems engineering [M]. Beijing, Northern Jiaotong University press, 2003.

15. Xie Shouyong, Li Xiwen, Yang Shuzi, He Binghui. Design and implementation of fuzzy control for irrigating system with PLC [J]. Transaction of the CSAE, 2007, 23 (6): 208-210.

16. Su Chen, Sun Yiyuan, Chen Yong. Study on Application of Newly Water-Saving Irrigation Control [J].ADVANCES IN WATER SCIENCE, 1994, (2): 142-148(in Chinese with English abstract).

17. Passino K M, Yu rkovich S. Fuzzy Control [M]. Beijing: Tsinghua University press, 2001

18. Sun Pingan, Li Duanming, Shi Xiangkun. Research on fuzzy control irrigation system based on PLC [J]. China rural water and hydropower, 2010, 12: 26-30.

19. Passino K M, Yu rkovich S. Fuzzy Control [M]. Beijing: Tsinghua University press, 2001

20. Solar Greenhouse Strawberry Cultivation Technology [M]. Beijing: Jindun publishing house, 2009.

21. Strawberry standardized production overall fine solution [M]. Beijing: China Agricultural Press, 2010.