Tuesday, November 29, 2011

WattDepot Command Line Tool

It has been awhile since we started our discussion on being "Green" and the need to monitor and analyze our own energy usage.  We have been busy learning to use the WattDepot energy data collection system.  And we have began rolling out our own command line tool using that system: the Hale Aloha dorm energy data command line tool.


This is a pretty neat tool, allowing the user to gain access to the energy data without the need to learn to program!  Our goal was to make the tool modular and extendable.  We defined a Command interface for which all current and future command additions could implement.  With this standard interface, any new commands can be added to the system without changing any other parts of the system, such as the command Processor and Manager.  This is made possible by the on-the-fly, run-time discovery approach used by the command Manager to discover new commands implementing the Command interface.  You can try it out: add a new command and see it appear as a new option in the program!

We have learned quite a few new development techniques since last.  We learn to use the "Issues" tab on Google project to drive our design effort.  The term they use for this approach is "Issue Driven Project Management".  There were two other members in our TNT group: Ted and Josh.  We work really well together as a team thanks to this approach!

Another cool addition we picked up along the way was Jenkins!  No, Jenkins was not our butler!  But he sure kept us honest.  Whenever one of us submit a code that's poorly tested, Jenkins would know and point it out right away!  You will get a big red dot in your build history, and reminded in your mail box that you screwed up!  No, Jenkins was not mean.  Rather, he gave each of us a chance at redemption before the rest of the team finds out!  The best thing a team could expect from Jenkins is his weather report: sunny if the last 5 consecutive builds has no error, cloudy and stormy otherwise.

I have had a very positive experience with this project development techniques that I am adapting it for my other projects.  However, since my other project cannot be open-sourced yet, I had to look for replacement tools.  I found trac for issue tracking, and bitten for Jenkins' continuous integration.


Tuesday, November 1, 2011

The First Step toward being "Green"

The first step in finding a sensible solution to any problem is understanding.  This is applicable to all problems, scientific or otherwise.  Today, we'll examine the "Green" initiative that has gain large momentum recently.  So, what is being "Green"?  To me, "Green" means being sensible to the impact that we make as a species to the environment, and the legacy that we want to leave to our future generation.  What are our legacies?  Well, to simply put, it's things that we take for granted now, but would be miserable without: clean water, air, energy, and sun light.

It's humorous to think in these simple terms, rather than in terms of other things that currently have more green ($$$) value assigned to it.  However, let's face the simple truth: inflation and economic changes will change the currency value of things to come, but it will never change our needs for these basics: clean water, air, energy, and sun light.

Today, the focus is on energy.  Being "Green" on energy means we need to realize that our supply of fossil fuel is NOT unlimited.  Indeed, the conflicts of the modern era can be tied to the disputes around access to these limited supplies.  Yet, our sole consumption of this depleting resource is not regulated, but rather, increasing at an alarming rate.  Indeed, one measure of a developing nation's "progress" is its increase in fossil fuel consumption!  How, then, do we act as a species to be sensible?

Our first step: study and understand our energy consumption behavior, and apply that understanding to reduce our consumption in a sensible manner.  To do that, we need monitoring and measurement solutions.  Being able to monitor our energy usage and understand the role each pieces of that consumption means to our lives will give us insight into our energy "efficiency".  That is, are we using energy to achieve the optimal Goods?  Or are we wasting it unknowingly in some areas just because it is still "cheap" to do so?  Is it really "cheap" to borrow from our grand children's "energy fund"?  Looking at the U.S. National Debt Clock, I am hard pressed to hope otherwise.

Hawaii's isolation makes us very dependent on imports.  It is interesting to note that we import approximately $6 billions worth of energy per year.  Just imagine, how much can we achieve if we were to invest that amount of money toward developing our energy independence?  Short term savings?  Long term savings?  To our future, that investment would be a truer path to making our island home a paradise than any.