Friday, July 10, 2009

XBee modems with an Arduino microcontroller

I'm very impressed with these little XBee radio modems. It is about the size of a couple postage stamps and requires very little power to operate, making them perfect for remote sensing applications. The big deal is that they allow you to communicate serial over wireless without any bullshit. Once you have them hooked up with some voltage you can send data through one device acting as a transmitter and receive it on another. There was very little configuration required and the whole experience was very much out of the box, making it a great component to add to my DIY arsenal.

With an arduino board (a microcomputer that can be powered by a 9V battery) you write for loops that send data out of its serial pins (among other things). This data can come from sensors such as temperature, motion, whatever. With the XBee that serial communication can then be extended wirelessly to any computer in range (there are various xbee's that can communicate up to 6 miles line of sight!). To test it out I soldered up a couple XBee adapter kits from Adafruit Industries and attached a USB TTL-232R cable to one acting as the receiver. In a terminal window you can simply use the screen command to monitor your XBee receiver listed in /dev (on the mac or linux). Later, I will be writing a daemon in python that will give me some neat alerting and other options for the remote sensors I'll be setting up around my house. The XBee's don't appear to suffer from any weird hand shaking issues, syncing, or anything like that from my tests. They just worked and I couldn't believe it when my simple arduino sketch program starting communicating and displaying on my computer monitor.


Labels: , , ,

0 Comments:

Post a Comment

<< Home