User Tools

Site Tools


energymonitor
no way to compare when less than two revisions

Differences

This shows you the differences between two versions of the page.


energymonitor [2016/04/08 09:25] (current) – created - external edit 127.0.0.1
Line 1: Line 1:
 +====== House Energy Monitor ======
 +
 +===== Hardware =====
 +
 +
 +This topic details a mini project using the [[http://www.eonenergy.com/At-Home/Products/Products-Electricity-And-Gas/Electricity-and-Gas/Energy-Saver.htm|EON Energy Monitor]]:
 +
 +{{05072008.jpg?350}}
 +
 +EON have being given them away "free" when you sign up to getting energy from them. It is infact a re-branded [[http://www.currentcost.co.uk| Current Cost]] Energy Monitor. 
 +
 +I noticed that on the bottom was an RJ45 connector, after a bit of Googling, I found [[http://www.yellowpark.net/cdalby/index.php/2008/06/15/setting-up-my-current-cost-meter| this]] and [[http://flickr.com/photos/pixelfrenzy/2499443217/|this]]. 
 +
 +So using Chris Hand's infomation, the interface on the RJ45 is:
 +
 +   * orange/white
 +   * orange
 +   * green/white (pin 7, data in to CurrentCost)
 +   * blue (pin 4, ground)
 +   * blue/white
 +   * green
 +   * brown/white
 +   * brown (pin 8, data out from CurrentCost) 
 +
 +The level is 3.3v TTL so cannot be connected directly to an RS232 port, however I don't have one of them free anyway, so I used a USB to TTL 3.3v [[http://www.ftdichip.com/Products/EvaluationKits/TTL-232R-3V3.htm|serial converter]] (also used by Chris Hand) from RS (part number 429-307). Current Cost do sell the cable for a good price, but what is the fun in that!!!
 +
 +Using an old Ethernet cable for an RJ45, connecting the USB to serial convert to the RJ45 connector was easy:
 +
 +{{05072008_003_.jpg?350}}
 +
 +
 +Just connect the pin 4 (blue) of the RJ45 to pin 1 (black) on the TTL-232R-3V3 and connect pin 8 (brown) of the RJ45 to pin 5 (yellow) on the TTL-232R-3V3. If I get time I will make a better cable, but for now this works. 
 +
 +
 +===== Software =====
 +
 +When the hardware connected, I used Minicom to check that it was working. There are two version of currrentCost available, one that runs at 2400 baud, and one that runs at 9600. Mine was a 9600. 
 +
 +The device spits out XML data every 6 seconds. You do not need to request data.
 +
 +I wrote a simple c program to read the XML stream and convert into a CSV file that gnuplot can understand. 
 +
 +The code can be found {{energymonitor.tar.gz|here}}
 +
 +This application runs on my Linux server and reads and converts the XML stream into the CSV file, I also have a cgi script to convert the CSV file into a picture. 
 +
 +   * {{powergraph.cgi.txt| Plotter Script }}
 +
 +This is an example plot:
 +
 +{{powergraph.cgi.png?350}}
 +
 +
 +[[LatestReadings]]
 +
  
energymonitor.txt · Last modified: 2016/04/08 09:25 by 127.0.0.1