This is the place to collect my scripts for the beescale, that are not (yet) incorporatet into hiveeyes. See more (sorry, in German language only):
PHP Shell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.


This is the place to collect my scripts for the beescale, that are not (yet) incorporatet into hiveeyes. For more prose about the beescale see the blog (only in German language).

Data Stream

The data source is a sensor node consisting of an Arduino Uno with a Dragino Yun Shield 2.4 ontop running OpenWrt. OpenWrt's mjpg_streamer collects the beecam image every 15 minutes and saves it to the Yun's SD card. The Arduino firmware is periodically collecting the data from all the sensors, writes it to the Yun Shield's SD card for backup purposes and passes it via HTTP Push over an USB connected GSM dongle (no Wlan nor Freifunk nearby!) through OpenVPN to a php-script at A OpenWrt watchdog is reconnecting all network interfaces if GSM or VPN fail to connect. The script at writes the data to two different databases: First a flatfile database (csv) right on the server and second via HTTP GET to Kotori at A cron job at the webserver sucks the latest image from the Yun's SD card every 15 minutes. The flatfile is visualized by graph.php, which is relying on dygraphs, a js charts framework. This graph is cleaned, completed and repaired manually every once in a while. A Raw data graph is also available. This is the historical and stabel approach. Kotori however is administrating a source gateway and routes the data into the time series database influxDB. Grafana is getting the data from there and displays them. Hiveeyes is the experimental and trendsetting approach.

Content of the beescale Repository

  • Folder OpenWrt: config and other custom beescale files of dragino yun shield's linux component running openwrt.
    • shell script that produces latest.jpg from most recent date-stamp-named-snapshot of usb webcam driven by mjpg_streamer.
    • shell script that checks connection from yun to web server and restarts connections if necessary. run by yun's cron.
  • beescale-yun-ds18b20-two_load_cells-dht22-switch-sd-lux-lite: arduino yun firmware/"sketch". Better get it from the hiveeyes repo: node-yun-http.ino
  • add_line2.php: collects data and writes to databases.
  • graph.php: creates visible representations (charts) based on dygraphs js-framework.
  • graph_pure.php: creates visible representation (charts) with the raw data, no spikes eliminated, based on dygraphs js-framework.
  • shell script that downloads beecam-image from arduino yun's sd-card, processes it with a timestamp of creation date (imagemagick) and saves it on web-server as latest.jpg for display on web page.
  • sensorik.csv: example flat file database file.
  • sensorik_pure.csv: example flat file database file with uncorrected raw data.