So. Reading an LCD screen was more difficult than I first assumed. My code is still good for reading my Thermostat values. However for energy monitoring and £20 I found a better solution.
Looking on the net a particular model of energy monitor was recommended for easy monitoring: the Current Cost EnviR.
This monitor has two big advantages:
- A USB data cable that allows a serial port connection; and
- Simple XML output over this connection.
These two features were a breath of fresh air after dealing with the proprietary mess that is the Owl/Electrisave energy monitor (just google).
A little trick: the EnviR was supplied by EON to its customers. While the EnviR is listed for about £50-70 new you can also buy cheap it on eBay by way of this EON link. Look for items listed as EON energy monitor and compare with the picture above (also look for the white RJ45 to USB cable – the monitor also comes in black).
Once you have a monitor get code from https://github.com/mapkyca/Current-Cost-EnviR
cd ~/Code git clone https://github.com/mapkyca/Current-Cost-EnviR
(Many thanks to Marcus Povey for this http://www.marcus-povey.co.uk.)
If pip is not installed:
sudo apt-get install python-pip
sudo pip install pyserial
I got an error that the serial port was already open – this was resolved by deleting the following line:
I then found that my energy usage was shown as 0 Watts. Doing a print out of the read data I noticed that there were three channels. I had plugged my monitor sensor into the third input on the energy monitor transmitter: hence the reading was on channel 3 (<ch3>):
Through trial and error I worked out that channel 1 is the central sensor socket on the transmitter:
- Setup time correctly on monitor (or ignore and use datetime – datetime.datetime.now());
- Set up a local database and store the tuple: (timestamp, energy, temp);
- Clone data in Pachube/Cosm/Xively (now owned by LogMeIn!)?
3 thoughts on “Simple Energy Monitoring on Raspberry Pi”
Thanks for your link, glad it was useful!
Btw, you’ve got the repo link a bit wrong – you want Current-Cost, not Current-Code 😉
Just got an EnviR from eBay for about £10 get this working about 10 minutes. Thanks for that. Off to monitor our usage and see if I can save money
Just out of curiosity what is the minimum Wattage these can measure the lowest I have seen is 121W ?? Anyone seen anything lower ??