my code for the energyMonitor can be fond here
http://code.google.com/p/apagg-lmce/source/browse/#svn/trunkI have added logging of "state changed" to DataLogger_Plugin.cpp and used unit=5 for the database
The energyGraph that I am working on uses the "state" from the datalogger and the "energy consumption" parameter I have added to template 37, 38 and 1897. I am still struggling to plot the correct data in the graph, but I think that energyMonitor.php should display the correct data.
all my devices that report state are z-wave I dont know how things like X-10 or KNX will work.