Networked power outlet

Computers & Mobile Energy & Sustainability
Networked power outlet

Picture from Landon Cox, 360VL, Inc.

Landon has a great site with loads of evidence from his hardware and software explorations.

Looking for a way to fly your Green Geek flag a bit? Check out the network controlled AC outlet:

The impetus for this came when I was at work at a client…their offices are about 70 miles from where I live. I have 3 servers at home which are housed in the crawl space under my office where they are out of the way, don’t pollute my workspace with fan noise, and don’t put out heat I have to live with. One of the servers wasn’t responding even though I had network access to the rest. It was just dead and I needed to bounce it with a hard reboot but I couldn’t given my geographical circumstances.

Using a $69 Linux embedded board (an Atmel NGW100), an AVR microcontroller relay board, open source development tools (WinAVR), and some home-brewed software and electrical elbow grease, I now have a system I can use to hard boot a server remotely.

Check out the rest of the site as well: Landon’s stuff is eye opening. I found his site to be well designed, with lots of information on projects, past and present.

Particularly useful is the approach he takes to posting on his site:

When I’m working on projects, sometimes I build or create things to see if I understand the problems or issues. For that reason, a lot of it is temporary, has no particular purpose, but might be amusing or educational. That’s what this site is all about.

This site’s content includes topics on hardware, sensors, microcontrollers, software, firmware, techniques I’ve used or discovered. It’s really a stash for things I’m learning and want to share or just keep around for reference.

This is kind of like having an open notebook so that the world can see your projects, maybe long after you have moved on to the next shiny thought. By providing ourselves with a place to park our ideas while they are hot, we don’t have to try and remember them later when other people get around to joining our interests.

I asked him for an update on the remote controlled power outlet project:

The project is still in use though because the servers don’t belly up that much, it doesn’t get exercised too much. If it was on a household device, that would be a different story. :-)

If I was going to do it again how would I do it differently? One thing is I would make the control between the NGW100 base station and the relay board a wireless link….not 802.11, but XBee. That way the NGW100 could be located more easily with my hubs and other internal wired network devices, but my servers, which are not in the same area, can still be controlled.

Would be nice to have a small web app running in the NGW100 to serve outlet status.

So, a little bit of hardware change. More software features.

Your work does not have to be complete to show it off. The process and the individual steps are valuable in themselves. Somebody else may be inspired to take your idea in a new direction, or maybe you will want to come back to it months or even years later. If you are willing to show off your documentation process, please share it with us in the comments.

20 thoughts on “Networked power outlet

  1. Rick DeNatale says:

    I sent an email to the author of the linked article about this.

    This is a cool article, and seems useful but. There seems to be at least one electrical code violation, and possibly more.

    The article connects the outlet to the relay controller using the neutral wire. The code requires that the neutral line be left unswitched, the hot wire should be used instead.

    I learned this lesson when I was in college studying E.E.C.S. and my mom asked me to fix a light in her bathroom, since after all I was studying “Electrical Engineering.” Not knowing electrician practices, I assumed that the black wire was ‘ground’ and switched the white lead. When an electrician did some work later he discovered the mistake, and I got a lesson in the code.

    There seem to be some extra devices in the outlet box, I’m not sure whether an electrical inspector would be happy with these, and the article doesn’t describe them, one seems obvious, a terminal strip presumably used to connect the line cord for the relay loop, but there’s also a mysterious black box labeled 107.

    Also, Romex rather than zip or line cord should be used between the outlet and the relay box.

    There’s no mention of whether or not the relay controller was put in an enclosure, there are code rules about enclosures containing mixed high and low voltage wiring.

  2. Cory says:

    Excellent observations by Rick DeNatale. This is one of the important things to do when Making with household electricity – read the code and make sure you understand why the parts are there. The NFPA code has evolved over a hundred years of experience and knows what it is talking about. Getting your own copy of the code is probably expensive, but local libraries usually carry copies for you to peruse along with local additions/changes.

  3. Anonymous says:

    Why the HELL aren’t there dozens of commercially available versions of this? There’s no reason something like this couldn’t be produced, to electrical code, and sold for under $50 each. I’d use a few dozen in my house because I’m a geek, but we have immediate demand for another few dozen in our computer equipment lab at work.

    1. Aud1073cH says:

      the X-10 controllers are available, and could be controlled via the net with just a little software.

      1. Aud1073cH says:

        may be bad form to reply to my own comment, but had some more thoughts-

        Some people have had success in controlling wireless X-10 devices with arduino.

    2. Anonymous says:

      There are dozens of commercially available versions of this. We have had them in the datacenter for years.

      A brand new basic SOHO network controlled power strip with 4 outlets can found on Ebay for $70.

  4. Aud1073cH says:

    You could probably do something very similar with an Arduino.
    With an ethernet shield for communication, and either a relay or optocoupler you could control the reset or power button of the server remotely – short pulse to reset or 4 sec. to power. It could be powered by the +5V standby (always on) from the power supply. with some extra wire, one Arduino could control 14 servers. (one for each output pin) or more with multiplexing.

  5. Ivan says:

    but now you have to add a second relay to bounce the first when it hangs ;)

  6. craig says:

    Yes, obeying the rule that the hot gets switched is a good idea, even if just from the standpoint that you know what is what when doing service on it later. I’ve seen plenty of jerry-rigs where a circuit that is shut off is still hot… not a good idea. Ignore Rick about low & high voltage being in the same enclosure… this is your portable plug-in device, EVERY portable plug in device has high and low voltage wires inside. Inspectors dont inspect your personal electronic portable projects.
    Also, do my eyes deceive me or is there no strain relief protecting the relay wire from the sharp metal of the box’s knock out hole?

  7. follower says:

    First up, a common way to make controlling mains-powered devices “safe” that I’ve seen is to use something like an RF remote controlled socket and modify the remote.

    Secondly, I also would encourage people to start an online “lab notebook” or similar site. I set one up a couple of years ago using an one-file Python wiki solution here:

    In addition to generic “throw some stuff somewhere pages” I have pages devoted to:

    * notes on work-arounds for software issues. e.g.

    * collections of useful links. e.g

    * sample and junk-box component lists

    * software usage notes. e.g.

    These pages are really helpful when posting in forums and the like. Do the research and write up the process once then refer people to it multiple times.

    Over time, I seem to have also settled into a standard project page naming approach depending on the project stage:

    * Initial research gets a “Learning About” page (currently about 30 pages). e.g.

    * Actual project development gets a “Project Log” page. e.g.

    * Complete step by step project write-ups get a “How To” page. e.g. Whoops, don’t appear to have any of those. :-)

    It has proven to work out really well both for me and other people (given the occasional appreciative email I’ve received). I get project documentation which makes it easier to switch between and restart projects. The world gets notes and code that would otherwise most likely just sit on my hard-drive. e.g. I’ve had a number of people successfully build my Arduino USB shield just from the pictures and notes in my project log.

    Start your online project log today!


    [My original anonymous comment didn’t appear after a few days so I’ve reposted after creating an account.]

Comments are closed.

Discuss this article with the rest of the community on our Discord server!

Making things is the best way to learn about our world.

View more articles by Chris Connors