Automated solar PV stats

Following on from previous posts about our new solar PV installation, I have now implemented an automated process which pulls stats from the SMA SunnyBoy 4000TL bluetooth-enabled inverter, stores the stats in a MySQL database and then makes a daily chart available showing solar PV generation, looking something like this:

In a little bit more detail…

  • Everything is hosted on my Debian Linux server.
  • I use the excellent open source sma-bluetooth package (http://code.google.com/p/sma-bluetooth/) and the bluez-tools package to connect to my inverter via bluetooth. The smatool program within this package stores the data it downloads in a simple MySQL database.
  • I have a cron job which runs this data extraction every 5 minutes.
  • I then wrote a simple PHP script which uses the excellent pChart 2 library (http://www.pchart.net/) to generate a daily output chart which is hosted on my personal web server.

So, I can now keep track of how much electricity I am generating wherever I happen to be!