Tuesday, January 5, 2010
Using Google Visualization API for Power Monitoring
I just started playing around with the Visualization API today and it's pretty cool. Here's a short screencast I just did showing real-time power usage from our Brultech ECM-1240 power monitor. Every second, data from the ECM-1240 is stored in MySQL. The gauges are in a simple HTML page with a little AJAX to fetch the power data each second from MySQL. The API takes care of the graphics and updating them.
Monday, January 4, 2010
xPLGPix connects xPL to Google's Picasa Web Albums
Continuing with my Google tangent, I've just created a new app called xPLGPix. If you send it an xPL message specifying an album and JPG file, it will upload the picture to the specified album on Google's Picasa. You can read more about it here. I've tested it just a little, so it may be a little rough around the edges.
Saturday, January 2, 2010
xPLGSheet: An xPL interface to Google Doc Spreadsheets
I'm welcoming in 2010 with a new app called xPLGSheet. It allows you to query and edit a GDocs spreadsheet using xPL messages. Aside from the typical use of automated updates of a database, this app opens up possibilities of syncing remote systems via a shared spreadsheet. For more, go here.
Wednesday, December 30, 2009
Most Downloaded of 2009
Since 2009 is the first full year I developed applications, I thought it would be interesting to see which ones were most popular. I know 2009 isn't over yet, but the #1 app certainly won't be unseated by year's end. Here are the 10 most downloaded DoghouseLabs applications for 2009.
1. EventGhost xPL Plugin - 125 times
2. BlueTracker - 33
3. Blabber - 24
4. SageTV xPL Plugin - 20
5. xScript - 18
6. xPLSerial - 17
6. xEKG - 17
8. xPLAudreyTTS - 15
9. xPLGCal - 11
10. OSDBuffer - 9
Looking at the numbers, other than the EventGhost plugin, that's not a lot of downloads. Volume has never been my aim - these are things that I use in my home automation system and sharing them is my way of giving back for all the cool software and ideas I've benefited from over the past 15 years. I am surprised by how popular the EventGhost plugin is compared to all the other xPL apps. Also, I'm curious if anybody really uses the SageTV plugin besides me - as only one person has ever asked anything about it. Anyway, thanks for using my apps and reading my blog in 2009 and happy automating in 2010.
1. EventGhost xPL Plugin - 125 times
2. BlueTracker - 33
3. Blabber - 24
4. SageTV xPL Plugin - 20
5. xScript - 18
6. xPLSerial - 17
6. xEKG - 17
8. xPLAudreyTTS - 15
9. xPLGCal - 11
10. OSDBuffer - 9
Looking at the numbers, other than the EventGhost plugin, that's not a lot of downloads. Volume has never been my aim - these are things that I use in my home automation system and sharing them is my way of giving back for all the cool software and ideas I've benefited from over the past 15 years. I am surprised by how popular the EventGhost plugin is compared to all the other xPL apps. Also, I'm curious if anybody really uses the SageTV plugin besides me - as only one person has ever asked anything about it. Anyway, thanks for using my apps and reading my blog in 2009 and happy automating in 2010.
Sunday, December 27, 2009
New App: Noise
No, I haven't fallen off the face of the earth, but I admit that it's been a while since I last posted. I've been taking a break from automation stuff over the holidays, but I did work on something I've always wanted to implement...
Have you ever wanted to be automatically told that the baby is crying or the dog's barking? Introducing my latest xPL app, Noise. It uses your PC's mic (or possibly other input device), samples the input for a period of time, and issues an xPL sensor.basic message with information about the noise it detected, if any. You can read more about it here.
Have you ever wanted to be automatically told that the baby is crying or the dog's barking? Introducing my latest xPL app, Noise. It uses your PC's mic (or possibly other input device), samples the input for a period of time, and issues an xPL sensor.basic message with information about the noise it detected, if any. You can read more about it here.
Tuesday, December 8, 2009
xPL Tweeting
I'm not sure why this hasn't been done earlier, but it looks like I'm the first to integrate xPL and Twitter. It was really easy to do and only took a few hours. A lot of the time was just figuring out what API to use and investigating OAUTH. I ended up using twitterizer's API, which doesn't support OAUTH. That's fine because I want this app to run standalone without any user interaction required for login, which OAUTH requires. The downside is the tweet source will show Twitterizer and not xPLTweet. Twitter no longer takes registrations for apps that do not use OAUTH, so there's no free publicity for my app in your Twitter streams. Bummer.
xPLTweet grabs OSD.BASIC messages explicitly targeting it (ie doghouse-xpltweet.yourinstance). It grabs the text portion of the message and tweets that. That's pretty much all it does. A future enhancement I may do will be to monitor who you're following and issue OSD.BASIC messages when they update their streams, but it could be messy if you follow many active Twitterers.
In any case, you can grap xPLTweet here.
xPLTweet grabs OSD.BASIC messages explicitly targeting it (ie doghouse-xpltweet.yourinstance). It grabs the text portion of the message and tweets that. That's pretty much all it does. A future enhancement I may do will be to monitor who you're following and issue OSD.BASIC messages when they update their streams, but it could be messy if you follow many active Twitterers.
In any case, you can grap xPLTweet here.
Thursday, December 3, 2009
Debugging ECM-1240 Setup
I've made some good progress on my ECM-1240 interface. It's a good thing I'm running it on xPLserial, where I can easily make changes to the script instead of having to recompile if it were an application. I found some problems in my script that caused it to miss a byte here or there and seems to be the source of the instability I was seeing. The current script has been running for 5.5 hours (since a power outage ended this morning) without having to reset the counters.
My script is no longer sending the readings over xPL, instead it's doing direct writes to MySQL. It was a pain trying to get ODBC working with XP Embedded, but eventually I did find an ODBC add on for HP thin clients. It doesn't say it supports the T5700, but it works anyway. Now, I'm updating power usage everytime it changes instead of whenever the xPL message was received.
As for this morning's blackout, it was quite a racket. I was awaken around 4AM to a symphony of beeping UPS's - 9 of them to be exact. I really need to open up a few of them and cut the buzzer wires. Some are really way too loud. I also discovered a couple with dead batteries. Good thing I got a couple more UPS's on Black Friday. It's actually cheaper to replace the low end ones instead of buying new batteries.
My script is no longer sending the readings over xPL, instead it's doing direct writes to MySQL. It was a pain trying to get ODBC working with XP Embedded, but eventually I did find an ODBC add on for HP thin clients. It doesn't say it supports the T5700, but it works anyway. Now, I'm updating power usage everytime it changes instead of whenever the xPL message was received.
As for this morning's blackout, it was quite a racket. I was awaken around 4AM to a symphony of beeping UPS's - 9 of them to be exact. I really need to open up a few of them and cut the buzzer wires. Some are really way too loud. I also discovered a couple with dead batteries. Good thing I got a couple more UPS's on Black Friday. It's actually cheaper to replace the low end ones instead of buying new batteries.
Tuesday, December 1, 2009
Random Progress
I was having some problems talking to the ECM-1240 through a virtual serial port and Lantronix MSS-100. It would occasionally lose its connection. I ended up deploying my leftover HP T5700 thin client, connecting it directly to the ECM-1240. I've got xPLSerial running on the thin client and it issues xPL messages every 60 seconds with the current power consumption. I'm still getting some weird problems with the ECM-1240 where the counters get out of whack on an Aux channel and exceed the usage on the main channel. This causes me to have to reset the counters and lose the cumulative statistics. I need to figure out how to work around this issue so I can get some valid full-day consumption readings.
I've also moved some xPL and xAP applications off my other 2 servers onto the thin client since it's not really doing a whole lot. It's chugging along at around 10% CPU utilization with about 5 apps running. I tried to run xPLSys on it, but it's crashing. There doesn't appear to WMI in the XPe build on the thin client. I may have to figure out a different method of getting the statistics.
Ironically, I've also been working on my automation interface GUI in expectation of buying some touchscreens. However, as the world found out yesterday, the Crunchpad died before birth. I was planning on buying several of those for touchpanels around the house. Hopefully, there will be some ChromeOS or Android tablets in the near future.
I've also moved some xPL and xAP applications off my other 2 servers onto the thin client since it's not really doing a whole lot. It's chugging along at around 10% CPU utilization with about 5 apps running. I tried to run xPLSys on it, but it's crashing. There doesn't appear to WMI in the XPe build on the thin client. I may have to figure out a different method of getting the statistics.
Ironically, I've also been working on my automation interface GUI in expectation of buying some touchscreens. However, as the world found out yesterday, the Crunchpad died before birth. I was planning on buying several of those for touchpanels around the house. Hopefully, there will be some ChromeOS or Android tablets in the near future.
Tuesday, November 24, 2009
First Power Graph
I got around to putting the data into RRDTool. I just updated the post with some better looking graphs. I used this guide for creating stacked, outlined area graphs.




Sunday, November 22, 2009
Back to Juggling Multiple Projects
Earlier this week, I started work on a new xPL app, currently called xPLSys. It monitors disk space, memory and cpu utilization and sends xPL messages containing the data. I'm not exactly sure how I want to package those messages as there really isn't a schema to hold the info I want to send - so either I make up my own schema or send multiple messages - one for each stat being watched. It's been running for a few days now but has been pushed aside for something else.

My Brultech ECM-1240 power monitor arrived Friday, and I started installing it that evening. I finished up most of the wiring Saturday morning and have been deciphering the serial protocol for real-time updates. I've been using our xPLSerial app to interface to it and code up the interactions with the built in scripting engine. I have to say, it's a very cool app and you should download it and donate ;). Despite being distracted by CAL's upset of Stanford (HOORAY), I figured out the serial protocol last night and have now been fine tuning my script. I've been thinking about rolling this into an app, but there is virtually no cpu utilization with the script running in xPLSerial.

I did make a change to xPLSerial to assist with debugging and that change will get pushed out eventually. I'm also considering removing the xPL from the name and calling it something else. It's really a serial port scripting engine with built in xPL functionality, but doesn't require xPL. In the meantime, I need to figure out what I'm going to do with the power data I'm getting every second.

My Brultech ECM-1240 power monitor arrived Friday, and I started installing it that evening. I finished up most of the wiring Saturday morning and have been deciphering the serial protocol for real-time updates. I've been using our xPLSerial app to interface to it and code up the interactions with the built in scripting engine. I have to say, it's a very cool app and you should download it and donate ;). Despite being distracted by CAL's upset of Stanford (HOORAY), I figured out the serial protocol last night and have now been fine tuning my script. I've been thinking about rolling this into an app, but there is virtually no cpu utilization with the script running in xPLSerial.

I did make a change to xPLSerial to assist with debugging and that change will get pushed out eventually. I'm also considering removing the xPL from the name and calling it something else. It's really a serial port scripting engine with built in xPL functionality, but doesn't require xPL. In the meantime, I need to figure out what I'm going to do with the power data I'm getting every second.
Saturday, November 14, 2009
Solar Contract Signed & ECM-1240 Ordered
We signed the contract a couple days ago with Real Goods Solar (Regrid Power) for a 3.68kW system. Projected install date is late February and power on in March. Might as well have it come online when there's more sunlight.
I also ordered the ECM-1240 power monitor from Brultech. I decided to put current transformers on the lines from the solar array, but I will have to extend those via Cat-5. They should be able to go 100 feet, but it looks like it will be very, very close to 100 feet or possibly more. Hopefully, it will work. I've already opened up a hole in the wall next to the sub-panel, installed a mudring and drilled through the stud next to the subpanel so I can pass CT wires from the subpanel to the mudring. I also ran a couple Cat-5 wires through the wall behind the subpanel to a closet in the adjacent bedroom. I'll need those to connect to the Cat-5 drops in that room to extend the solar array's CTs and possibly get the ECM-1240 on the network via a Lantronix MSS-100. With luck, it'll get here before the Thanksgiving break so I'll have time to work on it.
I also ordered the ECM-1240 power monitor from Brultech. I decided to put current transformers on the lines from the solar array, but I will have to extend those via Cat-5. They should be able to go 100 feet, but it looks like it will be very, very close to 100 feet or possibly more. Hopefully, it will work. I've already opened up a hole in the wall next to the sub-panel, installed a mudring and drilled through the stud next to the subpanel so I can pass CT wires from the subpanel to the mudring. I also ran a couple Cat-5 wires through the wall behind the subpanel to a closet in the adjacent bedroom. I'll need those to connect to the Cat-5 drops in that room to extend the solar array's CTs and possibly get the ECM-1240 on the network via a Lantronix MSS-100. With luck, it'll get here before the Thanksgiving break so I'll have time to work on it.
Tuesday, November 10, 2009
Power Monitoring
As we get ready for the solar panel installation, I've been looking into power monitoring systems. I'm going with the Brultech ECM-1240. This is their 2nd generation energy monitor and has been very popular with the Cocoontech crowd so it has been well tested in the real world. Brultech Support has been very helpful responding to my emails with timely replies. I am looking at purchasing Package A, which comes with the monitor, 2 200A split core current transformers (CTs) and 5 MicroCTs. I'll also need 8 more MicroCTs and possibly a couple of the 80 amp MicroCTs (for our AC unit).
We have a main panel with the electric meter that services the AC unit and a sub-panel inside our house. Everything else is fed from the sub-panel, so that's where the ECM-1240 will be. It will be easier because I can shut off the main breaker to the sub-panel, whereas the main panel has no shut off. The less I muck around in there, the better. I will have to connect the CTs from the AC breakers to the ECM-1240 upstairs by the sub-panel. The CTs can be routed over Cat-5, I just need to figure out how to get the CT wires out from the main panel and into my garage, but that can wait until the solar guys do the install. Maybe their electrician can help me out.
As for the solar install, we've finally decided on an array size, an inverter & an installer, but I'm waiting for the data access to be finalized before signing the contract. I've chosen not to use the ECM-1240 to monitor the solar array as I am working with the solar installer on getting access to the inverter via an RS232 add on board. They've been very responsive so far and hopefully this item will be resolved soon.
We have a main panel with the electric meter that services the AC unit and a sub-panel inside our house. Everything else is fed from the sub-panel, so that's where the ECM-1240 will be. It will be easier because I can shut off the main breaker to the sub-panel, whereas the main panel has no shut off. The less I muck around in there, the better. I will have to connect the CTs from the AC breakers to the ECM-1240 upstairs by the sub-panel. The CTs can be routed over Cat-5, I just need to figure out how to get the CT wires out from the main panel and into my garage, but that can wait until the solar guys do the install. Maybe their electrician can help me out.
As for the solar install, we've finally decided on an array size, an inverter & an installer, but I'm waiting for the data access to be finalized before signing the contract. I've chosen not to use the ECM-1240 to monitor the solar array as I am working with the solar installer on getting access to the inverter via an RS232 add on board. They've been very responsive so far and hopefully this item will be resolved soon.
Subscribe to:
Posts (Atom)