Zigbee and arduino communications

Hi everyone.
I have a lot of interest about home automation. I have been searching and find the solution using Zigbee and Arduino.
The main idea is to control the lights of the house, the devices that are connect to the electrical outlets (AC power plugs and sockets).

I was planning to change the switch of my house with this one On/Off dimming Switch (ILS-SE21J-Z) ( http://www.zigbee.org/DesktopModules/ZigbeeCompanyProducts/ProductDetails.aspx?ProductID=273&Ctrl=ViewProducts ).

The electrical outlets with the Safe Plug 2013 (http://www.zigbee.org/DesktopModules/ZigbeeCompanyProducts/ProductDetails.aspx?ProductID=311&Ctrl=ViewProducts)

According to what I have read (Not sure if it is correct)
I need to make my Zigbee network with their ZigBee Coordinator, use the ZigBee Router just in case it is need. (This will depend of my house) and the ZigBee End Device which are the On/Off dimming Switch and the Safe Plug 2013.

My question is.
With the arduino xBee Shield I could control all of this devices? It is going to be necessary to use the ZigBee Coordinator.
My idea is to create an online app for controlling the lights and electrical outlets of my house.

Thanks for your time

US $300 for a safe plug?? Please tell me I read that wrong. I couldn't find the light switch so I can't whine about how much it costs. However, in direct answer to your question: probably not. Although the XBee supports the Zigbee protocol, the HA series devices have additional requirements and it's unlikely you'll be able to directly control anything with an XBee.

But, I would love it if someone out there told me I was wrong, and that we can use an XBee to control these devices.

I suppose you read wrong. I never put the price on the post, and I find them at 5-10 $ in ebay.
Okay so returning to my original question. If I can't control those devices with XBee. What I need to do for controlling the lights of my house and the electrical outlets. Do I have to change them or add something so they can work with XBee?

Thanks for your time.

This is the zigbee safeplug that is listed on the zigbee site as a compliant device

http://www.safeplugse.com/spse-products.htm

And here is the product with its controller from the spse store

http://www.safeplug.com/store_us/index.php?target=products&product_id=38

Each additional plug costs about $70, where did you see one of these for $10? Got a link, I'd love to look into it.

I couldn't find anything about how they control it or an interface to it. Try sending them mail for more information

Forget it.
It was a bit on ebay. FInal Price was 250 $. (It is cheaper than original).

I think the best way for doing my project will be using x10.
Or do you know a way how to control the electric outlets using ZigBee?

No, I've never heard of anyone controlling zigbee home automation with an arduino. It may have been done, but I haven't ran across it yet. I have a number of X10 devices, and I hate all of them. They are very unreliable.

If you search around this forum though, there are several people that have controlled lights and appliances with various techniques using an Arduino and XBee or other radio device.

draythomp:
But, I would love it if someone out there told me I was wrong, and that we can use an XBee to control these devices.

Can't say right or wrong, but if it is doable, the answer lies in understanding application profiles, clusters, etc. The device(s) to be interfaced would likely need to conform to one of the public profiles, or the details of any proprietary profiles would need to be published.

I've just seen this stuff in the XBee product manual, haven't really made a decent effort at understanding it, much less doing something about it.

I have a number of X10 devices, and I hate all of them. They are very unreliable.

True that. They're basically unusable here now. Part of the problem is the proliferation of surge suppressors, at least some of which effectively clean the mains of X10 signals. I once had some devices that mysteriously stopped working and found that when I unplugged a surge protector that I had installed with a new TV, they worked again. Solid-state (high-frequency) fluorescent ballasts also raise hell with them. BTW, the TV won. Conclusion: X10 is no longer a viable technology in my heavily EMI-laden home.

According to Digi, the XBee people, their ZB series of modules are ZigBee compatible with this caveat: "†Network interoperability with ZigBee devices from other vendors requires that the ZigBee Feature Set or ZigBee PRO Feature Set be deployed on all devices. Contact Digi Support for details."

I just spent a couple of hours prowling through the zigbee specification at zigbee.org. What a royal pain in the bottom it is getting documents and specifications. Net though, they don't specify stuff like:

How to turn the light on
How to turn the light off
How to check if the light is on
How to check if the door is open
etc.

They do specify the interaction of nodes, controllers, routing of messages and such. Basically, it's a network specification, with the specifics that most of us are interested in being left to the manufacturers. That means that digi zigbee devices will operate within their specification, but digi has only certified routers and controllers, since matching a particular manufacturers technique of actual control would mean the manufacturer would have to publish something to tell us how they do it.

I hold exactly zero expectations of a wall switch that will work with several manufacturer's controllers. There's just too much flex given in how to do such a thing. Where we worry about exactly how to send a signal to turn a light on and then check to make sure it is actually on, the zigbee spec. leaves that to the manufacturer to implement any way they want to.

Strangely, that means that my NETWORK is zigbee compliant, but my devices don't match any manufacturers' simply because I use the zigbee protocol in the various modems.

sigh....

PS, someone out there tell me I'm wrong.....please.

DiegoTc:
Forget it.
It was a bit on ebay. FInal Price was 250 $. (It is cheaper than original).

I think the best way for doing my project will be using x10.
Or do you know a way how to control the electric outlets using ZigBee?

If you like soldering, you can use wireless boards and relays (mechanics or solid state) to control you electric appliance. We have done somenthing like this using Chibiduino boards, that has a radio in 2.4 GHz like ZigBee, but running over it a simpler stack.

Regards,
Dario.

draythomp:
I hold exactly zero expectations of a wall switch that will work with several manufacturer's controllers.

In the XBee ZB Product Manual, p35, I find the sections "Application Profiles" and "Clusters" to be encouraging. The way I read it, if a device operates, for example, in the public home automation profile, the On/Off "command" is a standard thing. "Cluster" sure is a funny word, I'm not sure what they're getting at. "On/Off" is a cluster, as is "Color Control" and "Level Control". Maybe cluster is meant to imply a container for commands, actions, etc. Probably not a word I would have chosen. :wink:

Thanks for your answers.

draythomp:
No, I've never heard of anyone controlling zigbee home automation with an arduino. It may have been done, but I haven't ran across it yet. I have a number of X10 devices, and I hate all of them. They are very unreliable.
If you search around this forum though, there are several people that have controlled lights and appliances with various techniques using an Arduino and XBee or other radio device.

Do you have any pictures, videos or something with your x10 devices?

Checking the forum, I found this post Plan: Arduino based home automation system (newbie :) ) - #3 by BroHogan - Home Automation - Arduino Forum

This guys talks about using x10device. Is this the same idea you were talking about.

Also I found this pdf http://www.houstondad.com/arduino/program_your_home.pdf
They recommend to use x10 Device will that be good or it will be a disadvantage?[quote author=Jack Christensen link=topic=136968.msg1029627#msg1029627 date=1355275632]

XBee can be a solution with normal electric outlets?

No, I don't have any videos of my X10 devices. They are just the normal light switches and 'socket rockets' with a couple of appliance modules in various places. I use them to control my outside lights and a couple of appliances that I don't want turning on automatically. The problem is not getting them to work, it's that they become unreliable very quickly. My attic light is attached to a X10 wall switch and it turns on every time the heater turns on. It stays on until I come around to turn it off manually.

X10, in modern homes, just doesn't work very well. The switching supplies in modern computers put too much noise on the line, and as Jack mentioned, power strips suck the signal off the power line. High efficiency magnetic motors will make the power line so noisy that X10 signals won't work as long as the motor is turned on.

I really don't have a good solution that doesn't cost a fortune. I'm not even sure the expensive ones work very well. Insteon (google it) is a power line protocol that also has an RF component and has been seen by some as a good possibility. There's also Z-wave, but I know very little about it.

The compelling feature of X10 is that it is very cheap relative to anything else on the market. Many of the X10 devices are very cheaply made and tend to fall apart when you install them. But.....they are easy to control and work with using any computer.

If they just weren't so darn unreliable. To help this there are many X10 signal boosters devices like this:
http://www.smarthomeusa.com/ShopByManufacturer/ACT/Item/CR134/ But, when you start installing these $200 items, the cheap factor disappears pretty quickly.

So, the unreliability of X10 and the expense of other devices are what causes people to try and make their own. However, your home may not be as big a problem as mine is. You can certainly try a couple of X10 devices and use any one of several techniques to control it with an arduino. You can do some experimenting for a relatively small amount of money to see if it will work for you. Here's a link to add to your list where a guy hooks some existing X10 devices to an arduino and then a web server. http://thenewtech.tv/tech-life/arduinox10-home-automation-over-wifi

I've had the same problem with longevity, the things just seem to degrade over time, usually a few years is about average. I keep thinking about doing something with XBees, not cheap, but I know it would work reliably.

I've started a project using XBees to control lights. A simple on-off (Zigbee Home Automation Protocol, on-off cluster :smiley: ) light switch. My idea is to use a simple, normal light switch and add a 328, a current sensor, a 10A power relay, and an XBee to control a light. There are a heck of a lot of problems with this idea though and I haven't overcome all of them yet.

For example, I can easily turn on a light, but how do I know it is actually on. I plan to use a latching relay so I don't have to supply current to it all the time and once it latches, I don't know what its state is. Especially if the power goes off to my house (happens frequently during the winter). So, I have to be able to sense current to the light and that isn't easy given the range of current various lights use. Those little CFLs pull around a tenth of an amp and a string of Christmas lights can pull several amps. Sensing voltage won't work if you have multiple light switches to turn on a set of lights like hallways and jack and jill bathrooms.

Right this second, I'm waiting for some parts to come in to do some more experimenting with various ideas on how to tell if the light is actually being sent power. I've found various current sensing devices, but don't know how they work yet and I came up with a way to sense AC current through an optocoupler, but the device hasn't arrived. This project will probably take another couple of months to get a prototype running so I can do some extended tests.

I have a thread started where I ask for advice on this project http://arduino.cc/forum/index.php/topic,130243.0.html

But, if I can get it to work, it would be so cool to have a minimal arduino hooked to an XBee that controls a relay the size of an X10 wall switch. I could even sense the current running through the device and report it. Set timers inside the switch and let it run itself.... You can see the possibilities.

Thanks for all of your answers.
I find this website about constructing the wireless sensors. Building Wireless Sensor Networks – Rob Faludi

I think that this will be a great help.

I've been working on a setup that uses a custom board with an ATTiny, RFM12B Transceiver and a relay (Similar to the JeeNode, but with a smaller uC). A nano with another transceiver was connected serially to the web server that bridges serial and RF (eventually I''ll make this standalone so it can communicate with a cloud server). The custom boards cost about $10-15 per including all the components and worked very well. I'm also testing this circuit to detect if a light is on/off (So that a normal light switch can still be used with it). It does dissipate a watt of power while the light is on, but the components are small, cheap and reliable. I'd recommend looking into the HopeRF or Nordic transceivers if you're concerned about cost.

Arrch:
I'm also testing this circuit to detect if a light is on/off (So that a normal light switch can still be used with it). It does dissipate a watt of power while the light is on, but the components are small, cheap and reliable.

Here is a circuit that will do the same thing, and dissipate one heck of a lot less power:

I did a bunch of experimenting with 110V trying to see when voltage was applied. What I came up with is similar to the circuit you show except it uses the impedance of a capacitor. Here's the circuit, you can easily substitute the emitter part of an optoisolator for the led and get rid of the heat.

Of course, the cap has to be able to take the voltage. I was worried about the protective diode, but it works just fine. I have a couple of these as indicators for wall power to some devices, and they've been working great. I sort of went a bit nuts when I found out that they work so well.

The problem with only sensing voltage is things like hallway lights where you have several switches that can turn them on and off. I think I have a solution for that, but I'm waiting for parts to try it out.

Hello everybody.

I have seen that you are looking for a solution to control your lights through ZigBee and Arduino. I can tell you that I developed a solution for it. I designed a board that it lets me to switch on/off since a remote computer one light (or another electrical component connected to the board) and it detect the manual state of the system, so it can change between remote mode and manual mode each time you touch the manual switch. It is really a electronical-remote conmutator.

You can find all the information about it schemes in another thread in this forum: http://arduino.cc/forum/index.php/topic,92963.30.html
It is in Spanish, but I think it is not difficult to understand the schemes.

Now, I have developed a new an industrial/commercial version of this solution. The previous version had one problem. It works fine, but it had a lot of possibilities to make a wrong connection. You can see some pictures about the new version at the end of the previous thread and it will be published too in the my new English thread: http://arduino.cc/forum/index.php/topic,116788.0.htmlhttp://arduino.cc/forum/index.php/topic,116788.0.html[/url]

I am going to open a eshop in a few days where I am going to sell production boards and prototype boards. If you are interested, please tell it to me. You will be able to find them at my web.