Scalable and Sustainable IoT System for Environmental Monitoring in Hydroponic Cultivation using LoRaWAN
This project consists of creating a technology-based solution using IoT (Internet of Things) to monitor key environmental variables in a hydroponic cultivation system. Through a wireless sensor network (LoRaWAN), data such as temperature, humidity, atmospheric pressure, and air quality are collected and transmitted.
The aim is to improve the performance and sustainability of the crop, reduce water and energy consumption, and allow for the progressive expansion of the system to other areas or cultivation modules without the need for large infrastructures.
The use of LoRaWAN enables long-range coverage, ideal for large-scale agricultural operations or greenhouses, with low energy consumption that makes it feasible to use solar power as the main energy source.
This system integrates fully with The Things Network (TTN), a public and free LoRaWAN network, which allows the system to scale without the need to pay for proprietary servers, while also complying with the principles of open access and technological sovereignty.
The RAK11300 is the core of the system. It is a programmable module that integrates:• RP2040 microcontroller (dual-core ARM Cortex-M0+ at 133 MHz).• LoRa SX1262 transceiver compatible with LoRaWAN 1.0.3.• Compatible with the WisBlock platform: modular and expandable format.
Technical advantages:• Low power consumption: ideal for solar-powered projects.• Native LoRaWAN capability for long-range networks (>10 km in open field).• Versatility: can be used with environmental sensors, soil moisture, light, EC, pH, etc.
Role in the project: This module acts as the brain of the sensor node, executing the code that collects environmental data and transmits it via LoRaWAN to the Gateway.
RAK19007-O – WisBlock Base BoardThe RAK19007-O is the base board that enables the interconnection of the RAK11300 module with other WisBlock peripheral modules.
Key functions:• Provides connection ports for I2C, UART, analog, and GPIO sensors.• Integrates a JST connector for solar panel and another for Li-Ion battery.• Includes a reset button and USB Type-C port for programming and debugging.
Role in the project: Serves as a structural and electrical connection base, making the assembly of the sensor node clean, modular, and robust—ideal for agricultural or laboratory environments.
Multifunctional digital environmental sensor manufactured by Bosch (model BME680), mounted by RAKWireless as RAK1906. It offers a combined reading of:• Temperature (±1 °C)• Relative humidity (±3%)• Barometric pressure (±1 hPa)• Air quality (IAQ) through gas resistance (detects VOCs)
Connection: via I2C bus (3.3 V and GND pin from the RAK5005-O).
Technical advantages:• Compact size.• High precision.• Very low consumption (ideal for intermittent operation every few minutes).
Role in the project: Allows monitoring of the environmental conditions where hydroponic crops are located, detecting unfavorable conditions that could affect growth or generate risks such as condensation or air deficiencies.
RAK Edge Gateway Lite 2Device that acts as a LoRaWAN Gateway, i.e., it receives the packets sent by LoRa nodes and forwards them to the cloud (in this case, to The Things Network).
Key technical characteristics:• Processor: Raspberry Pi Compute Module 4.• LoRa modem: Semtech SX1302 (8 simultaneous channels).• Connectivity: Ethernet and Wi-Fi.• External LoRa antenna and support for USB-C or PoE power supply.• Operating system based on OpenWRT.
Role in the project:• Functions as the central point of the network, receiving signals from nodes and keeping them connected to the TTN backend.• Capable of managing dozens of nodes simultaneously.• Can be located inside or outside the cultivation environment.
5 V / 3–5 W Solar Panel + 3.7 V Lithium BatteryAutonomous and sustainable power supply system.• Solar panel: converts solar energy into electricity, charging the battery through the RAK5005-O’s charge controller.• Li-Ion battery: stores energy and powers the system during the night or cloudy days.
Suggested specifications:• 5 V / 3–5 W panel, with standard JST connector.• 2000–3000 mAh battery, 3.7 V Li-Ion, with protection.
Role in the project:Ensures that the node can operate without the need for fixed electrical infrastructure, aligning with SDG 7 (Affordable and Clean Energy) and allowing these systems to be implemented in remote or agricultural locations.
Other Auxiliary Components• 868 MHz LoRa antenna: essential for transmitting and receiving LoRa data.• USB Type-C cables: necessary for programming and debugging.• Screws, IP65 or 3D-printed enclosure: physical protection of the node.• Multimeter or tester: to check panel and battery voltages.
3. Step-by-Step GuideStep 1: Physical Assembly of the WisBlock NodeThis step consists of correctly assembling the IoT node components so that it becomes physically operational and ready for programming.
Detailed instructions:- Mount the RAK11300 module on the RAK19007-O base board:
- Carefully insert the module into the 40-pin connector labeled “Core”.
- Make sure it is fully inserted and straight.
- Connect the RAK1906 sensor:
- This sensor is inserted into one of the ports labeled "IO" or "I2C" on the base board.
- It snaps into place in the corresponding slot. If there are securing screws, tighten them for greater stability.
- Connect the LoRa antenna:
- Screw the 868 MHz antenna to the RAK11300 connector.
- ⚠️ Important: never power on the node without the antenna connected.
- Connect the Li-Ion battery (3.7 V):
- Connect it to the JST connector on the base board labeled “BAT”.
- Verify the polarity and voltage are correct (usually indicated on the battery and datasheet).
- Connect the solar panel (optional, for autonomous use):
- Insert the panel’s cable into the JST “SOLAR” connector on the RAK5005-O.
- Use a compatible 5 V panel to avoid damaging the board.
- Verify power-on:
- When connecting the battery or USB, the board’s LED should blink.
- If it doesn’t, check the battery connection or charge level.
- Enclosure assembly (optional):
- Use a waterproof IP65-type case if it will be installed outdoors.
This step is necessary to upload the program to the node and debug its operation.
Detailed steps:- Connect the node via USB Type-C to the computer.
- Install the CP210x or CDC USB drivers if the operating system doesn’t automatically detect the COM port of the RAK11300.
- Check from Device Manager (Windows) or ls /dev/tty* on Linux that the port appears correctly.
- It is not necessary to disconnect the battery to program the device, but it can be done for safety.Make sure to leave room for the antenna and solar/battery cable inputs.
This step prepares your development environment to properly program the RAK11300 module.
Step-by-step instructions:- Install the Arduino IDE from arduino.cc.
- Open the menu File > Preferences and add the following URL to the "Additional Board URLs" field:
- Go to Tools > Board > Board Manager, search for "RAKwireless", and select "WisBlock RAK11300".
- Install the following libraries from the Library Manager:
- Adafruit BME680 (sensor)
- LoRaWAN RUI3 by RAKWireless (LoRa)
- WisBlock-API (functions for communication and power)
- Restart the Arduino IDE to apply the changes.
With the hardware connected and the environment ready, this step allows you to upload the program that will read the sensor and send the data to TTN.
Key steps:- Open the example sketch or custom code (such as the one we’ve prepared).
- In Tools > Board, select "RAK11300 WisBlock".
- In Tools > Port, choose the corresponding COM port.
- Enter the device keys (DevEUI, AppEUI, AppKey) if using OTAA.Click the Upload button.
- If the upload is successful, you’ll see in the console:
- Open the Serial Monitor (Ctrl + Shift + M) at 115200 baud and observe the sensor data and LoRa transmission confirmation.
- If everything is working correctly, every 5 minutes you will see temperature, humidity, pressure, and air quality index data in the serial monitor, along with a message confirming the LoRa transmission.
- The node automatically enters low-power mode (deep sleep) between transmissions to conserve energy, especially useful in solar-powered operation.5. Creators and Acknowledgments
- Name: Miguel Montiel
- Role: Designer, hardware integrator, programmer, and technical manager of the system.
- Motivation: Developing an educational and technical solution for environmental monitoring in hydroponic cultivation, with a focus on sustainability, energy self-sufficiency, and practical learning of IoT technologies.
- RAKWireless:
- Manufacturer of WisBlock modules (RAK11300, RAK1906, Gateway Edge Lite 2) used in the project.
- Provides high-quality technical documentation and a repository of basic examples to get started quickly.
- The Things Network (TTN):
- A global LoRaWAN community offering free, accessible, and scalable infrastructure.
- Open platform and comprehensive documentation that allows students, makers, and businesses to deploy low-cost IoT networks.
- DSIoT Project:
- Template and philosophy based on the Erasmus+ program to promote educational projects integrating sustainability and technology.
- Proposals for accessible activities addressing environmental issues through intelligent use of sensors and interconnectivity.
- Bosch BME680 Datasheet & Applications:
- Technical inspiration for sensor use in environmental quality analysis.
- RAKWireless Official Examples:
- Foundation for LoRaWAN OTAA code and compact payload structure.
- WisBlock Documentation (RAKWireless)https://docs.rakwireless.com/Product-Categories/WisBlock
- The Things Network Docshttps://www.thethingsnetwork.org/docs
- Adafruit BME680 Sensor Libraryhttps://github.com/adafruit/Adafruit_BME680
- WisBlock Examples Repository (GitHub)https://github.com/RAKWireless/WisBlock
- Agenda 2030 – Sustainable Development Goals (SDGs)https://www.un.org/sustainabledevelopment/es/
Comments