Fork me on GitHub

Hacklet Build Status

A library, written in Ruby, for controlling the Modlet outlet.

If you haven't heard of the Modlet before, it's an outlet cover which allows you to convert any standard US outlet into a smart outlet. This means that you can control whether each socket is on or off as well as determine how much energy it's using with a sampling frequency of 10 seconds.

If you're interested in controlling your Modlets remotely, you can use them with IFTTT using hacklet-remote. Once setup you can control your applicances via SMS, email or even Google Calendar. It works just like the WeMo switch except you maintain control (and don't have to worry if WeMo's servers shutdown).

Getting Started

You'll need:

Once you've got those materials you should be set. For a full walkthrough, watch the demo video. For the impatient read below.

# On Ubuntu/Debian based Linux
sudo apt-get install libftdi1
echo 'ATTRS{idVendor}=="0403", ATTRS{idProduct}=="8c81", SUBSYSTEMS=="usb", ACTION=="add", MODE="0660", GROUP="plugdev"' | sudo tee /lib/udev/rules.d/99-thinkeco.rules

# On OSX
brew install libftdi0

# For Windows see

# Now it's time to install hacklet
gem install hacklet

# Insert the dongle into the computer

# Add the device to the network, keep a copy of the network ids (ie 0xDEED)
hacklet commission

# Plug your modlet into the wall

# Turn the top socket off
hacklet off -n 0xDEED -s 0

# And back on again
hacklet on -n 0xDEED -s 0

# Get the samples from the top socket on the device registered as 0xDEED
hacklet read -n 0xDEED -s 0


So why write another client?

I really liked the idea of the WeMo outlet, but I felt like it should really have included two sockets. I also disliked the fact that you need to use their servers to control it. Then I found the Modlet.

Unfortunately the client software included with the Modlet isn't available on all platforms (Linux) and it's pretty heavyweight for what it does.

The goal of this project is provide all the same functionality of the bundled client but do it in a lightweight manner. In short, create a client that gives total control and availability of the data. Join us in our quest.

A hack by Matt Colyer