Actuators
If you’re not using X-10 modules to control the sprinkler valves, you’re going to want to open and close a relay directly from a microprocessor. The sprinkler valves require AC voltage to drive them, and at voltages that are high compared to what most semiconductors are rated for. Relays typically draw more current than a microprocessor output can take directly, too, so you’ll need a switching transistor to handle the load. Figure 5 shows the generic circuit you need assuming an open collector output on the microprocessor. The diode connected across the relay coil prevents the field collapse across the windings from generating too high a reverse voltage that would destroy the transistor. Be sure to use both a transistor and diode rated for the relay surge currents and applied voltages.

FIGURE 5: Relay control with a microprocessor
X-10 power line controls offer several choices for actuators. The X-10 Universal Module is a less expensive alternative if you’re going to control all circuits simutaneously, as we did, since in that case you’ll only need one relay to interrupt the common return lines.
You can detect and counter failures in the power line transmission to the actuator by paralleling the UM506 with a PF284. A few lines added to the polling script can check if the read-back from the PF284 doesn’t match what the actuator state should be, and simply send the righ command again if the actuator state is wrong.