We moved into a new house last fall. Turns out we seem to be using a lot of energy there. Why is that? That's the question, based on the assumption that what you can measure you can manage.
Luckily, it's the year of the Lord 2021 and the house is equipped with a ✨smart meter✨. In this case it's an Easy Meter Q3A.
It has an optical D0 interface. I don't know what that means, but that's what I read. What I also read is that you can connect
a special usb reader to such an interface and it will output energy consuption data from the smart meter on
/dev/ttyUSB0 on linux. So I ordered
I plugged this into a raspberry pi zero, and indeed it started giving me output on
/dev/ttyUSB0. It looked like this:
/ESYXXXXXXXXX V3.XX 1-0:0.0.0*255(0XXXXXXXXXXXX) 1-0:1.8.0*255(00009XXX.8922100*kWh) 1-0:21.7.0*255(00002X.44*W) 1-0:41.7.0*255(0000X6.90*W) 1-0:61.7.0*255(0000X4.50*W) 1-0:1.7.0*255(000XX3.84*W) 1-0:96.5.5*255(X0) 0-0:96.1.255*255(1ESYXXXXXXXXXX) !
What is this? What does this mean? After some research with my favorite search engine, I stumbled upon this thread
with a very pragmatic approach to parsing and interpreting this code. I modified it a little and put it into a git repository.
main.py script I'm running as a cron job once every ten minutes.
For now I'm writing the data into an influx db. Maybe I'll just keep it that way. Or maybe I'll be conviced that I need a home assistant instance running, then I'll integrate it there.