CurrentCost-Ruby
A gem to provide a Ruby interface to the CurrentCost energy meter (www.currentcost.com)
Licensed under the MIT license (See COPYING file for details)
Author: James Smith ([email protected] / www.floppy.org.uk)
Homepage: github.com/Floppy/currentcost-ruby
INSTALLATION
1) Enable gems from github, if you haven’t already done so (rubygems >= 1.2):
> sudo gem sources -a http://gems.github.com
2) Install gem
> sudo gem install Floppy-currentcost
REQUIREMENTS
Floppy-rb232 >= 0.2.3
USAGE
You can read data from the meter by creating an instance of the CurrentCost::Meter class, and registering an observer which will receive readings. See examples/simple.rb or the CurrentCost::Meter documentation for a simple example of how to do this.
TRAY MONITOR
This gem includes the ‘currentcost_tray_monitor.rb’ application. This is a program which will sit in your system tray and display a coloured icon based on your power usage. To use the program, run:
currentcost_tray_monitor.rb -p your_serial_port_name
The program requires the Gtk2 libraries for Ruby (available from ruby-gnome2.sourceforge.jp/).
For more details, see github.com/Floppy/currentcost-ruby/wikis/currentcosttraymonitor