tags:

views:

281

answers:

5

Duplicate

What's the most practical way to toggle several power items with a PC?

I'm automating the build system for my company's development team and wanted to have a stoplight in our office window represent the outcome of the nightly build.

Does anyone know of a device I can buy that has an API I can code against to turn power on / off?

I see that Lego bricks have an API but I'm looking for other ideas.

+2  A: 

There is something at Coding4Fun that might help.

http://blogs.msdn.com/coding4fun/archive/2006/10/31/916478.aspx http://blogs.msdn.com/coding4fun/archive/2006/12/20/1337418.aspx

Maybe those might help.

percent20
A: 

The CruiseControl.Net CCTray application have built in support for X10 with which you can control electric appliances.

Peter Lillevold
+1  A: 

You need an IO board with a relais protection (so that you can switch 230/110V)

There are many out there. I've used the Velleman board (available in Europe), which works with Windows XP/2003. It has examples of how to do P/Invoke from C#.

Try in google "DIGITAL OUTPUT BOARD with relais"

taoufik
A: 

There are some power strips, such as the following: http://dataprobe.com/remote-control-power-strip.html

which can be controlled via RS232 commands. So you would open a Serial Port, set the port to 9600-8-N-1, and send a few commands. If you're not familiar with serial communication, it might go something like this:

  SerialPort port = new SerialPort("COM1", 9600, 8, NoParity, OneStopBit);

  port.Write("set outlet 1 off\r\n");

  port.Write("set outlet 1 on\r\n");
MedicineMan
A: 

You might consider the Babysitting policy used at FogCreek where the dev that breaks the build has to babysit it until another dev breaks it. It's used as both a deterrent and and educational system.

Read more on his site.

http://www.joelonsoftware.com/news/fog0000000141.html

Paul Alexander