Here is a video of two Xbee radios working as a doorbell. There is a button attached to one Xbee/Arduino set-up and a speaker attached to the other. When the button is pushed, it sends a serial communication through the Xbee radio to which it is connected to the other Xbee radio. The receiving radio then tells the speaker to buzz. Now that we have a basic doorbell working, we (Nick and I) are going to scale up and make a more advanced doorbell. Stay tuned…
Here are the details of how to set up a basic doorbell with two series 2 Xbee radios:
1. Follow the steps for getting two Xbee radios to chat.
2. Set up the first board with the push button and the second with the speaker. The steps to setting up the Xbee radios for both are the same.
3. Setting up the Xbee radios: Connect TX/RX on the Arduino to D-In and D-Out on the Xbee radio. Connect Power (3.3V for the Xbees, nothing higher!) and Ground.
4. Board 1 (Button): Using a push button (like the yellow one in the video), connect power from the button to power on the breadboard. Connect the button’s ground to a pull down 10K resistor (resistor should go to ground) and then a wire going from the resistor to digital pin 4 (you can pick any digital pin).
Upload this code to the button board. Remember to disconnect TX/RX before uploading otherwise it won’t work!
5. Board 2: Connect the speaker’s ground to ground and the power to digital pin 5.
Buzzer board code Remember to disconnect TX/RX before uploading otherwise it won’t work!
Ta dah! Or should we say, ding dong?