New Frontend for Opensource Smartmeter

|

I never really liked the structure of my piMeter software. The combination of websockets for live data and a database for the historical data was cluttered and prone to error. Added to this i never felt happy with the javascript frontend in which all graphs were hardcoded for visualization.

Time to streamline the software and leave the visualization to people who know about it. Grafana and InfluxDB were the right candidates for this.

Installation of InfluxDB and Grafana

Add the Package Source:

    curl -sL https://repos.influxdata.com/influxdb.key | sudo apt-key add - source 
    /etc/lsb-release echo "deb https://repos.influxdata.com/${DISTRIB_ID,,} 
    ${DISTRIB_CODENAME} stable" | sudo tee /etc/apt/sources.list.d/influxdb.list


Install the database with apt-get and start the service:

    sudo apt-get update && sudo apt-get install influxdb
    sudo service influxdb start


With the command:

    influx

you can start the InfluxDB console and add a database for your piMeter

    CREATE DATABASE piMeter

Thats it.

Installing Grafana works the same way.

Add Package Source:

    echo "deb https://packagecloud.io/grafana/stable/debian/ wheezy main" | 
    sudo tee /etc/apt/sources.list.d/grafana.list curl https://packagecloud.io/gpg.key | 
    sudo apt-key add -

Install Grafana with apt-get and start the service:

    sudo apt-get update && sudo apt-get install grafana
    sudo service grafana-server start


You can now Log-In to your installation at www.yourDomain:3000 and build your Dashboard.

Grafana Dashboard
Ressources

Github

The Old Repository gets cleaned up and will be renamed to piMeter_hardware.
I would like to thank  orca-zhang for the really easy to use InfluxDB-Cpp Lib!