Skip to content
This repository has been archived by the owner on May 17, 2021. It is now read-only.

DIY on XBee binding

juri8 edited this page Dec 29, 2016 · 3 revisions

since 1.9

#Introduction This binding is to interact with self built (DIY) hardware that all communicate via XBee modules.

#Hardware setup The XBee connected to openhab has to be configured to run in API mode for this plugin to work.

Binding configuration

Example to add in openhab.cfg:

     diyonxbee:serialPort=/dev/serial/by-id/usb-FTDI_FT232R_USB_UART_A702NX9M-if00-port0                                                                                
     diyonxbee:baudRate=9600                                                                                                                                            

Item configuration

 Number  Living_Temperature      "Temperatur [%.1f °C]"          <temperature>   (GF_Living)     { diyonxbee="<0013A20040B40F18:Temperature" }
 Switch  Living_Motion           "Bewegung [MAP(de.map):%s]"     <present>       (GF_Living,GPresence)   { diyonxbee="<0013A20040B40F18:MOTION" }
 Color  Living_Stripe      "Living RGB Stripe"          <lights>   (GF_Living)     { diyonxbee="<0013A20040B40F18:Stripe" }

(regard the > and < arrows that define in and out).

Protocol

The Protocol is text based to allow simple development/debugging the Arduino code even without using the XBee (any serial console will do). For the pure sensors, the Arduino has to send lines conaining key=value, e.g from the example item configuration above, a valid message would be:

Temperature=21.3
MOTION=ON

For the actors, the Arduino has to send the received command back to the sender, this ensures that the openhab item state is only updated when the command was correctly understood. Currently, RGB led stripes (openhab type Color), switches and Dimmers are supported.

Sample Arduino Sketch

Find a Arduino library with example here

Installation


User Interfaces


Community

(link to openHAB forum)

Development



Misc


Samples

A good source of inspiration and tips from users gathered over the years. Be aware that things may have changed since they were written and some examples might not work correctly.

Please update the wiki if you do come across any out of date information.

Use case examples

Collections of Rules on a single page

Single Rules

Scripts


Release Notes

Clone this wiki locally