Internet of Things Approaches for Monitoring and Control of Smart Greenhouses in Industry 4.0

: In recent decades, climate change and a shortage of resources have brought about the need for technology in agriculture. Farmers have been forced to use information and innovation in communication in order to enhance production efﬁciency and crop resilience. Systems engineering and information infrastructure based on the Internet of Things (IoT) are the main novel approaches that have generated growing interest. In agriculture, IoT solutions according to the challenges for Industry 4.0 can be applied to greenhouses. Greenhouses are protected environments in which best plant growth can be achieved. IoT for smart greenhouses relates to sensors, devices, and information and communication infrastructure for real-time monitoring and data collection and processing, in order to efﬁciently control indoor parameters such as exposure to light, ventilation, humidity, temperature, and carbon dioxide level. This paper presents the current state of the art in the IoT-based applications to smart greenhouses, underlining beneﬁts and opportunities of this technology in the agriculture environment.


Industry 4.0 and System Engineering (SE) Applications for Precision Agriculture: An Introduction
Currently, we are living in the Fourth Industrial Revolution, known as "Industry 4.0", in which ICT-based production systems are requiring more and more integration and agility [1], resulting in digital matching or even in digital twins on the Internet. SE benefits from these new approaches in the design and analysis phases of the overall systems to tackle their complex structures.
The digital twins architecture supports the co-optimization of the production schedule, energy consumption, and cost, considering significant factors and including production deadlines, quality grading, heating, artificial lighting, energy prices (gas and electricity), and weather forecasts [2]. This work gives a new approach to vertical integration and optimization related to greenhouse production processes to improve energy efficiency, production throughput, and productivity, taking into account product quality or sustainability.
I4.0 was introduced at the Hannover Fair in 2011 in Germany, following discussions among representatives of industry, research, trade unions, and the state [3][4][5]. The main objective of this initiative was not to increase production automation, but to make production methods more intelligent through networking of machines and humans [6,7].
I4.0 is defined [8] as an industrial policy aiming to gain and maintain a global competitive advantage in manufacturing companies. Because of investments by companies in information technology, supply chain coordination, automation via cyber-physical systems, embedded systems, and robotics, I4.0 is regarded as a solution for the future [9,10]. Its objective is to respond to a change in consumers who request personalized products, forcing the industry to change its paradigms and practices and move toward personalized mass production [11,12]. I4.0 is mainly applied in the previous literature to collect, share, and This work presents a systematic literature review approach using three major databases, which are Google Scholar, IEEE Explore, and Scopus, for the period 2010-2021. The searching paper criteria is based on the TAK approach [55], according to the keywords "greenhouse", "IoT", and "Internet of things". Another set of papers was further considered by searching for the keywords "monitor" and "control". Within the results, in Google Scholar, 461 papers were found; in Scopus, 124 papers; and in IEEE Explore, 90 papers. The matching of the scientific articles was carried out according to the specific context of greenhouses, excluding papers related to general agriculture or to other applications not relevant for this review. Finally, 95 citations classified into the different categories, concentrated in the last 11 years, were selected. In this list, papers published between the 2020-2021 comprise 32%, while 53% papers are dated in the period 2015-2019.

IOT Architectures for Greenhouse Applications
IoT is a technological revolution in computing and communication that has mobilized the industry in recent years [56]. IoT is defined as a global network of interconnected services and intelligent objects of all kinds that are designed to support humans in daily life activities through sensing, computing, and communication capabilities [57,58].
The ability to observe the physical world and provide information for decision making will be a fundamental architectural part of the Internet of the future [59,60]. These objects must work in a system that is beyond enterprise boundaries, which is the digital world [61]. IoT includes a great variety of devices and integrates sensors and actuators. These sensors and actuators are the key elements of IoT [62]. They follow the state of their environment and obtain information on different physical variables, e.g., temperature, movement, position [63], and forming a complex network [64], and they are generally composed of a potentially large number of nodes [65].
Sensors collect information present in the environment to enrich the functionalities of devices [66]. They are becoming smaller and smaller and are therefore more easily integrated into objects [34]. Seventy-five billion IoT devices will be connected to the Internet by 2025 [27].
IoT relates to the network, data and new services [67] and relates to various technical solutions, RFID, TCP/IP, mobile technologies, etc. that identify objects and capture, store, process, and transfer data in physical environments and between physical contexts and virtual worlds [68,69].
IoT is composed of a heterogeneous set of networks that support the communication of these objects [70]. LPWA networks are emerging, with LoRa and SIGFOX in particular [71]. These are long-range, low-speed networks that are entirely dedicated to communications between objects. Other technologies are also used, such as Narrow Band or LTE-m [72]. Figure 1 shows an IoT architecture diagram for greenhouse applications in smart agriculture.
IoT has added value that lies in the new uses it will bring about [73]. In the industrial sector, for example, we can now monitor machines remotely, perform predictive maintenance on equipment, or improve product traceability [74], with specific applications in agriculture.
In agriculture, IoT solutions take the form of sensors connected to the Internet to collect environmental and mechanical measurements [75]. By using various smart farming tools, farmers have gained greater control over the process of raising and growing crops, making it more predictable and improving its efficiency [75].
Due to these new technologies, the farm manager can now remotely control his/her machines via a guidance system, thus rationalizing their use [76], and can monitor the machine fleet and detect the slightest anomaly [77]. The implementation of predictive maintenance also contributes to improving employee safety [78]. IoT in agriculture introduces many innovations that are constantly emerging. For example, drones can analyze crops and see where it would be best to intervene according to the data in terms of positions and qualities [79]. Thus, the farmer can distribute fertilizer or water where it is needed without Energies 2022, 15,3834 5 of 30 interrupting the portions that are doing well [80]. Of interest to the farmer is therefore that the distribution of fertilizer is conducted in a more efficient way [81]. This will also save costs in the sense that he/she will no longer have to place fertilizer on the entire field but only on specific parts [82]. These drones can also provide information on water requirements for crops [81]. IoT has added value that lies in the new uses it will bring about [73]. In the industrial sector, for example, we can now monitor machines remotely, perform predictive maintenance on equipment, or improve product traceability [74], with specific applications in agriculture.
In agriculture, IoT solutions take the form of sensors connected to the Internet to collect environmental and mechanical measurements [75]. By using various smart farming tools, farmers have gained greater control over the process of raising and growing crops, making it more predictable and improving its efficiency [75].
Due to these new technologies, the farm manager can now remotely control his/her machines via a guidance system, thus rationalizing their use [76], and can monitor the machine fleet and detect the slightest anomaly [77]. The implementation of predictive maintenance also contributes to improving employee safety [78]. IoT in agriculture introduces many innovations that are constantly emerging. For example, drones can analyze crops and see where it would be best to intervene according to the data in terms of positions and qualities [79]. Thus, the farmer can distribute fertilizer or water where it is needed without interrupting the portions that are doing well [80]. Of interest to the farmer is therefore that the distribution of fertilizer is conducted in a more efficient way [81]. This will also save costs in the sense that he/she will no longer have to place fertilizer on the entire field but only on specific parts [82]. These drones can also provide information on water requirements for crops [81].
Another example relates to small autonomous robots that can remove weeds [83]. Another example relates to small autonomous robots that can remove weeds [83]. Greenhouses will be able to take advantage of IoT, becoming a smart greenhouse [84], and thus adapting to evolutions in the environment by communication means and electronic processing interfaces [85]. Measurement and control systems of the greenhouse production environment are examples of IoT applications. Such systems can collect temperature, humidity and soil signals and use mobile wireless communication technology to achieve greenhouse monitoring [86].
The use of wireless communication is the most important and ideal tool to improve the comfort and security of goods and people, as well as of energy consumption reduction. Combining the advantages of emerging technologies such as IoT and Web Services can improve the measurement of the great amount of data in agriculture as well as manage energy usage [87].
A hierarchical wireless sensor network to monitor and control air humidity, temperature ground moisture and environment lightness has been proposed in a simulation environment [88]. The work shows some challenges and strong points in the Zigbee protocol used for the connection.
Therefore, tomorrow's agriculture will be automated, and agricultural production will be based on the concept of an intelligent agricultural greenhouse in order to manage processes with easy remote access and control [89]. IoT  agricultural greenhouse, providing a large number of high-quality crops with greater predictability [90]. Table 1 presents a comparison between the technologies used for connectivity in the agricultural system in terms of power consumption, frequency band, and transmission range.

Fuzzy Logic, ANN, MPC and PID
Several techniques can be used to optimize control and monitoring. In this first part, the main challenging methods are introduced: fuzzy logic, ANN, MPC, and PID. In the second part of this section, we briefly discuss other recent control and monitoring methods applied to smart greenhouses. The fuzzy control system is a mathematical system that analyzes analog input values in terms of logical variables. The FLC techniques usually decompose a complex system into several subsystems according to the human experts' knowledge about the system. Many processes controlled by human operators cannot be automated using conventional control techniques, because their performance is often lower than that of the operators. One reason for this is that linear controllers, which are commonly used in control systems, are not suitable for nonlinear plants. Fuzzy sets are used to define the meaning of qualitative values of the controller inputs, and fuzzy logic can capture the continuous nature of human decision processes and is therefore an improvement over methods based on binary logic. The mathematical approach related to this concept can be written as: The partitioning of the temperature domain into three fuzzy sets according to the previous formula is shown in Figure 2.
The fuzzy sets are determined based on deep human expertise and knowledge of the thermal behavior of the GHS as well as of the usual operating ranges of the GHS [91].
The ANNs consist of many simple processors linked by weighted connections that can acquire knowledge from the environment through a learning process and store the knowledge in its connections. The mathematical formulation of the ANN is outlined in Figure 3. The fuzzy sets are determined based on deep human expertise and knowledg thermal behavior of the GHS as well as of the usual operating ranges of the GHS The ANNs consist of many simple processors linked by weighted connectio can acquire knowledge from the environment through a learning process and s knowledge in its connections. The mathematical formulation of the ANN is out Figure 3.   The fuzzy sets are determined based on deep human expertise and kno thermal behavior of the GHS as well as of the usual operating ranges of the The ANNs consist of many simple processors linked by weighted con can acquire knowledge from the environment through a learning process knowledge in its connections. The mathematical formulation of the ANN Figure 3.
where b i is the bias, y k is the output, w ki is the weight between the neuron k of the previous layer and neuron i of the current layer and ϕ is the activation function, which is a differentiable and non-linear function. Strengths and weaknesses of NNs can be noted in different implementations in greenhouses, from microclimate forecast to energy consumption-specific tasks, including for example the control of CO 2 . Primary evidence as a guideline for designers of smart protected agriculture technology in the systems where 4.0 technologies are involved have been highlighted in [92].
Conversely, the MPC approach is outlined in Figure 4.
where is the bias, is the output, is the weight between the ne vious layer and neuron i of the current layer and is the activation fun differentiable and non-linear function. Strengths and weaknesses of NN different implementations in greenhouses, from microclimate forecas sumption-specific tasks, including for example the control of CO2. Prim guideline for designers of smart protected agriculture technology in th 4.0 technologies are involved have been highlighted in [92].
Conversely, the MPC approach is outlined in Figure 4. The plant represents the true system-in our case, the greenhouse model is usually a simplified model, generally linear, describing the dyn variables of the plant. Such a prediction model usually gives good perfor instances of simulation, while it becomes completely unreliable after a mizer is usually defined as a cost function to be minimized and is often straints. Mathematical programming, ANN, or other solving techniques However, the solution should be computed in a relatively fast time com tem dynamics, which are usually less than the duration of a sample tim discrete time systems. MPC implements a rolling horizon approach to co At each step, only the first value of the optimal control sequence is appli uously recomputed taking into account new measures of the output of following formula shows a typical mathematical formulation with qua constrained optimal control: is the prediction control variable; • Q is the semi-definite positive symmetric matrix, and R is the defin metric matrix. The plant represents the true system-in our case, the greenhouse. The prediction model is usually a simplified model, generally linear, describing the dynamics of the state variables of the plant. Such a prediction model usually gives good performance in the first instances of simulation, while it becomes completely unreliable after a while. The optimizer is usually defined as a cost function to be minimized and is often subjected to constraints. Mathematical programming, ANN, or other solving techniques can be used here. However, the solution should be computed in a relatively fast time compared to the system dynamics, which are usually less than the duration of a sample time, in the case of discrete time systems. MPC implements a rolling horizon approach to control the system. At each step, only the first value of the optimal control sequence is applied, as it is continuously recomputed taking into account new measures of the output of the system. The following formula shows a typical mathematical formulation with quadratic cost for a constrained optimal control: min x is the prediction state variable; • u is the prediction control variable; • Q is the semi-definite positive symmetric matrix, and R is the definite positive symmetric matrix.
According to the characteristics of the optimization problem and prediction model, different MPC approaches can be identified by specific attributes, such as non-linear MPC, constrained MPC, etc. In a few words, an MPC problem faces the problem of achieving a good tradeoff between the computational complexities to resolve the optimization problem and the capacity to define the dynamic characteristics of the system [93]. The last method that is introduced is the PID. It is a control loop feedback mechanism that is widely used in industrial automation and a variety of other applications for its simplicity and good performance. A PID controller applies a feedback correction that continuously calculates an error value as the difference between a reference value r(t) and the measured variable y(t). The control function in a continuous time system can be written as: where e(t) = y(t) − r(t), and K p , K i and K d are respectively the proportional, integrative, and derivative gains. The control parameters must be adjusted to improve system performance. Stability is a base requirement, but different values of the gains may lead to different settling times, overshooting, etc. For this reason, PID tuning can be a difficult process. An example of a PID controller is shown in Figure 5. The last method that is introduced is the PID. It is a control loop feedback mechanism that is widely used in industrial automation and a variety of other applications for its simplicity and good performance. A PID controller applies a feedback correction that continuously calculates an error value as the difference between a reference value r(t) and the measured variable y(t). The control function in a continuous time system can be written as: where ( ) = ( ) − ( ), and , and are respectively the proportional, integrative, and derivative gains. The control parameters must be adjusted to improve system performance. Stability is a base requirement, but different values of the gains may lead to different settling times, overshooting, etc. For this reason, PID tuning can be a difficult process. An example of a PID controller is shown in Figure 5.

Other Relevant Methodological and Technological Aspects
Other relevant methodological control techniques could be considered in the management of indoor parameters of smart greenhouses, specifically: robust control, distributed control, image analysis, Kalman filtering, and finite difference method.
Robust control is an approach to controller design related to uncertainty. The goal of robust methods is to carry out stability in the presence of limited modeling errors. In other words, the system is often optimized and controlled to minimize the maximum worst performance in order to guarantee a certain quality of service. Some real applications use this approach.
An H2 robust control method has been designed in [94]. The simulation proposed was based on a benchmark physical model in an experimentation greenhouse. Due to insufficient equipment power in the pilot greenhouse, there was a large bias in the target values. The result of the study showed good performance of the controller proposed. Another application related to the robust control based on feedback control architecture to study the energy-saving problem has also been proposed [95]. The study reports how the controller is insensitive to changes inside the greenhouse and how it can keep up the performance in instability conditions. With the goal to avoid waste energy, a fuzzy logic controller based on ventilation flow rate has been set up to achieve robust control [96].
Distributed control is an automatic control methodology where the controllers are in different systems and a central supervisory is not present. Due to the easy scaling architecture, it adds or removes subsystems and sensors [97]. The general drawback of these approaches is related to the time required to obtain an optimal control compromise among the different subsystems. This approach can be used for example among different

Other Relevant Methodological and Technological Aspects
Other relevant methodological control techniques could be considered in the management of indoor parameters of smart greenhouses, specifically: robust control, distributed control, image analysis, Kalman filtering, and finite difference method.
Robust control is an approach to controller design related to uncertainty. The goal of robust methods is to carry out stability in the presence of limited modeling errors. In other words, the system is often optimized and controlled to minimize the maximum worst performance in order to guarantee a certain quality of service. Some real applications use this approach.
An H 2 robust control method has been designed in [94]. The simulation proposed was based on a benchmark physical model in an experimentation greenhouse. Due to insufficient equipment power in the pilot greenhouse, there was a large bias in the target values. The result of the study showed good performance of the controller proposed. Another application related to the robust control based on feedback control architecture to study the energy-saving problem has also been proposed [95]. The study reports how the controller is insensitive to changes inside the greenhouse and how it can keep up the performance in instability conditions. With the goal to avoid waste energy, a fuzzy logic controller based on ventilation flow rate has been set up to achieve robust control [96].
Distributed control is an automatic control methodology where the controllers are in different systems and a central supervisory is not present. Due to the easy scaling architecture, it adds or removes subsystems and sensors [97]. The general drawback of these approaches is related to the time required to obtain an optimal control compromise among the different subsystems. This approach can be used for example among different neighboring greenhouses wishing to cooperate, sharing for example water and energy resources, or even at the level of a single greenhouse. For example, a recent work manages the indoor environment using automatic vehicles. An unnamed distributed control system related to the visual input of an aerial vehicle has been implemented to move autonomously inside an indoor environment [98]. Analogous studies based on visual acquisition data used image analysis to evaluate the growth of plants or flowers inside a greenhouse. Image analysis is commonly used to monitor crops in horticulture. Due to the difficulty in monitoring the growth of tomato cultivation in plant clusters, an automated clip-type IoT has been designed [99].
Sometimes, in a real context, the data from internal and external environmental sensors can be affected by noise. Filtering can be a classic way to cope with this problem, but currently, interesting new filtering techniques have been applied in this field. For example, a filtering model based on the ANN algorithm to update the error covariance in the Kalman filter has been proposed [100]. The experimental results prove that the proposed method improve the performance respect to traditional techniques.
In the field of modeling, the increasing speed of computation of traditional elaboration systems gives more and more details to the system specification. For example, the finite difference method for managing heat transfer of a wall in a solar greenhouse has been designed [101]. In the proposed work, the methods have been used to predict and evaluate the heat performance of the wall. This model was built to evaluate the periodic variation of environmental conditions, with a forward and backward approach to simulate the system efficiently.

IoT for Monitoring and Control of Temperature, Air Humidity, Light Intensity, Soil Features and Wind
Recently, the MPC application has taken great interest in the control of the climate of greenhouses that are provided with forefront IoT and ICT-based monitoring and control systems. Current control systems can be described as consisting of three major embedded subsystems: the monitoring sensor node network system, the communication network, and the control unit [93].
In this context, MPC has been applied to a smart greenhouse in order to control the indoor air temperature by determining the optimal control signals regarding the water mass movement produced by a heat pump [102]. The MPC has been developed as a multi-objective optimization model considering the active behavior of the greenhouse with regard to power and mass balances by an ICT-based monitoring and control system.
Similarly, control of the key indoor climate's parameters of the greenhouse system has been improved by an intelligent control system based on fuzzy logic [91], adopting a specific measurement of temperature and humidity. A fuzzy logic control technique has been used to cope with the non-linearity and complexity of the system. An intelligent automation system for wireless data monitoring allowing for remote access to the data has been applied. The results show the effectiveness of the intelligent automation system on the monitoring of the different set points of the parameters. The energy savings and water consumption could reach, respectively, 22% and 33%. The production costs could then be significantly reduced with respect to a study on the GHS.
Currently, many control methods, such as feedback control, adaptive control, and intelligent control, require an accurate model and IoT applications. In this context, several mathematical models including ML and dynamic models with an ANN method for predicting indoor air and roof temperature (Ta and Tri) as well as the energy loss in a semi-solar greenhouse have been compared [103]. Data samples related to environmental factors that influence Ta and Tri have been collected. These factors include indoor soil temperature, outdoor air temperature, solar radiation on the roof, wind speed, and indoor air humidity. The performance of the proposed model can solve the nonlinear relationship between the indoor environment variables and can estimate Ta and Tri with high accuracy.
Further works that have been carried out are described below. The key parameters considered are indoor temperature, air humidity (which is considered in most cases), light intensity (which is often taken into account), soil features (which are taken into account in some cases), and parameters such as internal or external wind speed and direction (which are considered in some cases).
A model based on a constrained discrete MPC strategy for indoor temperature of a greenhouse has been developed, whose goal is to select the best control on the basis of an optimization procedure under the constraints of the control concept [104]. This model has been solved using Simulink MATLAB and the Yalmip optimization toolbox for the implementation of the algorithm and blocks. Mathematical modeling using the subspace system identification algorithm, which forms a state space that fits correctly in the acquired data of the greenhouse temperature dynamics, has been carried out. The simulation results have confirmed the accuracy of this model for controlling and monitoring the reference indoor temperature.
A model based on a nonlinear MPC approach for greenhouse temperature control using natural ventilation has been implemented [105]. In distinct climatic areas, natural airing is used to regulate greenhouse temperature and humidity. The nonlinear MPC used is based on a second-order Volterra series model determined by the input/output greenhouse data gathered during the experiments.
Optimal placement of sensors in order to monitor and control the internal environment such as the air temperature has been considered [106]. Two methods have been proposed: the error-based sensor placement, which allows for the selection of sensor locations where the monitored data were close to the desired value, and the entropy-based sensor placement, which allows for the selection of sensor position according to the external weather conditions. The accuracy of the selected sensors has been evaluated by statistical analysis, and the proposed methods have been found to be able to determine the optimal sensor locations for the entire facility environment and detected areas with significant air temperature variations.
Further work has been carried out to improve agricultural production using innovative solutions and modern agricultural technologies based on IoT [107]. This work has set up an intelligent system to control and monitor the temperature of greenhouses. A Petri Net model has been used to monitor the greenhouse environment and to control the internal temperature. An energy-efficient scalable system has also been designed that uses a dynamic graph data model to process massive amounts of IoT big data captured from sensors. The system organizes various formats of unstructured collected raw data into a structured form in a unified and independent manner by model transformations and model-driven architectures. The results show that the proposed system can autonomously control and monitor the parameters of the outdoor temperature, the angles of the sun's rays, the energy consumption at peak hours, and generate the appropriate temperature. Environmental control systems for a greenhouse consist of special environmental and biological sensors along with other control and instrumentation devices that monitor all important environmental variables that affect crop growth [108,109].
An intelligent system to control frost through IoT and a weather station with an ANN has been developed [110] for an optimal prediction of the indoor temperature of greenhouses. A fuzzy expert system controls the activation of an IoT-based water pump system. The ANN involves input variables such as outdoor air temperature, indoor relative humidity, and solar radiation. The ANN models, through the coefficient of determination of the ANOVA method, are used to predict the internal temperature of the greenhouse and the temperature of the cultivated land, which are used to activate the anti-frost water distribution system. This work indicates a serial correlation with an approximate confidence level of 96%. Therefore, when the ANOVA model is adjusted, the ANN bias changes abruptly from its original value, and the R 2 value indicates that the adjusted model explains 95.8% of the annual internal temperature variability.
IoT technology has been used to monitor environmental data such as temperature [111]. An intelligent supervisory fuzzy controller has been proposed that can monitor and change the parameters remotely, preventing damage to the plants, and including an alarm system to notify of any event, such as fire. The results show that the model can control the greenhouse parameters, and the user can monitor and adjust the desired temperature and humidity.
Another IoT-based system has been developed to monitor and control environmental parameters such as temperature, soil moisture, humidity, light intensity, etc. [112]. These parameters are monitored by a DHT11 sensor, an LDR sensor, a soil moisture sensor and a flame sensor. The environmental data are sent to a module that is used for further working processes. The results show an effective control of the greenhouse environment, which includes temperature and humidity via portable devices such as mobile devices.
In the same context, for environment monitoring and control, a data encapsulation method has been presented in order to reach the adaptation of data communication between the gateway and the server in a greenhouse IoT system [113]. This method, based on XML, has been designed to allow for data interoperability in a distributed greenhouse IoT system. Multi-agent system behavior has been used to fuse heterogeneous information and the responses for data synchronization. For real-time and cumulative data synchronization between the gateway and the Java Agent Development JADE-based server, the data communication mechanism has been tested in a specific greenhouse. The results show that the system could be applicable to data communication. The data loss rate between the data acquisition unit and the gateway was 1.52%, and the data loss rate between the gateway and the server was 0.4%.
A system for monitoring environmental conditions in a greenhouse uses sensors to collect information on significant parameters (temperature, soil temperature, humidity, soil moisture, and light intensity) [114]. The sensor data received by the gateway, via an access point the greenhouse area is equipped with, are displayed in real time through a Node-RED dashboard installed on the gateway as a user interface to monitor the greenhouse conditions. The average percentage of the data that have been successfully stored is 99.76%, and the average percentage of loss or duplication of data is 0.24%. Therefore, the effectiveness of the system for monitoring and controlling environmental conditions has been found to be satisfactory.
An Arduino-based system has been set up to monitor and control environmental parameters such as temperature, water content, humidity, light intensity, and soil pH [115]. DHT11 sensors, LDR sensors, soil moisture sensors, and pH sensors have been used. The environmental data from the sensors have been sent to an Android cell phone both online and offline via short message service through a global system for mobile communication modem, which allows the user to control the parameters and actuators (exhaust fan, cooling fan, water pump, artificial light, and motor pump) from any location. These data are sent to the server via ethernet and are stored in a database. The sensors that have been used give exact values of the environmental parameters, reducing energy consumption, maintenance needs and complexity.
Currently, wireless communication technologies in the process of data transmission are being developed in the IoT world. Wi-Fi, Zigbee, Bluetooth, and LoRa have been used. A real-time IoT system to monitor the environmental data (temperature, humidity, light intensity, and soil moisture) of the greenhouse has been set up [116]. This system uses the LoRa communication protocol. The sensor data are sent to the LoRa gateway through a LoRa RFM95 and are saved as an IoT platform. The tests that have been carried out include the comparison between received signal strength indicator (RSSI), signal to noise ratio (SNR), and packet loss values. The results are presented in terms of packet loss, RSSI, and SNR performed under indoor and outdoor conditions, and they show that the system delivery performance in indoor conditions is improved.
An agricultural greenhouse environment monitoring system based on ZigBee technology has been developed [117]. This system, which uses a wireless sensor and CC2530F256 control nodes, consists of front-end data acquisition, as well as data processing, data transmission, and data reception. The data processed by the sensor are sent to the intermediate node via a wireless network. This node gathers all the data and sends them to the PC via a serial port, which allows the user to analyze and store the real-time data for the agricultural greenhouses. This system has been found to improve operational efficiency and application flexibility. The greenhouse environmental data can be reliably transferred, and the control instructions can be sent on time.
An intelligent greenhouse management system using sensor networks and web-based technologies has been set up [118], which consists of sensor networks based on Zigbee protocols and of a software control system that communicates with a middleware system via serial network interface converters. This web-based system provides users with an interface to view the status of agricultural greenhouses, to manage hardware installations, and to send commands to the actuators to remotely manage environmental parameters such as temperature, humidity, and irrigation. The results show that the control of the greenhouse environment can be achieved through a website to facilitate the remote operation management.
An Arduino Mega2560-based system has been developed for hydroponics in smart greenhouses [119]. The data of variables such as temperature and humidity are stored in a real-time database. An internet connection via the ESP-01 module for data communication between the Arduino Mega2560 and the firebase platform is used. The results show the proper functioning of the system, which can monitor and control the greenhouse parameters via an application on a smartphone.
An approach to monitor internal greenhouse parameters is described, in which ANNs technologies are used [120]. An IoT node acts as a smart gateway (GW), and WSN is installed to process sensor data by an ANN-based prediction model. The results show that this forecast algorithm can predict the air temperature using the index root mean square error of 1.50 • C, a mean absolute percentage error of 4.91%, and an R 2 score of 0.965.
An automated system has been set up that focuses on two factors that affect cultivation: weather conditions and plant diseases [121]. It monitors temperature and humidity and includes crop health inspection by image analysis. It is controlled by a Raspberry Pi microcontroller unit (MCU), an MSP432, a temperature sensor, a humidity sensor, and an OpenCV image inspection system. The yield of the product is enhanced through immediate control and monitoring without direct analysis by the farmers.
An IoT system has been set up to provide smart agricultural solutions to monitor and control the growth stages of tomatoes, monitoring temperature, humidity, and water supply. Disease monitoring and early detection are also provided [122]. The results show a weight accuracy of 91.5% for the visible wavelength in the support vector machine classification. An intelligent management system for agricultural greenhouses based on the NB-IoT (Narrow Band Internet of Things) network and smartphone has been set up [123]. It includes a sensor node, a cloud platform, and an Android application. Environmental data such as temperature, humidity, wind speed and direction, and light intensity are collected by the sensor node and are uploaded to the cloud platform in real time via the NB-IoT network. The management of node information, user management, real-time monitoring, and alarm logging and historical information query are implemented by the web application and Android app, respectively. The results show that the data transmission is stable with a high success rate that meets the real-time management requirements.

IoT for Indoor Parameters Monitoring and Control Focus on CO 2 Emissions
Several variables affect the growth and life of plants. Temperature (air and root zone temperature), light, relative humidity, and CO 2 are the key variables in a greenhouse environment [124]. Therefore, controlling and monitoring these important environmental parameters to achieve high performance at a low cost may be a challenge [125]. However, as a greenhouse is also a production system, CO 2 emissions are an important key performance indicator. In this respect, a comparison between three ML algorithms such as ANN, SVM, and DL for the forecasting of greenhouse gases emissions in Turkey has been made [126]. The electricity production data of the country between 1990 and 2014 was used to forecast gas emissions in the following years. Due to the high correlation between electricity production and greenhouse gases emission, the authors decided to use the historical data to forecast and try to reduce these emissions. These aspects are not the objectives of this paper. The goal is to monitor CO 2 concentration by IoT in connection to the quality of greenhouse production. CO 2 concentration is one of the important environmental elements for photosynthetic assimilation, and photosynthetic capacity and productivity are often limited by CO 2 concentration levels; therefore, CO 2 enrichment has been used to a great extent in various cultivation facilities [127]. For example, a method for automatically controlling the CO 2 concentration in a greenhouse that is dependent on ventilation to efficiently improve the productivity of strawberries under weather conditions in the northern part of Kyushu in Japan has been proposed [128].
In general, CO 2 control approaches in greenhouses consider the interactions with the other system state variables present. That is why the use of IoT becomes even more strategic due to the need for more sensors for different state variables that also produce precise monitoring in space and time at a reasonable price. Within this framework, a system to monitor and control parameters such as CO 2 level, humidity, light, etc., has been proposed [129]. This system collects these parameters and transfers them to a Raspberry pi, which acts as a real-time server based on the IoT. This system consists of sensor nodes that collect data and transfer them to the server via the ESP8266 Wi-Fi module. The stored data are compared with the appropriate parameters for crop growth, and the system provides users with a graph for the current values related to CO 2 using the Red-Node software. Finally, the actuation unit generates corrections to obtain optimal conditions. This distributed system enables a more accurate control of growing conditions, allowing data to be accessed over the Internet from anywhere, thus reducing human effort.
Similarly, an IoT approach for smart greenhouse management has been followed using Raspberry Pi, Sense HAT, and Arduino [130]. The sensors, such as the Adafruit CCS811 air quality sensor used to detect CO 2 level, detect the level of climate parameters and trigger the appropriate actuators automatically. These sensors also act as early warning systems that can mitigate unexpected events and return a total volatile organic compound, as well as an equivalent carbon dioxide reading.
A system to monitor and control parameters such as CO 2 level, humidity, light intensity, temperature, and soil moisture using Raspberry Pi and Arduino has been developed [131]. The data are collected in real time from the smart greenhouse and are visualized on the ThingSpeak platform. This automated greenhouse has excellent security and a monitoring provider that could become an advanced and diversified version of the current systems.
Another system aimed at modeling CO 2 flux from soil to the atmosphere in greenhouse conditions using MLR, ANN and deep learning neural networks (DLNN) has been developed [132]. This work compares the models to evaluate the prediction accuracy of the three predictive models via input parameters such as soil temperature and crop species. It has been concluded that the CO 2 flux from soil to the atmosphere can be modeled with an accuracy higher than 98% and that DLNN can achieve a higher efficiency in similar cases.
A big data analysis approach based on HDFS has been followed, using cloud services for data storage [133]. The environmental data have been collected from their own IoT architecture, which includes sensors to detect the concentration in different gases such as CO 2 , O 2 , O 3 , and NO 2 . These sensors transfer the data to the STM32-ARM processing chip, where the data are collected and sent to a MYSQL database through the Wi-Fi module, which uses the TCP socket protocol for transmission. The data have been periodically stored in the MySQL database and transferred to the cloud platform. A big data analysis, such as HDFS, has been carried out to analyze the details of the plant, providing the end-user with useful data through web and Android interfaces. The results show that the data generated by the system could help growers with regard to accuracy, memory consumption and time.
The performance of ZigBee communication technology in a greenhouse environment has been examined, using sensors equipped with a ZigBee (XBee PRO S2 ZigBee) module to determine various parameters, such as gas sensors, carbon dioxide (CO 2 ) sensor (TGS4161), SHT75 humidity sensors, MCP9700A temperature sensors, and PT-1000 soil temperature sensors [134]. These sensors measure environmental data and transmit it them to the PC via a router. The results show that in order to obtain better results, the sensor and the router must be placed at an appropriate distance and density.
In order to increase the yield and provide organic agriculture, a system for greenhouse agriculture control and remote sensing of agricultural parameters such as CO 2 control, soil moisture, temperature and light has been set up [85]. The monitoring action for the greenhouse windows/doors is performed according to the crops throughout the year. Comparative results show the effectiveness of the system. Moreover, the results for the environmental parameters of the greenhouse, such as CO 2 , are analyzed using a graphical representation based on practical values from the IoT kit.
A real-time CO 2 monitoring system has been set up, in which real-time data are stored in a ThingSpeak platform, and smartphone compatibility provides easy access [135]. The system uses an open-source ESP8266 for Wi-Fi 2.4 GHZ as a processing and communication unit and includes a CO 2 sensor as a detection unit. The results show great promise and represent a significant contribution to IoT-based CO 2 monitoring. This system has shown advantages both in installation and in configuration, because of the use of wireless technology for communications, and it has also been developed to be compatible with all devices.
A system for monitoring CO 2 and other significant parameters has been set up [136]. The data are sent from the transmitter node to the receiver, which monitors and records the data in an Excel sheet on a computer by a Graphical User Interface, realized in LabVIEW. The LabVIEW data are transferred to a smartphone through an Android application. The system has been implemented and successfully validated at various locations. The sensor node for environmental parameters (CO 2 , humidity, temperature) consumes less energy (4.99 mW), with system reliability at about 65% with a multi-hop mechanism.
A method to monitor the concentration of CO 2 in the greenhouse (applied to tomatoes) has been developed [137]. Two pieces of information have been chosen as the input parameters of the prediction model: the environmental parameters, which have been automatically collected by WSN, and the plant growth information, which has been manually obtained during the whole growth phase of the tomato. The results have shown the same trend as the theoretical analysis, and the model with a minimum of attributes has been found to have better predictive accuracy, proving that the system is useful for CO 2 concentration control.
A monitoring system based on various sensors highlights a new IoT-based solution [138]. This DSS acts as a central operating system that governs and coordinates all activities. It records the collected data, such as CO 2 level, UV light, pH and EC value, etc. Once the data are acquired, the data acquisition system sends it to the DSS, which analyzes this data and performs appropriate actions through an actuator management system. The system allows for increased productivity while reducing costs. Besides providing accurate information, the process also reduces the burden of manual work through automation.
An IoT platform applied to a greenhouse has been set up [139]. A fuzzy control method has been used for the controlling parameters (CO 2 , humidity, etc.), and the ZigBee protocol for wireless communications, using GPRS for remote control. A mobile communication network has been used by the master node to send the data from the perception layer to the application layer. The greenhouse environment data have been published on the web, and the corresponding authorized users can remotely check the associated information through a browser. The results show a stable performance of this monitoring system, with a simple structure and easy extensibility compared to traditional monitoring systems.
An intelligent system has been set up for real-time monitoring of environmental factors such as CO 2 concentration, air temperature and humidity, soil moisture, and light intensity [140]. It has been designed to adopt IoT technology and to use the JenNet protocol to establish a wireless network. The UPPAAL time automata modeling tool has been used to verify the correctness of the logic and execution time on an established formal model. The results show that the system runs stably with high acquisition accuracy and low energy consumption of the nodes, which satisfies the intelligent greenhouse data acquisition and control demand.
A prototype has been developed that allows for remote monitoring of the parameters inside the greenhouse, such as CO 2 concentration, light intensity, water irrigation, and ventilation [141]. The data are uploaded to a web page designed using a low-cost Wi-Fi module (NodeMCU V3) with appropriate sensors. An Android mobile application has been developed using a GSM A6 module to inform farmers about the status of the plants. In addition, it has been used to transmit the plant images through a web page to identify and classify diseases. A convolutional deep learning NN has been developed and implemented in a Raspberry Pi 4. The results show the ability of the system to identify the state of the plants and consequently to monitor and remotely control the greenhouse.

Monitoring and Control of Soil and Crop Quality by Water Supply and Energy Saving Approaches
Coupling IoT with a suitable control approach, such as MPC, enhances the optimization of the management of the overall systems, mainly in term of costs related to the consumption of resources. In this section, the energy-saving aspects related to the coupled use of smart controls and IoT are taken into account, while no consideration is given related to the energy consumption of IoT technology on its own.
One of the main advantages of introducing IoT technology is adopting smart controls to considerably reduce energy and water consumption, with the final goal of achieving an autonomous system with zero consumption of resources [142]. The performance of soilless crops depends on the accuracy of the collected data and on the efficiency of parameter measurement [143]. In this respect, the main factors that support the wide application of wireless sensor networks are the quality of the environmental control and energy and water consumption reduction. Several approaches have been adopted to monitor and control the quality of soils and crops to save water and energy.
In this context, a model of microclimatic parameters in two greenhouse crop production systems-the first, which is naturally ventilated, and the second by an evaporative cooling system-has been developed [144]. The model has flexible architecture and selfadaptive reference inputs, in order to function with various crops and cultural practices in which different growth stages can be modeled and analyzed. Two IoT connectivity boards are presented that use the ATmega328p microcontroller single-chip low power and low cost-ESP8266 serial module and integrated LoRa RFM95 module, providing a transceiver that makes network and point-to-point communication possible. The results demonstrate the successful adoption of simulation models fed by real-time IoT sensors and cloud-based data collection.
An MPC-based control model [102] provides approximately 30% electrical energy savings for a time horizon of 20 h in a smart greenhouse with sizes 15.3 and 9.9 m and an average height of 4.5 m, which compared to relay control, ensures a consistent temperature profile.
An intelligent system has been developed to collect and control information such as soil moisture data and soil temperature data [145]. It consists of a laptop, an Android terminal, a web terminal, an information perception module, an information processing and control module, a GPRS communication module and an LED display module. The GPRS module wirelessly transmits the collected data to realize real-time monitoring, data download, data display and data analysis. Once the data cross the limit, the intelligent alert system makes scientific decisions and remains available to users. Significant savings in terms of water are achieved by an automatic control of the irrigation system.
A system based on WSN has been set up [146]. This zoning irrigation system has been developed to optimize plant growth conditions and reduce water use and energy consumption. Environmental data of the plant, such as soil, humidity, and temperature, are transmitted by a server (Raspberry pi) based on RF communication. These data are processed by an FLC to control and monitor irrigation. This system uses an IoT-based human-machine interface (HMI) developed under IBM's Node-RED, which generates an improvement of 26.41% and 65.22% in terms of water and energy savings with respect to the traditional irrigation techniques.
FLC has also been used to control the greenhouse climate by several greenhouse parameters, such as soil data, temperature and humidity, in order to save energy and water resources. A smart monitoring and control system has been set up [147]. This system is based on WSAN, as well as on a fuzzy logic controller using python language and HMI. The results show the advantages of the system in terms of energy use and cost reduction.
A fuzzy logic controller has been developed in MATLAB, which was implemented around an Arduino microcontroller, as well as implemented to create a simple webserver to monitor the greenhouse parameters [148]. The system has been found to control the variables in a single action, achieving significant energy savings. Another fuzzy logic-based intelligent control system has been set up [103], in which the control has been enhanced by a wireless data monitoring platform for data routing and logging, which allows for real-time data access. It has been demonstrated that the energy and water consumption savings could reach 22% and 33%, respectively.
An FLC system uses smart controllers to measure sequential online plant temperature, and it is recursively updated based on the energy balance of an elementary volume of air in the greenhouse [149]. The results of the greenhouse dynamics simulation show the effectiveness of the system without an exact mathematical model of the plant.
The hybrid WSN is one of the promising applications of wireless sensor networking techniques. In this context, an architecture of a hybrid WSN system of wireless sensors has been developed [150]. This system uses sensors to collect soil information, including water content and temperature. In WSN, the module used is a CC2430 wireless transceiver module based on the ZigBee agreement. The nRF905 wireless chip uses WUSN for information collection and transmission. In addition, the wireless sensor node has been designed by a modular design method. Within each node, there is a sensor module, a processor module, a wireless communication module and an energy supply module. The system takes into account the electromagnetic wave transmission parameters and energy losses for different volumetric soil water contents and different compositions of sandy and clay soils.
A wireless monitoring and control system with low power consumption for smart greenhouses has been set up, which uses LPL technology to reduce energy consumption of the wireless nodes and which adopts the ACK mechanism to improve the quality of wireless communication, as well as the software watchdog to improve the anti-jamming capability of the nodes [151]. The base station receives the data of indoor and outdoor environmental factors acquired by the sensor nodes via the relay node and enters them through the RS-232 serial port into the industrial computer to process, store, display and download. According to the test results during the wireless transmission process, there is no loss of data packets. In addition, the current of the nodes using LPL technology is much lower than the current in the three operating states (transmit, receive, and idle). Therefore, this system can meet the actual requirements of the greenhouse microclimate.
A wireless sensor network system to recover, store and transmit data to monitoring soil water content has been set up [152]. The system is composed of ten sensor nodes, as well as a central node, in order to collect data from the sensor nodes and a base node connected to a PC that retrieves, stores and presents the data. TinyOS and ZigBee are used as the operating system and communication protocol, respectively. In addition, a solar-powered module is used to provide the energy needs of the sensors and of the central nodes. The results of the packet delivery rate experiment indicate that, overall, stable data transmission has been achieved.
Another project evaluated a predictive event-based control system for a greenhouse irrigation process [153]. This system controls and maintains the level of the desired substrate moisture, which keeps water consumption at the lowest possible level. The control system uses a microlysimeter to provide irrigation, drainage and crop water loss measurements. A family of 32 MISO ARMAX models represents the transpiration dynamics as a function of two inputs: solar irradiation (V GR ) and VVPD. It has been found that the use of a winter rye cover crop over the long term can improve the water dynamics of soil without sacrificing the growth of cash crops in the corn-soybean rotations. An automated irrigation system has been developed [154] to optimize water use for smart greenhouses. This system has a distributed wireless network of temperature and soil moisture sensors. The information from the sensors is processed by a gateway unit that triggers actuators and transmits the data to a web application. In order to monitor and control the amount of water, an algorithm has been developed with limit values for soil moisture and temperature, which were scheduled into a microcontroller port. In addition, the system is photovoltaically powered and has a duplex communication link based on a cellular-Internet interface that allows the data to be inspected and the irrigation to be scheduled via a web page. This system achieves water savings of up to 90% compared to traditional irrigation practices in the agricultural area. The system has the potential to be helpful in geographically isolated and water-limited areas, due to its energy self-sufficiency and low cost.
A novel control strategy for the optimal operation of a microgrid-powered greenhouse has been set up [155]. This strategy is formulated using MPC to optimally maintain the desired greenhouse microclimate while properly managing energy and water flow for irrigation. The MPC-based optimization aims to maximize the rate of crop photosynthesis while optimizing the use of available water and energy sources for a better quality of crops.
An approach for energy reduction in agricultural greenhouses has been adopted [156], which allows for the installation of sensors at several locations for better resolution of the monitored data gradient. In order to have good coverage, the LPWAN technology has been used with a LoRa network. The environmental data from the sensors are transmitted to the gateway and are collected for analysis. The challenges and limitations of IoT connectivity in greenhouses are identified, to enhance opportunities for energy savings and efficient wireless data communication.
A system for monitoring greenhouse environment parameters such as soil moisture and water control has been developed [157]. This system uses NodeMCU ESP8266 sensors and cloud computing. Three methods have been used, namely traditional management, soil moisture control by a timer, and soil moisture control by an automatic system. The results show that the system is efficient, with a 41.2% better growth rate, productivity (70%), and water savings (20.9%) compared with a traditional farm.
In order to overcome the problems of increasing time and energy consumption, an effective data collection system for critical events (CEs) in smart greenhouses has been developed [158]. The key feature data types (KFDTs) are obtained from the archival data set to keep the key information about CEs. Moreover, the sensing nodes are made to sense the event-related data considering the latency constraints of the SDWSN software servers. The results show that the system can reduce sensing time, communication time, number of required sensors and volume of collected data, while proving a low latency agricultural information collection system.

Challenges and Limits of IoT
The objective of this article is to provide a literature review on IoT applications in agriculture, and specifically in the smart greenhouse sector. The literature review highlights the main significant benefits and limitations provided by IoT applications.
This new technology allows for the measurement of a range of physical characteristics of the soil, air, and water to create optimal conditions for the growth of crops. In addition, the constant monitoring of the physical characteristics of the environment allows these parameters to be kept stable in order to optimize the growth of the crop and therefore the yield, and to significantly anticipate the harvest.
It has been found that the introduction of IoT has led to improvements in quality of products, reduced time, and lower production costs. Therefore, there are still missing experiences related to reliability in time, availability, and maintainability of IoT-based systems in greenhouses.
The increase in efficiency by intelligent devices can automate several processes throughout the production cycle by adopting an energy-and water-saving approach, also minimizing irrigation and fertilization requirements [159]. These important aspects, favored by IoT technologies, also relate to the improvement in product quality and volume [160], and to ensuring the health and wellbeing of the crops across their various cycles [161].
An overview of the major challenges facing IoT-enabled smart greenhouse farming, such as low cost and reliable solutions for the monitoring and growing of plants, unified data transmission protocol, and secure data transmission and collection, have been discussed [90]. It is believed that major efforts by the researcher must be focused in order to improve the crop yield at lower cost, particularly if it will consider future smart greenhouse farming.
The challenges and limitations of IoT connectivity in a greenhouse has been tested in a pilot study [156]. A possible research outlook to increase the opportunities in saving energy and efficient wireless data communication has been also proposed.
Due to the increasing number of IoT devices with a lot of consumption of energy, a green solution to charge these designs has been tested [162]. The article is a challenge in IoT architecture because it focuses on motivation for further research to realize green IoT. The same concepts have been proposed in [163]. In this case, the focus is on the important points of view of the farmers that are important aspects of green IoT technologies, such as energy saving, financial saving and management issue.
The processing of the physical world into a digital one inside the industry's context has made everything connected. Industrial IoT is one of the major goals not only in the manufacturing industries but also in different fields such as agriculture or medicine [164].
A combined approach between IoT and additive manufacturing to provide an escape from the limitations of mass production while obtaining economic and ecological savings has been performed [165]. The methods proposed to modify the production and supply paradigm reduces the ecological impact of industrial systems. This new approach could remodel the future of manufacturing.
The greenhouse industry due to its ability to produce fresh agricultural products with immense growth and production rates in recent years has been taken more into consideration in the agriculture community. A challenging issue in current greenhouse systems is related to the security and authenticity of agriculture data, particularly for yield monitoring and analysis. The parameters regarding a controlled environment must have optimal settings to produce increased food production [166].
A study regarding the forecasted economic benefits on the applications of IoT for an optimized greenhouse environment and resources management that are sustainable have been carried out [38]. The study affirms how any potential risks are incomparable to the long-term benefits in commercial agriculture.

Discussion and Research Directions
Despite that a greenhouse represents a quite ancient technological resource in the agricultural domain, new paradigms derived by Industry 4.0 have been recently added, and IoT may greatly support monitoring and control techniques as shown in the previous sections. Some aspects are however important to allow the reader to find its proper contribution and interest in the current state of the art. It is important to be reminded that IoT monitors a greenhouse with high detail in space and time at a reasonable cost. This fact defines more accurate models regarding the details of growing each single plant or flower and of the related physical variables affecting them. Such models can be coupled with MPC architectures for control schemes going beyond the traditional limitations given by nonlinear terms, constraints, and binary variables. Decisional problems in this domain are devoted to keep the greenhouse system autonomous, with zero energy and zero water needs. In our opinion, one promising field of research is the application of accurate monitoring and proper MPC to control crop production in extreme environments such as desert [167], underwater [168], or Mars missions [169]. Thus, in these cases, the objective becomes to keep the greenhouse system toward zero consumption in terms of water and energy, while forcing plant production to specific temperature, radiation and humidity trends related to a safer and more optimized production. In severe conditions, techniques related to robust control may also be more adequate to avoid critical system behaviors. Research in the MPC domain can also be coupled in this case with ML approaches, where an ANN can play the role of a predictive model. The trend toward autonomous greenhouse systems can be relaxed in certain conditions where several greenhouse systems, generally closer in space, can cooperate toward the same zero consumption objectives, but in this case as a system of systems. In this respect, important techniques that have interested researchers to investigate are related to distribution and cooperative control. However, despite the increasing number of applications present in the literature, few of them have been applied in a real context (see first row of Table 2). Table 2. Variables of the IoT-based agriculture monitoring and control system for the different references.
The first research trend is related to flexible control, as required by a greenhouse where the configuration of the crops varies in time. In this respect, MPC and ANN techniques are the most promising methodologies. Conversely, as reported in Table 3, few papers have been published on the application of these techniques in greenhouses. The second research trend is related to the need of designing and implementing virtual digital twins of greenhouses. A digital twin is an electronic corresponding to a real item representing its behavior and state in a virtual space. Using digital twins as a focus for greenhouse direction enables the splitting of the physical stream from its planning and control. Therefore, by using this technology, the farmers can remotely direct based on real-time digital information rather than by observation and tasks on-site. This approach grants them to work immediately in case of a (projected) deflection and to reproduce the effects of an action based on real data [171].
The results of a performance analysis between crop production in a real and simulated environment in different divisions have been compared. For the simulated greenhouse crop production, digital twin technology has been proposed [172]. By the availability of this digital twin of the real greenhouse, a detailed analysis can be performed to better understand the roles of different growth factors. For this reason, the digital twin may constitute a fundamental tool to reach the optimization of productivity, intended as the ratio between production and resource consumption [173]. These new methodologies in construction technology would bring the industry a step forward toward achieving the goal of Industry 5.0 [174].
A further required research activity is the one related to considering a greenhouse not as an isolated system but as a system interacting with other similar systems, i.e., with other greenhouses, or with other heterogeneous systems, i.e., a residential building, a swimming pool, a touristic location. In this respect, important interactions should be considered at the level of thermic and electrical energy consumption and production, and water consumption.
About 100 works are quoted where IoT plays a fundamental role in the monitoring and control of key variables of a greenhouse. IoT more and more represents the foundation of modern approaches to control key variables in greenhouses. For the sake of readability, Table 2 reports the variables that have been monitored by IoT for the different references.  Table 3 shows the techniques that have been used for management control or optimization in the greenhouse.

Conclusions
IoT is a technological revolution that has mobilized industry. It brings about new opportunities and challenges in several economic fields. IoT is an exciting technology that opens many possibilities for greenhouse cultivation. Moreover, it can be applied to various technical solutions that identify objects, as well as capturing, storing, processing, and transferring data in physical environments and in between physical and virtual worlds.
IoT supports the transition from the traditional greenhouse to smart solutions, which consists of an intelligent greenhouse equipped to track the indoor parameters and to communicate with the farmer who can make decisions automatically to preserve crops and improve production.
IoT for smart greenhouses includes a wide variety of devices integrated with sensors and actuators, which are connected to and interact with each other via the internet, trending toward a greater osmosis between the real world and digital world. Sensors and actuators, which are the key elements of the IoT, monitor the state of the system as well as the environmental parameters, obtaining information on temperature, humidity, CO 2 , water and energy consumption, movement, position, etc., and which manage the dynamics of the system.
Moreover, the possibility of controlling the above-mentioned indoor values within certain reference levels minimizes pesticide treatments for the prevention of the main diseases to which the crops are subjected. The possibility of monitoring and controlling the optimal conditions of crops in a protected environment minimizes the damage due to climate change or to any weather condition, as well as allows the farmer to intervene by irrigating, heating, and fertilizing only to the extent that is necessary to achieve the pre-established objectives, effectively avoiding waste and implementing water and energysaving approaches.
In conclusion, mainly for its characteristics of accurate measurements everywhere, anytime, and at a reasonable cost, it can be said that the introduction of IoT and related technologies in greenhouse systems may allow for the development of a new developing economy in agriculture, above all, in specific territories, such as the ones present in the western part of the Liguria region in Italy, which has been excellent for many years in flower production, but which has also been in a deep crisis for the last few years.
Institutional Review Board Statement: Not applicable.

Informed Consent Statement: Not applicable.
Data Availability Statement: Not applicable.

Conflicts of Interest:
The authors declare no conflict of interest.