Control systems are critical in many aspects of human life and are used in both large infrastructure and every-day appliances. Examples include factory control for chemical processes, HVAC control in buildings, cruise control in automobiles, spin cycles in washing machines, and even smart cooking in microwaves. However, large scale control of physical environments has largely been done with SCADA systems, which are only practical for large enterprises and often consist of monolithic systems designed for specific functions HVAC or factory automation. The past decade has seen the emergence of wireless sensor networks being deployed to monitor all kinds of environments including buildings, waterpipes, cities, and wilderness areas. These sensor networks offer cheap monitoring capabilities without the need for a large amount of fixed infrastructure. Recent work in some of these areas has augmented the wireless sensor network environment with control, particularly in homes and buildings. This dissertation focuses on combining control systems with wireless sensor networks to enable commodity sensor- actuator networks that can be incrementally deployed in any environment. These sensor-actuator networks can accommodate not just a single sensor-actuation application, but a set of them. An important challenge here is how such a group of sensors and actuators are integrated in a sensor network with commodity hardware and programmed by the end user to achieve embedded control objectives. This dissertation specifically addresses the latter -- the programming -- problem. We show methods and build tools that enable an end user to write sensor-actuator network control applications and address challenges specific to incorporation of actuation in modern sensor networks