A complete walk through can be found in my Road Test Review on setting up the EnOcean Pi and Sensors:
http://www.element14.com/community/roadTestReviews/1795
With my recent arrival of the EnOcean Pi Road Test Kit I thought a tutorial on setting up the Gateway would be a great article to start with. The Sensor Kit is on backorder so I will fill my time working with just the EnOcean Pi Gateway for now.
This entire process is outlined within the White Paper :
Raspberry Pi talks EnOcean - How to setup a home automation server with EnOcean Pi or USB 300
Source: http://www.enocean.com/fileadmin/redaktion/pdf/white_paper/wp_Raspberry_talks_EnOcean.pdf
Steps to setup the EnOcean Pi
1. Connect the EnOcean Pi board to the Raspberry Pi
Disable Serial Console
sudo nano /boot/cmdline.txt
The file should look like this:
dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait
Remove all references to ttyAMA0 so the contents are:
dwc_otg.lpm_enable=0 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait
Exit and Save the File. CTRL+X
Update Raspbian
sudo apt-get update && sudo apt-get upgrade
Install the required Perl packages:
sudo apt-get install perl libdevice-serialport-perl libio-socket-ssl-perl libwww-perl
Install FHEM (Check to make sure you are getting the latest FHEM Version Home of FHEM.)
wget http://fhem.de/fhem-5.5.deb
sudo dpkg –i fhem-5.5.deb
2. Display FHEM Web Interface
Start your browser and type following to the link field:
http://<Raspberry_Pi_IP>:8083/fhem
You will get the following user interface on the screen:
FHEM recognizes and configures the EnOcean PI. It receives radio telegrams from all EnOcean devices within the neighborhood (10-30m within buildings). Device entities will be created automatically for each new received EnOcean device (every EnOcean radio module or device has a unique manufacturer ID). Switches are by recognized by their specific RPS telegram, sensor types are recognized via learn button with 1BS or 4BS telegram. By default devices with EnOcean radio protocol will be to room EnOcean.
3. FHEM auto configurations
FHEM server is configured via the configuration file fhem.cfg.
Start the configuration file editor via the FHEM menu item “Edit files”.
Gateway:
If USB 300 is plugged and configured to the Rapsberry Pi correctly following code will be generated automatically by the FHEM autocreate function:
define TCM310_0 TCM 310 /dev/ttyUSB0@57600
If EnOcean Pi is plugged and configured to the Rapsberry Pi correctly following code will be generat-ed automatically by the FHEM autocreate function:
define TCM310_0 TCM 310 /dev/ttyAMA0@57600
At this point in the log file it returned the following:
2013.02.01 07:43:29 3: Can't open /dev/ttyAMA0: Permission denied
To remedy this add the users pi and fhem into the tty groups:
sudo usermod -a -G tty pi
sudo usermod -a -G tty fhem
Switch:
After you press the rocker the first time a new device entry is generated:
define EnO_switch_FEFFFEFB EnOcean FEFFFEFB
attr EnO_switch_FEFFFEFB room EnOcean
attr EnO_switch_FEFFFEFB subType switch
define FileLog_EnO_switch_FEFFFEFB FileLog .../log/EnO_switch_FEFFFEFB-%Y.log EnO_switch_FEFFFEFB
attr FileLog_EnO_switch_FEFFFEFB logtype text
attr FileLog_EnO_switch_FEFFFEFB room EnOcean
Manufacturer ID is 0xFEFFFEFB, telegram data will be logged automatically.
Sensor:
This is an example of an temperature (room controller) sensor. After you press the learn button the time a new device entry is generated:
define EnO_sensor_0088F03E EnOcean 0088F03E attr EnO_sensor_0088F03E manufID 00B
attr EnO_sensor_0088F03E room EnOcean
attr EnO_sensor_0088F03E subType roomSensorControl.01
define FileLog_EnO_sensor_0088F03E FileLog ./log/EnO_sensor_0088F03E-%Y.log EnO_sensor_0088F03E
attr FileLog_EnO_sensor_0088F03E logtype text
attr FileLog_EnO_sensor_0088F03E room EnOcean
Manufacturer ID is 0x0088F03E, telegram data will be logged automatically and can be displayed within a diagram.
Interface:
With the user interface you can visualize and configure graphical user elements to visualize events and send control telegrams to actuators.
A reference of FHEM commands for EnOcean can be found at:
http://fhem.de/commandref.html#EnOcean
A small guide “how to” can be found at: http://fhem.de/HOWTO.html
For German users there is an additional forum available: http://forum.fhem.de/
Example of visualization:
Following visualization example has been generated by STM 330 (temperature sensor) with HSM 100 (humidity sensor plugged):
#ID:0088F03E STM_330 temperatur & humidty sensor
define Sensor_0088F03E EnOcean 0088F03E
attr Sensor_0088F03E manufID 00B
attr Sensor_0088F03E room EnOcean
attr Sensor_0088F03E subType roomSensorControl.01
define FileLog_EnO_sensor_0088F03E FileLog ./log/EnO_sensor_0088F03E-%Y.log Sensor_0088F03E
attr FileLog_Sensor_0088F03E logtype text
attr FileLog_Sensor_0088F03E room EnOcean
More Resources:
EnOcean Link Trial Software is also available follow this article
element14: How to use EnOcean Pi with Raspberry Pi
For an overview see the article
EnOcean Pi: Transforms Raspberry Pi into a Wireless Gateway
Also See:
Greg Fenton's Article EnOcean Sensor Kit (ongoing) with 3D Printed housing for the Temperature Module.
For more details on setting up the EnOcean Pi and Sensors see my review
http://www.element14.com/community/roadTestReviews/1795
.
Top Comments