Low Cost Automation for Roll-off Roof Observatories
My friend asked me to help set up his roll-off roof observatory for automated remote observing. We looked into commercially available automation systems, but at more than $2000, we figured there had to be a cheaper way to accomplish the automation. After a bit of research, we found inexpensive equipment that would do the job with a minimum of fuss.
The Hardware
The original installation was done with a 1/2 hp three phase AC motor and a ABB motor controller. Essentially the motor controller has two inputs: run and direction, that can be controlled in a variety of ways including manual pushbuttons or remote relays. The controller can be programmed to ramp up the motor speed slowly and also to shut the motor down on overcurrent, a handy feature to have in case limit switches fail.
The motor controller has auxiliary control inputs that can override the manual controls. We chose to design a system to control these two inputs (run and direction) via an ethernet link to a LAN already existing at the observatory. In order to control the inputs, we found a dual relay manufactured by ControlbyWeb.com . Their Dual Webrelay not only has two relay outputs: there are also two two inputs that can be set up to monitor the state of the limit switches on the roof.
The same company also manufactures a Webswitch that we used to control a magnetic contactor relay to switch the line to the motor controller and to switch the telescope mount and imaging accessories.

The Schematic
The motor controller power is switched by energizing a magnetic contactor from the webswitch. With the main line power connected, the motor controller is active and awaiting control signals. All control signals are 24 vdc.
Opening the Roof
In order to open the roof, the webrelay controls an auxiliary spdt relay to put 24 vdc on the run and direction inputs. This starts the motor turning in the open direction. As the roof moves, the "roof closed" limit switch toggles, and alerts the webrelay input by putting 24 vdc on that input. When the roof gets all the way open, the "roof open" limit switch toggles, and interrupts the "run" control line to the motor controller, stopping the motor.
Closing the Roof
To close the roof, the webrelay puts 24 vdc on the "run" control, and the "direction" control remains at ground so that the motor turns in the direction to close the roof. When the roof gets to the closed position, the "roof closed" limit swich toggles and interrupts the "run" control line, stopping the motor.
Note that there's another way to close the roof. The Boltwood Cloud Sensor includes an output that will switch to ground when there are clouds or rain. This input controls a relay that will also put a 24 vdc signal on the "run" control. This is a safety feature to ensure that the roof closes even if the software control of the roof via the webrelay fails.

Software Control
Both the Webswitch and Webrelay come with a standalone webserver that can be customized. You can see our version below. Both can also be controlled via any program that can send and recieve xml. We asked a friend of ours to modify the VBasic examples provided by the manufacturer. We now have a "close.exe" and an "open.exe" that can be invoked from the observatory computer's observation automation suite. We use CCDAutopilot at Galaxy Quest to control the entire night's observing program from roof open through imaging and finally to roof close. CCDAutopilot also monitors the Boltwood Cloud Sensor and will invoke our "close.exe" when it's cloudy.
Cost
The total cost of the automation project was about $500 for the webswitch, the webrelay, the auxiliary relays and the magnetic contactor. Of course, the motor controller and motor aren't part of this cost, but they were already part of the Galaxy Quest system. For a quarter of the price of commercially available systems, we've got an automated roll-off roof observatory.
Future improvements
We are working on an ascom driver for the webswitch so that any image automation suite will be able to use our system. We also would like to install a UPS system that will automatically close the roof in the event of a power failure. We are also working on email and phone notifications on roof closure. Stay tuned!