Vous êtes sur la page 1sur 4

Home Energy Monitor - now with added Twitter and

Pachube
VERSION 5

Created on: Jun 28, 2009 1:58 PM by Ian Bell - Last Modified: Jul 6, 2009 5:07 AM by Ian Bell

Requirements:
Application Software: LabVIEW Base Development System 8.6
Driver Software: NI-VISA
I posted this originally in the discussion forums - but I think it really belongs as a
document.

I got this "free" home energy monitor from my energy supply company. It's actually
developed by Current Cost www.currentcost.com. Two basic parts. A current clamp with
a wireless transmitter which you fit over the incoming supply cable plus a display unit
which you can site anywhere in the house. This unit displys current power, and (if you
put in the per kWHr cost) the cost per and per month of the current power consumption.
It also keeps track of historical data and temperature. Of interest to the DIY LabVIEW
developer - it has a serial port on an RJ45 connector. So I bought the serial - USB cable
from their ebay shop. Plugged it in. And after googling for the driver (their new website
is much better), fired up a simple LV VI and grabbed some data.

Turns out the device transmits a set of data in an XML format every 7 seconds or so. It is
a very simple format and - although I might convert it to the LabVIEW XML library later
- for now I just parse that string with standard string handling functions. (Look.....it's not
that the XML library is hard to use... its just overkill for this....anyway I first learnt
LabVIEW 15 years ago and I can "do" the string functions in my sleep....aaahhhh yes
that's "real" LabVIEW programming...from the GPIB era... when there were only a few
instruments drivers....ooops sorry drifted off for a moment there). On further reflection - I
am going to stick to the string functions - moving to the XML library will make the app
Windows specific. There is no reason this shouldn't work on MacOS or Linux.

So I now have a little LV program that gets the data and displays it graphically. (see
screen shot below). Also used it with the built in web server so I can check on it remotely.

Now - the point behind this is ....once you start monitoring power usage you want to
reduce it. To do the monitoring with LabVIEW needs the PC to be on and that consumes
around 100W... all the time ... and that costs - you get the idea. So next step is to get this
working on my home built Windows Home Server system, which is power optimised and
is on all the time. Then - add some proper historical logging and long term trending, send
usage email reports, text message alerts. Perhaps it could automate yelling at the children
when power usage goes over a certain limit It's at this point that your other half starts to
mutter - "LabVIEW all day and now all night.... you're addicted!".

Oh well output of the addiction is attached. ("Home Energy Monitor.zip")

Update

The original Home Energy Monitor program has now been updated. Not really tackled
much of my "Version 2 feature list" except for a couple of minor mods too make it work
OK on Windows Home Server (which is a thinly disguised Windows Server 2003). But I
have added the following:
Options dialog box with storage and retrieval to an INI file
Read and Display history data stroed on CurrentCost
Publishing of data to Pachube ("patch-bay" for sensors uses the VIs I already
uploaded see How to connect your LabVIEW app to Pachube
Publishing of energy consumption (2hr and 24h) and high power alarm status to
Twitter
Read and Display 2nd and 3rd input channels on CurrentCost Classic

This new version is attached below as "Home Energy Monitor-4.ZIP" and see
screenshot below

It is an interesting experiment and an evolving "meme" - this idea of bringing together


personal energy use and social networks. It is really powerful to be able to compare our
energy profile against other homes in UK and around the world.

I am questioning whether running this on the Windows Home Server machine is really
the best from an energy efficiency standpoint. Having the program has given me much
greater insight into our energy usage and looks like it has stimulated at least a 15%
reduction. But it now looks like at least 20% of our background electricity use is down to
the server. I am now looking at running this on a really low power (15W) machine - but it
ships with Xubuntu Linux - but apparently it will run XP. I will get around to testing the
app on Linux at some point.

Another potentially big job is to get the program working with the new CC128 "Envi"
device. This has much expanded I/O, the imminent luanch of indvidual device monitors
and even an OEM/"hobbyist" board with 2 AI and one DI which can be paired with a
channel.Slightly annoyed that the new device's XML output format is not an extension to
the original but is different in structure.

Note - latest version is attached as Home Energy Monitor-4.ZIP

Vous aimerez peut-être aussi