This Tech Tip is brought to you by Digi Applications Engineer Brenton Mock from the Lindon, UT team.
Be sure to answer the XBee Puzzler at the end of this entry for a chance to win an XBee t-shirt hot off the presses!
There have been an increasing number of requests for Tech Tips and How-to articles regarding the XBee Wi-Fi and the XBee Wi-Fi Cloud Kit.
Due to the protocol-bridging nature of the XBee Wi-Fi, many communication project infrastructures are simplified. One such project is controlling an AC circuit remotely using web applications. This makes control from any web-connected device possible.
This Tech Tip relies heavily on the Getting Started Guide for the XBee Wi-Fi Cloud Kit. Please ensure that you are familiar with the procedures contained within that guide.
In this tutorial we will be using the XBee Wi-Fi Cloud Kit to toggle a digital output line on the XBee which will control an AC relay. We will be using the Heroku website service to accomplish this in conjunction with Device Cloud by Etherios.
Since dealing with high voltage electricity can be dangerous, we’re going to stick to using the PowerSwitch Tail, a product that packages the relay circuitry in a nice little box that we can plug into the wall. Any device that we plug into the other end will be at our command. This guide will get you started using the PowerSwitch Tail with the XBee Wi-Fi Cloud Kit.
1 – XBee Wi-Fi Cloud Kit (XBee Wi-Fi, Cloud Kit Development Board, micro-USB cable for power)
1 – XBee Wi-Fi Cloud Kit account (To create an account, please follow these setup instructions)
1 – PowerSwitch Tail II (This product can be found here)
2 – Solid Core, 22 AWG or 24 AWG, insulated wires
1 – AC-powered device (in this case, a fan)
During the XBee Wi-Fi Cloud Kit setup, you will be asked if you would like to configure the XBee Wi-Fi for the Cloud Kit. Please do so. This will configure all the DIO lines for use with the HerokuApps that are used by the kit.
Once your XBee Wi-Fi is added and configured to your account, you will see a screen as shown below:
We will be using DIO 9 (pin 13) for our example. This will correlate with the User LED toggle:
The DIO line (pin 13 on the XBee) connects to pin 1 of the PowerSwitch Tail.
Ground (pin 10 on the XBee) connects to pin 2 of the PowerSwitch Tail.
Connect the PowerSwitch Tail to an AC power source.
Connect an AC device to the PowerSwitch Tail. In this case we are using a fan.
Now you should be able to click on the User LED toggle. This will then send a web services instruction to the radio via Device Cloud by Etherios (which interfaces with the HerokuApp on the backend) that will toggle the DIO9 (pin 13) to a high state. This in turn toggles the PowerSwitch Tail to complete the AC circuit.
The fan is now on:
But seeing as this isn’t a User LED that we are toggling, we must re-label the widget to accurately reflect the device that will be used. This can be done by clicking on the Widget Settings icon that will appear when you hover over the widget:
This will take you to the following screen:
You can change the label from “User LED” to something more appropriate such as “Most Awesome Fan of the Heavens.” (I love this fan.)
The XBee Wi-Fi Cloud Kit demonstrates an easy way to web-enable your devices. Device Cloud by Etherios and the Heroku web apps service together simplify the process of remotely controlling AC devices anywhere in the world.
Ready to get started with an XBee Wi-Fi Cloud Kit? Head over here.
You are working on a project with an XBee Zigbee Coordinator radio installed high up in a tower. You have an XBee Zigbee Router radio connected to your PC and want to test the link between the coordinator and router.
Digi Zigbee radios support a loopback cluster to enable link testing to a remote radio without the need for a physical loopback adapter. You decide to use the loopback cluster in API mode to test the link success rate of many transmissions.
You have the following information:
Coordinator 64 bit address: 0013A200 40506070
Router 64 Address: 0013A200 12345678
You want to send “Hello World” without the quotation marks as your test payload.
What is the correct API frame to accomplish this?
Submit your answer below. The deadline for entries is March 7, 2014. Winners will be notified by email. Employees of Digi and its subsidiaries are not eligible for the prize drawing. Good luck!
We are no longer taking submissions for this XBee Puzzler. The correct answer is:
7E 00 1F 11 01 00 13 A2 00 40 50 60 70 00 00 E8 E8 00 12 C1 05 00 00 48 65 6C 6C 6F 20 77 6F 72 6C 64 F4