Many times you need to remotely control a relay, electrovalve or some other electronic or electromechanical device, and many times wirelessly. With XBee modules things become very easy. Very versatile and having small dimensions it is easy to add it to your projects.

In this demonstration the modules are set to wirelessly control two types of relays, standard and latched. To achieve this you will need to configure the analog inputs of the Xbee to digital I/O. In the given schematics the standard relay is driven by a general purpose NPN transistor T1. Some relays already have the protection diode incorporated, if not you will need to use D1 as shown.

The latch relay is driven by a hex inverter IC connected as a buffer. Each inverter changes the logic level from high to low and from low to high so you must cascade two inverters to preserve the logic level. This type of relay is activated by pulses so it needs a small amount of current. Even so the output capability of a single inverter might not be enough so the remaining inverters are connected in parallel.

On the transmitter side you have two push buttons connected between ground and the digital I/O ports of the XBee. There is no need for pull-up resistors because this is done internally in the Xbee.

This demonstration has lots of practical applications. You can connect almost anything to those relays or use the digital output of the module with a buffer to control other devices or transmit information.

Wireless Relay Control with XBee: [Link][Via]