GithubHelp home page GithubHelp logo

jaccorens / emonhub Goto Github PK

View Code? Open in Web Editor NEW

This project forked from openenergymonitor/emonhub

0.0 2.0 0.0 321 KB

emonHub acts as the link between your inputs and emonCMS

Home Page: emonhub.org

Shell 10.39% Python 89.61%

emonhub's Introduction

emonHub (emon-pi variant)

Emonhub is typically used in the OpenEnergyMonitor system to first read data received over serial from either the EmonPi board or the RFM12/69Pi adapter board and then second to then forward this data on to emoncms in a decoded ready-to-use form - based on the configuration in emonhub.conf

More generally: Emonhub consists of a series of interfacers that can read/subscribe or send/publish data to and from a multitude of services.

Emonhub is included on the pre-built SD card used by both the EmonPi and Emonbase. The documentation below convers installing the emon-pi variant of emonhub on linux for self build setups.

Emon-Pi variant

This variant of emonhub is based on @pb66 Paul Burnell's experimental branch adding:

  • Internal pub/sub message bus based on pydispatcher
  • Tested MQTT interfacer (integrated with new emoncms nodes module)
  • HTTP Emoncms interfacer (rather than reporter).
  • Reporters have been removed.
  • A multi-file implementation of interfacers.
  • Rx and tx modes for node decoding/encoding provides improved control support.
  • json based config file option so that emonhub.conf can be loaded by emoncms - intention is to provide config interface in emoncms.

Installing Emonhub

Emonhub requires the following dependencies:

Mosquitto: (see http://mosquitto.org/2013/01/mosquitto-debian-repository)

wget http://repo.mosquitto.org/debian/mosquitto-repo.gpg.key
sudo apt-key add mosquitto-repo.gpg.key
cd /etc/apt/sources.list.d/

Depending on which version of debian your using:

sudo wget http://repo.mosquitto.org/debian/mosquitto-wheezy.list

or:

sudo wget http://repo.mosquitto.org/debian/mosquitto-jessie.list

Update apt information:

sudo apt-get update

sudo apt-get install -y mosquitto python-pip python-serial python-configobj
sudo pip install paho-mqtt
sudo pip install pydispatcher

It is recommended to turn off mosquitto persistence

sudo nano /etc/mosquitto/mosquitto.conf

Set

persistence false

Install the emon-pi variant of emonhub:

git clone https://github.com/openenergymonitor/emonhub.git && emonhub/install
sudo service emonhub start

The emonhub configuration guide can be found here:

emonhub.conf configuration

To view the emonhub log via terminal on the emonpi or emonbase:

tail -f /var/log/emonhub.log

EmonHub Emoncms config module

If your using emoncms on the same raspberry pi as emonhub you may find the emoncms config module useful which provides in browser access to emonhub.conf and emonhub.log:

https://github.com/emoncms/config

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.