Measuring the weight of a beehive

Yes, I will publish code and constructions files. I am in a beta / alpha phase so not all is perfect, e.g. I have an design error in the PCB file, so I have to connect two pins to the Stalker directly and not over the shield. But one prototype with 2 DHT22 or 33 sensors, 5 DS18B20 and load cell is sending data every 20 minutes since over four weeks without any problem from my balcony. We set up an other installation some days ago with reduced sensors--only humidity/temperature outside and the weight--and this is running also.

You can find the graph of a test installation under

It is an interactive graph. You can select an area with the mouse--the timeline or the value range--so you can zoom in. With a double click you got back to all datapoints: Under the graph there are check boxes for every data series. If one chosen, for example only the weight and all other off, the script scales automatically the graphic so that the current values are populate the full scale range.


I use dygraphs for visualization, a JavaScript library that deals with many data points. It runs as browser side JS, not on the server Thus, the first call may take more time when thousands records are loaded but if you then zoom in or out is the super fast.

The raw data, which the script directly processes, are simple comma-delimited values on the server:

Date/Time,Weight,Outside Temperature,Outside Humidity,Voltage
2016/06/15 20:34:38,  71.892, 17.3, 99.9, 4.08
2016/06/15 21:34:38,  71.810, 17.2, 99.9, 4.07
2016/06/15 22:34:38,  71.692, 16.3, 99.9, 4.07
2016/06/15 23:34:38,  71.614, 16.0, 99.9, 4.07
2016/06/16 01:34:38,  71.525, 15.4, 99.9, 4.06
2016/06/16 02:34:38,  71.470, 15.0, 99.9, 4.06
2016/06/16 03:34:38,  71.405, 14.0, 99.9, 4.06
2016/06/16 04:34:38,  71.363, 13.5, 99.9, 4.06
2016/06/16 05:34:38,  71.329, 13.3, 99.9, 4.05
2016/06/16 06:34:38,  71.378, 14.6, 99.9, 4.06
2016/06/16 07:34:38,  71.439, 22.0, 78.6, 4.08
2016/06/16 08:34:38,  71.496, 21.6, 71.1, 4.11
2016/06/16 09:34:38,  71.339, 21.9, 76.0, 4.14
2016/06/16 10:34:38,  71.216, 21.4, 73.9, 4.17
2016/06/16 11:34:38,  71.252, 22.0, 75.0, 4.18
2016/06/16 12:34:38,  71.245, 22.5, 64.6, 4.18

You can see on the first photo the complete bee monitoring system: - The main electronics in the middle. - Right in blue, a drilled cup with a DHT33 / combined humidity/temperature sensor for outdoors. - Below are the load cell for a unilateral weight with aluminum L-profiles. - On top 5 DS18B20 temperature sensors (can be more also) for the brood nest area. - Left side in curlers (against cementing) a DHT33 for indoor use.

All sensors are connected with round cables, which can be good passed through the screwable, waterproof cable glands on the case. An exception is the temperature array for inside (on top of the photo). There is a small board as flat cable connector. With this flat cable it is very easy to connect a pin header as as branch for the various temperature sensors between the combs.


The electronic case with a small solar cell under the transparent acrylic cover. The box is waterproof. The screws started after a wet day to rust. The box in the photo is on the balcony for about a month.


Inside the box it's quite busy:

  • At the bottom you can see the Seeeduino Stalker (red board), an Arduino derivative with additional clock (RTC), a charging circuit for solar panel and Lipo and a bee socket. "Bee socket" has nothing to do with bees ... haha! On the bee socket, the GSM / GPRS module sits, with "SIM800" print.
  • Right (white) is the self-designed shield with the load cells IC, some screw terminals, resistors, caps. Currently we have connections for a load cell and up to 3 DHTxx or DS18B20 sensors.
  • The small printed antenna for the modem is between board and housing, a black cable goes (almost invisible in the pic) from the modem to the antenna
  • The rechargeable battery, a Lipo, is under the Stalker and and so not visible.


Soem close ups Lipo, printed antenna, DHT on a smal breakout so that it fits in a curler, same DHT covered by a drilled Ikea cup for weather protection:




And I thought we were high tech when we would go out and lift each side of our hives with a fishing scale to see what they weighed ! The one thing we really had to watch for was that they had enough going into winter and in the spring, that they didn't go empty (the Seattle area is notorious for 2-3 weeks of nice weather in April which gets them all cranked up, the queen laying then 2-3 weeks of cold/rain/snow). You could lose a hive easily in late spring when that happened (cold / rain was also typically when your new queens arrived in the mail with no way to put them in the hives :confused: )

gpsmikey: [...] and lift each side of our hives with a fishing scale to see what they weighed !

There are a lot of commercial scales out that count on a double "H" as scale frame. The load cell is mounted on the "-" of the "H", see e.g. . I've seen also some DIY prototypes of this scale type. Most wiggly but I don't know is it due to the concept at all or is it the amateur welding skills or the weak and too thin material.

Nevertheless I decided to count on a single side weighting process. Construction is easy, hive stands still stable, and of cause it is cheaper than a full-blown H frame.

I did some control measurement (Herold Magazin with Zander frames similar to a Langstroth Hive) last autumn--I did not write numbers down--but I had maximum 2 kg difference between the front and the back side of a hive.

What are your experiences, do you think a single side measurement (on the back) is sufficient? I asked in a German beekeeper discussion forum and most voted for a compete weighting procedure.

We were not that concerned with the accuracy as we were with making sure they were at least 80 pounds or more going into winter (pref. over 100) and they did not drop below about 35-40 in the spring to avoid them starving out. It doesn't surprise me you get different readings depending on the side - I would think the side with the most sun would be the heaviest, but I never actually checked them that way (and this was before all the problems with colony collapse we are seeing these days).


It's my first post but I have been watching the progress of Lars project. So let's go:

I have a similar situation with the beehives. I want to monitor the weight of a freezer full of product to see if it is getting empty (when it becomes light), to send more products without the need to send someone to check.

This could also serve to warn about an interruption in the supply of freezer energy, so I could check what happened before the melting of the products. :D

I was thinking of installing the weight ranges between the wheels and the base of the freezer and a system that would send daily (or on demand) weight measurements by sms. Energy would be no problem because the system could be connected to power supply of freezer.

Is there any practical and feasible way to test this idea?

I appreciate any consideration. ;)


One problem with strain gauge between wheel and freezer is that when you move it a little bump on the floor will have a stress/impact far greater than normal load. Strain gauges usually resist 150-200% stress of their nominal measuring force limit, but more than that will very likely affect their readings.
I would use a fixed weight-measuring frame with screws to lift the fridge a few mm once it is in its place.

Very good idea Blimpyway. Can you tell me how can I connect the weight scale sensor with a gsm data logger (data logger model/ what I have to check to ensure the weight sensor compatibility)?

I'm not sure I understand the question.

You should look into tutorials, examples about how to: - Connect HX711 (strain gauge sensor) to arduino. - Connect arduino to a GSM module or modem to send SMS-es

Combine the two in a arduino program that reads weight and sends weight data via SMS

If there-s any chance the freezer be located in a WiFi coverage area, I would use Wifi instead of GSM.

Clemens is there a chance that you can find time to make af software version for Stalker V3.1 (DS1337S RTC and GPSBee ) of yours OpenHive ?

Hello Clemens and other guys,

Clemens, I have some questions for you if you can answer please.

I am working on Arduino based bee scale project and I am experiencing some problems with ADC and GSM module interference. I am using shielded HX711 breakout board and SIM800L module. Everything works ok till SIM800L module starts to communicates with network. When GSM module receives SMS or voice call ADC data become corrupt so weight is not correct. All is powered from 3.7V 4000mAh Li battery. I've tried to power GSM module from other battery but problem still persist. It looks like interference comes from RF side. I have made dual side PCB (photo attached) with separate ground planes and decoupling for analog, digital and GSM sections but again problem persist. ADC reading is averaged in firmware but it does not helped a lot. I do not know what else to try. What about your experience about GSM module and bee hive weight scale?

Sorry for my bad English. :-[

Here is picture…

Bole dont you think its because of the unshielded wire from your loadcell ? The wire should be as short as possible, othervise the vill act as "a pickup" for any noise (and the GSM-signal).

Sorry for my bad English. :-[

Hi all.
Since I last posted I have still been working on my scales but sporadically. I have working code - and it was working well, I thought I had it at the point where I just needed to start tidying it (understatement). I had the scales running for about 1 week continuously, then was out of the country for 3 weeks. On returning I set it up again and without changing the code it returned an error when trying to upload the scale data. I am not too sure why but my best guess is that when I send the USSD to retrieve balance info, the returned message is overflowing the buffer and causing the AT+CIPSEND to fail. I assume that when it was working the message returned from the network provide was less than the 64 bytes and so the error was not occurring…would this make sense as a reason for the error to occur? The reason I know retrieving the balance is what causes the failure is because the upload works without error when I temporarily remove the balance function.

Please advise if best addressed under another thread.

The flow of the code is:
Normal setup
Power SIM900 and connect network
Query current date and time and send to RTC
Set interrupt alarm time depending on current time

Get weight
Get Balance
Power down

wait for interrupt

Serial output:


+CFUN: 1


Call Ready








+CCLK: "17/06/26,10:04:29+48"

RTC Time: 2000/1/1 0:1:7
Old datetime:  2000/1/1 0:1:8
New datetime:  2017/6/26 10:4:28
A1 Enabled for 4 PM
A1 Enabled for 4 PM in Setup



+CFUN: 1


*PSUTTZ: 2017, 6, 25,AT+CGATT=1





Weighing Mode Active

check balance string:
Second Pass






A1 Enabled in Loop
Going to Sleep Now

My reponse code (which I think could use significant improvement:

void Response()

and the balance query code:

void Balance(){
      //balance_character =;
      int startPos = (balance_content.indexOf("$"));
    if (isdigit(balance_content.charAt(startPos)))
while (++startPos < balance_content.length());

// Then find the index of the last digit    
int endPos = startPos;
    if (isWhitespace(balance_content.charAt(endPos)))
while (++endPos < balance_content.length());

    bal = balance_content.substring(startPos, endPos);

Just to emphasise, the code worked well previously and the only thing I can think changed is the Network response to balance inquiry. What I don’t understand is why the CIPSEND fails and I can only assume that when the buffer overflowed it times out the SIM900 “session”. I am not a proficient coder. I have written all the code with a lot of trial and error, which I know people wont appreciate - but ultimately I am a beekeeper and truly understanding this language has been beyond me.

Thanks in advance.


I found a quick solution - but as with all quick solutions it may not be the best. I just terminate the USSD session, as I had suspected it seems to be that the session is remaining open, either waiting for a reply or because I am not managing the buffer input well.

I end the session with


I would really like to improve my code, but as stated I have done my best with the skill level I have - is there somewhere on the forum I could submit my code for critique / improvement? or is this offered as a service?


Hello Folks!

With a friend beekeeper, we started to dig the subject a few yars ago. Like everybody, we started with the cheapest strain gauge we could find. Stability of the measure was disastrous. We thought about buying better load cell. But after research, and discussion with another beekeeper who also searched on the subject, and who has a background in physical measurement, came out of these discussions that there were no good tradeoff between price of the components, and quality (especially stability).

So we moved to a completely different approach, which can be much more DIY-friendly than load cells : we built an automated mechanical scale. Principle is pretty simple, you take a roman scale, a beam, suspend mass to weigh on one side, slide a counterweight the other side, an articulation between, and that's it. Mass to weigh = ratio of the distance articulation-counterweight / articulation-mass * mass of the counterweight.

Electronically, it becomes very simple, arduino has to drive a stepper motor, and check the status of a sensor (optical, reed..) to detect the balance. No analog layer...

Stability of the measure is dependent on the structural stability of the beam on its length, given there is no constraint on it in the length direction, we could say problem of stability is solved.

The tricky part is now to build something that integrates nicely under a hive. It's what we worked on. Quickly, we had prototypes that worked very well. Then we wanted to make a version that was easy to replicate if we needed to make 10, 20, 30..... And when we started this "industrialization", we thought about making more and sell it as kit.

Here we are, project is mature enough now : We release all the sources (mechanic, dedicated board, firmware, cloudware) for DIYers And for beekeepers who don't have {time/energy/skills} we propose for sale a kit.

If it sounds interesting enough, you may visit our website :

And the sources :

Cheers, Pierre

Fantastic project… I like the fact that you have discussed the pro and cons of various methods, and your product looks good.

Tom… :slight_smile:

Thanks Tom!
I posted here pictures of the previous designs, maybe more adapted to the build of a single scale on your own.

Hi, mate. I'm not a beekeeper, but it will be a good source of reference for the number if times that we get questions about weighing beehives.

There must be other applications that a platform like yours can be use for.

Thanks Tom...Merry Christmas

My last creation, a 4-point BeeScale. You are velcome to follow my scale on: My scale are named Beder-2.

Update every ½ hour at Sigfox net. Battery last more than a hole year.

(Cut and paste too your browser)

Hi Bee folks,

I have pondered this set of requirements more than once, have had family hives and a family friend was a commercial keeper and now have half a dozen hives for a family friend on my mothers small forest plot.

To justify the development of a cheap system the volumes should be large so that some knock off company starts to make a tolerable clone at falling prices.

So the key for volume is for this to be of value to larger apiaries. This means the replicated unit must be cheap and easy to install.

The reason I came here today and registered was that I saw by chance a new device I had not seen before and thought that it shared similarities to the task at hand and might work as a starting platform or at least as inspiration to some. This was a propane cylinder digital scale that are used to measure remaining cooking or heating gas. Prices were in the sub US$20 on Amazon with wired and wireless options. The same company could make a beehive scale for similar money and the search for everyone would be over.

However my solution to the problem if one wants to have something perhaps a bit more elegant was as follows. A force multiplying and summing 4 corner linkage such as one would see in a vintage mechanical bathroom scale but instead of a spring with position readout or a force sensor I had the idea to use another bit of consumer technology to load the links. My idea was to use the guts (or equivalent) of a blood pressure monitor to inflate or contract a membrane actuator and at a certain pressure it would cause the link to flip position (say 30mm movement) on cause a magnet to approach a reed-switch on a embedded IoT device such as the RuuviTag which can measure the temperature of the hive bottom and the position of the magnet and communicate via Bluetooth low energy (BLE) to a central station in the neighbourhood (they have achieved over 800m range in tests). The hives would have a mechanical weigh base with an actuator similar to the automotive units used to control the internal air-conditioning, central locking or turbo charger waste-gates. These are commodity actuators and will be repeatable. The base station would have a pipe loop with taps to each hive in the area and pump air or vacuum into the actuators and wait for each device to report that the magnet has changed position. It would then slowly (just like a blood pressure reading) let the pressure drop and listen for the reports from each RuuviTag for the moment when each hive comes back down to rest.

The benefits are no electrical connections between hives to cause electrical interference to electronics or bees due to lightning induced currents. Each hive has a free base temperature monitor. Each hive has a tamper indicator if the hive is lifted and the temperature changes or the base is lifted so the links flip over or extra sensors top and bottom. Base station can monitor cloud cover and ambient temperature for the group. Base can have GSM connection to data collection site and WiFi to keeper to do testing locally. Cost of pump and pressure sensor are shared between all the hives in one cluster. Base station can be run with power from electric fence that is used to keep out wild animals. The active lifting of the hive (only a millimetre or two needed) will break any propolis, mud or snow encrustations. There is only one well protected small sealed electrical enclosure in the hive with a 5 year CR2350 cell so minimal chance of rain causing a problem. Only one accurate pressure sensor required so drift and temperature can be managed better, perhaps even with one or two dummy hive base/s with an identical mechanical and pneumatic link system and known mass/es. Remote mounting the pump will mean that the hives only have a tiny disturbances once or twice a day at midnight and at sunrise (programmed) to wake the hive up for the new day.

The problems are cost compared to falling prices of cheap propane scales. The need to have periodically replaced desiccant on the air inlet port to prevent water in the pipes. The chance or lawnmowers or wild animals damaging the pipe system. And lastly the need to replace batteries periodically though the base could be solar powered in most places and the remotes have a many year life and can be shut down until the reed-switch is activated.

I prefer the idea of a vacuum rather than pressure as pipes will not try to jump off.

All that is needed is to make a viable prototype and a design from cheap materials (powered coated steel) and get quotes from 100 manufacturers and wait for one of them to clone it :-) I like the idea of a crowd designed open source design that has a ROBUST set of specifications and interfaces so that there would be a number of low cost sources. The market such scales will keep growing now with the threat to bee populations and desire to increase monitoring. The design will work with any product that needs accurate daily or twice daily measurements.



Lahti, Finland