- Basic knowledge of electronics
- Wire a simple circuit on a breadboard
- Programmation en Arduino (C/C++)
- Knowledge of the LoRaWAN protocol
- Using TTN (The Things Network) to send data
- Reading datasheets
Did you know? Bees help pollinate 80% of flowering plants and are responsible for 35% of the food we eat! Without bees, we’d lose apples, strawberries, tomatoes… and maybe even chocolate!
But today, beekeeping faces several major challenges threatening the survival of bee colonies.
Indeed, since the 1990s, beekeepers have observed a strange and scary phenomenon: Colony Collapse Disorder, or CCD. Each winter, 20% to 50% of bee colonies disappear, compared to just 10% before. This massive loss of bees is due to a number of threats such as Varroa mites, Asian hornets, new insecticides (neonicotinoids acting on insects' nervous systems), climate change (alters the availability of floral resources, disrupting their diet) and even hive theft (forces beekeepers to increase surveillance and security of their facilities).
And as Albert Einstein once (probably an apocryphal quote) said “If the bees disappeared, humanity would only have four years left to live.”
To reduce bee colony losses, we have three options: preserve traditional beekeeping methods, adopt natural beekeeping practices or use cutting-edge technologies. In a context of growing environmental and economic challenges, the use of modern technologies is essential. If the aim is to produce honey efficiently, we need to develop an innovative prototype capable of improving productivity, colony resilience and optimizing the beekeeper's workload.
Our goal is to build a complete embedded system with sensors, microcontroller, communication module and electronics for energy management. Obviously, this system must be robust, reliable and extremely low-power.
FeaturesThe Open Ruche project consists in building a hive monitoring system.
At the end of this project, we succeeded on obtaining and we made a prototype connected and energy-efficient, smart and AI-powered and waterproof that collects data on:
- The temperature and humidity (inside and outside the hive)
- The light level (sun exposure)
- The weight of the hive (for honey production or theft detection)
- Battery level of the system, recharged by a solar panel
- Queen presence using AI-powered sound analysis
Our prototype also includes:
- Real-time monitoring of hive data, 24/7
- Automatic alerts when anomalies are detected (weight loss, low battery, temperature drop…)
- Historical data logging for long-term analysis
- Data transmission via LoRa every 10 minutes (configurable via downlink)
- A startup LED that lights up for a few seconds when the system boots
And all in a sturdy case that can be left outside all year round.
- A - Temperature and humidity sensors
Our system uses a combination of temperature and humidity sensors to ensure accurate and reliable monitoring of the beehive’s environment. Inside the hive, we have two DS18B20 sensors dedicated to measuring temperature, on the left and right of the hive, and a DHT22 sensor that provides both temperature and humidity data, in the center of the hive. To protect the DHT22 from damage, it will be encapsulated in a custom 3D-printed enclosure, ensuring durability while maintaining accurate readings. This redundancy enhances reliability, allowing the system to remain functional even if one sensor fails. For external conditions, we use an SHT31 sensor, which measures both temperature and humidity outside the hive, providing valuable insights into the environmental factors affecting the colony.
- B - Brightness sensor
The BH1750 light sensor is positioned above the hive, alongside the solar panel, inside a transparent enclosure that allows light to pass through. This sensor enables us to remotely monitor the number of sunlight hours, providing valuable insights into the hive’s exposure to natural light. This data can help correlate environmental conditions with bee activity and energy generation from the solar panel.
- C - Battery and solar panel
The system is powered by a 3.7V 2000mAh LiPo battery, which is recharged using a solar panel. The charging process is managed by a LiPo Rider Pro board, which regulates the energy input and provides a stable 5V DC output to power the components. This setup ensures the system remains autonomous and operational even in remote locations, reducing the need for manual intervention.
- D - Weight sensor
The scale sensor (equivalent to Bosch H40A) is placed underneath the hive to continuously monitor its weight. It is connected to an HX711 load cell amplifier, which ensures accurate weight measurements. This data provides valuable insights into honey production, bee activity, and colony health. Additionally, sudden weight changes can help detect potential hive theft, allowing for quick intervention if necessary.
- E - Sensor testing
To ensure that all the sensors and modules we use in the Open Hive project work well, are accurate and reliable. We tested each component with reference equipment to validate our prototype under conditions close to reality.
To check that the DHT22 sensor, DS18B20 probes and SHT31 probe were giving consistent values, we compared their measurements with those of a reference mini thermo-/humidity meter (DEM500 RI3693).
All sensors were placed under the same conditions (outside in full sunlight, over a glass of water, in a closed room) to ensure a consistent comparison.
Next, the temperature and humidity levels were taken several times at regular intervals, and the differences between the sensors and the reference instrument were noted. If the difference was less than 1°C or 5% humidity, the data was considered reliable.
For weight, we used a “real” Terraillon scale (Max: 180 kg, graduation: 100 g) supplied by the by our school's workshop as a reference tool.
We took turns weighing ourselves on the scale connected to the HX711 amplifier, then compared the results with those obtained on the Terraillon scale. As long as the difference between the real scale measurement and that of our weight sensor was within ±100 g, we considered the measurement reliable.
A Velleman DEM301 LightMETER luxmeter was used as a reference for the brightness test. This device can measure light intensities up to 400,000 lux, with an accuracy of ±3% for low light levels (<10,000 lux) and ±4% (above 10,000 lux).
The two sensors (BH1750 and luxmeter) were placed side by side under different conditions: in full sunlight, in the dark in a box. The values measured by the BH1750 were then compared with those given by the luxmeter. If the difference was less than 50 lux, the measurement was considered correct.
For the battery test, we used a BRYMEN BM257s TrueRMS multimeter as a reference tool.
We compared the value measured on the DAC analog output of our MKR WAN 1310 board with that given by a multimeter connected to the output of the voltage divider bridge. We took several measurements at different times, for example when the LiPo Rider Pro board was fully charged (green OK LED lit) or after one or more hours of use. As long as the difference remained below 20 mV, the measurement was considered reliable.
Here is a table summarizing all our sensors with their operating range and accuracy:
To ensure that the data was actually transmitted to The Things Network (TTN), we first connected the LoRa antenna before transmitting, otherwise we risk damaging the LoRa module's RF output stage.
We then sent several frames containing measurements from all our sensors (temperature, humidity, luminosity, weight, battery). We compared the values sent live on the Arduino serial monitor with those received in the TTN console, allowing us to check in parallel that the payload formatter used to decode the data was working correctly.
Once the data had been correctly decoded on TTN, it was automatically transmitted to Ubidots via Webhook integration. We checked that each variable was correctly named and transmitted in the correct format according to the sensor.)
The correct display of graphs, gauges and data histories enabled us to confirm that the entire transmission chain, from the sensor to the visualization interface, was operating correctly.
A - Data Collection and Labeling
Our AI module is dedicated to detecting the presence of the queen—or confirming the complete absence of bees—in the beehive. We primarily utilized the “Smart Bee Colony Monitor: Clips of Beehive Sounds” dataset from Kaggle. To streamline the labeling process in Edge Impulse, we developed a Python script to systematically rename the audio files. In parallel, we also trained a model on a professor-provided dataset designed to classify “No Bee,” “No Queen,” and “Queen Present.” Although this secondary model showed strong theoretical performance, its real-world implementation on the Nano 33 BLE Sense was inconsistent, so we ultimately did not deploy it.
B - Model Training and Feature Extraction
Model training was conducted on Edge Impulse. We initially experimented with Mel Filterbank Energy (MFE), which achieved nearly 100% accuracy during training. However, despite these impressive results, the MFE approach did not translate well to field conditions. We therefore chose to use Mel-Frequency Cepstral Coefficients (MFCC) for feature extraction. Although the MFCC-based model delivered slightly lower training accuracy (around 85–90%), it provided significantly more reliable performance in practical applications.
C - System Integration and Deployment
The AI module was integrated into our prototype using the Nano 33 BLE Sense. We connected the Nano’s TX pin to the RX pin of the MKR WAN 1310, with proper matching of ground (GND to GND) and voltage levels (3.3 V to 3.3 V), to ensure effective transmission of inference results to TTN. One challenge encountered was the increased power consumption due to the AI processes—the current draw rose to approximately 35 mA compared to under 10 mA without AI. Despite this, the MFCC-based model offers robust and reliable queen detection, ensuring the system accurately differentiates between a hive with a queen, one without a queen, and an empty hive.
Future work will focus on further optimizing energy consumption and refining model performance with additional real-hive data, potentially revisiting alternative feature extraction methods or integrating hybrid approaches for even better efficiency.
III - Full System- A- PCB design
The entire system was designed using KiCad to model the electrical circuit, which was first tested on a Labdec prototyping board. Given the number of sensors involved, this testing phase was crucial to ensure proper functionality and compatibility. Once validated, we finalized the PCB schematic, which was then printed and soldered. This structured approach allowed us to refine the design, optimize connections, and ensure a reliable and efficient final assembly.
- B - Production of the box
To ensure the durability and waterproofing of our system, we encapsulated all components inside a PVC waterproof enclosure. This robust housing protects the electronics from environmental factors while keeping the system reliable over time. The sensor wiring is neatly organized through seven dedicated cutouts in the enclosure, allowing for secure and structured cable management:
- On/Off Button
- Under the hive: Weight sensor (original cable)
- Top of the hive: Solar panel + light sensor (6 wires, 1.5m-2m cable)
- Inside the hive: DHT22 + 2x DS18B20 (5 wires, 1m cable)
- Outside the hive: SHT31 (3 wires, 20-30cm cable)
- Inside for AI processing: Nano 33 BLE Sense (4 wires, 50cm cable)
- LoRa SNOC Antenna
After assembling all the components and sealing them inside the waterproof enclosure, we deployed our prototype on a real beehive located in Saint-Cyr-l'École to test it in real-life conditions.
Here are the results we obtained on BEEP after letting our system run for two weeks:
This project was an excellent experience on every level: technical, organizational, collaborative and even human. It enabled us to work as a team, from the search for the material to the unit testing of the sensors, right through to the design of the housing and installation on a real hive.
We're particularly pleased with what we've achieved, because our prototype meets a real need in the beekeeping world. We're proud to have contributed, in our own small way, to the preservation of bees.
For most of us, this was the first time we'd programmed with an Arduino. It was an enriching discovery that helped us to progress technically.
We used many of the skills we'd learned in class:
- Using the LoRaWAN network
- PCB design and soldering
- 3D printing of enclosures
- Optimizing energy consumption
- Creating and customizing a dashboard on Ubidots to provide a fluid user experience
A real engineering project, useful, concrete and exciting. Thank you for following our Open Ruche adventure!
ContactIf you have any questions, for additional information you can send an email to the following addresses:
ayoub.ladjici@etu.sorbonne-universite.fr
theotime.quiret@etu.sorbonne-universite.fr
ilias.amsal@etu.sorbonne-universite.fr
Comments
Please log in or sign up to comment.