**5. Experimental Results, Analysis and Discussion**

### *5.1. Experimental Set-Up and Sensors Calibration*

To measure the functionality and performance of the proposed LoRaWAN empowered IoT architecture and implementation for agriculture, a testbed has been setup. An indoor greenhouse is used for this purpose, as seen in Figure 5a.

The hardware used are the Dragino LG01-P LoRa Gateway, FRDM–K64F ARM mbed board, LoRa shield, light-intensity sensor, soil moisture sensor, temperature and humidity sensor. A strawberry plant in this greenhouse is used for the tests which could be assumed to be representative of a plot in the greenhouse.

Sensors are attached to FRDM–K64F ARM mbed board and Semtech SX1272MB2xAS LoRa shield as seen in Figure 5b. The temperature and humidity sensors are connected through the D6 digital input port of the LoRa shield, while the soil moisture sensors are attached by employing the A3 analog input port. Similarly, the light-intensity sensor is used through A1 analog input port of the LoRa shield.

(**a**) Overall view of strawberry greenhouse. (**b**) LoRa Node, sensors and strawberry plant.

**Figure 5.** Greenhouse and LoRa node monitoring strawberry-plant growth.

The Gateway is placed approximately 100 m away, due to the size of the greenhouse, from the above connected devices. The required Internet connection of Dragino LG01-P LoRa Gateway is established by deploying the WAN port of the device connected to an Ethernet admission. After that, the soil moisture sensor is placed inside the soil surrounding the strawberry plant, while the temperature, humidity and light-intensity sensors settle nearby, as seen in Figure 5b.

Data is flashed into the FRDM–K64F ARM mbed evaluation board's micro-controller through the Mbed online compiler. The IoT system runs as an autonomous time-triggered program based on set transmit interval. Once data is collected, it will be sent to the cloud server, i.e., "The Things Network" and consecutively to the client interface API, i.e., "All Things Talk API".

Before powering-up the whole IoT system, where compulsory, calibration tests have been conducted to measure the accuracy and stability of the sensor readings. For example, the temperature and humidity sensor is pre- calibrated with minimal sensitivity levels of humidity 1% RH and temperature 1 ◦C (see Table 1). On the other hand, for the soil moisture sensor, calibration has been conducted for three different levels of moisture; (A) sensor in dry soil, (B) sensor in humid soil and (C) sensor in water. Similarly, for the light-intensity sensor, calibration has been deployed for two different levels of light; (A) HIGH when sensor in daylight and (B) LOW when sensor in dark. The results for soil moisture and light-intensity sensors during calibration test are shown in Figure 6. Data gathered from temperature and humidity sensor is also being visualized for a more comprehensive review.

After the sensor calibration test, the real-environment test has been deployed. *Test 1 (Real-condition)* was set to transmit all sensor data at the interval of 300,000 milliseconds, which is 5 min.

**Figure 6.** Visualization of sensors calibration test data. x axis is time (Number of Measurements). y axis represents the sensor readings. (**a**) Temp unit is ◦C, (**b**) Hum unit is % RH, (**c**) LightInt unit is Volts and (**d**) SoilMoist unit is Volts. Soil moisture calibrated against three different levels; (A) sensor in dry soil, (B) sensor in humid soil and (C) sensor in water. For the light-intensity sensor, calibration has been deployed for two different levels of light; (A) HIGH when sensor in daylight and (B) LOW when sensor in dark.
