Close

Slowly moving forward

A project log for Bee hive health monitor

This project will monitor the weight changes in the hive along with some environmental items to provide real time indicators of hive health

sparks.ronsparks.ron 10/30/2020 at 02:210 Comments
Well, we have the HX711 and scales figured out but each set seems to require its own calibration. For the scales we were converting the actual performance is a curve (exponential) and not a straight line. The two github HX711 libraries we tried are linear approximations only and do not work over the full range of the scale. The solution is to approximate the response on our own, which we have done. First you access the raw ADC reading from the HX711 and then plug it into our exponential curve equation. The ESP8266 has the needed exponential and logarithmic functions to handle this easily. For you math lovers the best fit equation is in the traditional exponential form Rdg = A*exp((wt-mu)^2/(2*sigma^2) where wt is the actual weight on the scale and Rdg is the corresponding ADC raw value. For our first scale the constants were A = 69,470 mu = 301.48 sigma = 88.42 Our next test is to install the clone controllers on the other modified scales and see how much these constants vary from scale to scale. Once that is done we can deploy them under the hives and start real world testing. After all this complication with the sensors and ADC, we have decided we will hold back one unit and put it on a mounting frame with a constant fixed weight on it. That will give us a control to use to back out any noticeable variations due to temperature, etc. The whole focus for these scales is on the relative changes day-to-day and not the absolute accurate weight. If we can just reliably tell the change in weight, that can be plotted over time and give the answer we need about hive size and honey production/use. Another thing that was accomplished this summer was extensive continuous real time data collection for temperature and humidity. Both the Sensirion and Honeywell sensors did well in our hot and humid environment. Neither one showed any signs of saturation even though they often experienced 97-100% RH. An old queen cage has been modified to hold this sensor for placement inside the hive. We are still looking for a suitable wiring option and will be testing 4 conductor ribbon cable, Cat5 Ethernet cable, and 2 shielded 2 pair audio cable. The winner will be the approach that has the easiest mechanical installation combined with no signal degradation. The software was completely rewritten this summer to allow easy changing of sensors, MQTT broker data, WiFi data, etc. Now that the program is modularized, the next step will be to convert the various functions and move them out to a library where that makes sense. The long term goal is to have the main program hold all the needed data that will change from unit to unit and the library(ies) hold all the computation, communications, and control functions.

Discussions