Bees play a crucial role in our ecosystem. They are much more than honey producers: they are the guardians of biodiversity. By pollinating nearly 80% of flowering plants, bees allow many plant species to reproduce and so contribute to the richness of our environment. To help me look after these living creatures, sensors let me monitor the hives at all times.
Main goal: track changes in the hive’s weight and check the temperature in the brood. These two factors show the health of a hive and allow a quick response.
Specifications:
- Measure weight and temperature every 5 minutes
- Send the data to a server (Internet access 150+ m away)
- Energy-autonomous, so low power consumption
- Web interface to view the data and follow changes over time
- Uses an Arduino Pro Mini, 3.3 V operating voltage
Data transmission:
My Internet access is about 150 metres from the apiary, which is too far for a Wi-Fi connection. So I chose a radio link using the LoRa protocol. The system sends the data by radio to a gateway connected over Wi-Fi.
Operating diagram
Hive unit
Sensors:
To measure the weight, bear in mind that a hive can weigh up to 70 kg. So what better than a bathroom scale? The weight sensor is made of four load cells and an amplifier. Under pressure, the metal of the cell deforms slightly, which changes its internal resistance. A module connected to the cells amplifies the signal and converts it into a digital value. The system’s operating range is 0 to 200 kg.
The temperature sensor must be waterproof and bee-proof. The temperature inside a hive is about 35 °C. I use the DS18B20 sensor, powered at 3.3 V, which provides a digital reading. Its operating range is -55 to 125 °C, with an accuracy of 0.1 °C. It costs €5.
LoRa transmitter/receiver
LoRa (Long Range) is a long-range, low-power wireless communication technology, mainly used for IoT (Internet of Things) networks. LoRa works in unlicensed frequency bands (such as 868 MHz or 433 MHz in Europe) and connects sensors and devices over long distances, from a few kilometres in urban areas to more than 10 km in rural areas, while using very little energy. The protocol uses spread-spectrum modulation (Chirp Spread Spectrum) to ensure robust communication even with interference.
In my case, I set up a “private” LoRa network with a transmitter and a receiver. That way I don’t need a subscription, as one would otherwise go through a provider (such as Orange, Bouygues, etc.) for the radio link to the Internet.
I use the LoRa RA-02 module (433 MHz), connected to an Arduino. I reached 2 km without losing the signal. It costs €5 on AliExpress and €10 on Amazon. The module uses the Arduino’s SPI interface. Its consumption is 10.8 mA when receiving, 120 mA when transmitting and 0.2 µA in sleep mode.
Connected scale diagram:
To use the HX711 module with 4 load cells, I followed Indrek Luuk’s article, which explains the mechanics and electronics of the scale very well. Read the article
Microcontroller:
Hive system:
Data receiving unit
The receiving unit is made of a LoRa module and an ESP8266 D1 mini. Once the data is received, it is sent over Wi-Fi to a database on my web server, where a PHP program processes it.
The red and green LEDs show the connection status. Green: all good. Red: connection to the hive lost. Red and green: Wi-Fi connection lost.