Skip to main content

Posts

Showing posts from December, 2015

Useful Raspbian Linux Commands

Return the octal file permission value for a file or directory stat -c "%a %n" * Replace * with the relevant directory or the exact filename that you want to examine. From the man page of stat , -c --format=FORMAT use the specified FORMAT instead of the default; output a newline after each use of FORMAT %a Access rights in octal %n File name Usage: With files: $ stat -c "%a %n" ./Documents/Udev.html 664 ./Documents/Udev.html With folders: $ stat -c "%a %n" ./Documents/ 755 ./Documents/

Installing AeonLabs Z-Wave Stick on a Raspberry Pi openHAB server

Background This guide is for  installing an AeonLabs Z-Wave Stick Gen5 usb stick on a a Raspberry Pi and integrating it into the openHAB home automation server for controlling Z-Wave devices. Steps Install Z-Stick on Raspberry Pi USB port - powered hub is desired The Z-Wave Stick is automatically detected without additional software installation. Correct detection of the USB stick can be verfied with the  lsusb  command: pi@raspberrypi /usr/share/openhab $ lsusb Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 001 Device 008: ID 0658:0200 Sigma Designs, Inc. Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. Bus 001 Device 004: ID 05e3:0608 Genesys Logic, Inc. USB-2.0 4-Port HUB Bus 001 Device 005: ID 045e:00f5 Microsoft Corp. LifeCam VX-3000 Bus 001 Device 006: ID 05e3:0608 Genesys Logic, Inc. USB-2.0 4-Port HUB The “Sigma Designs, Inc.” device is the Z-Wave USB stick. Now we need to find out

Configuring openHAB on Rasberry pi

General Configuration - openhab.cfg The runtime comes with one core configuration file, the file  openhab_default.cfg . The purpose of this file is to define all basic settings, such as IP addresses, mail server, folder locations etc. The file also contains settings for all (optional) bindings. These settings are automatically dispatched to the according binding. For this, all settings come with a namespace (such as "mail:" or "knx:") to identify the associated binding. First thing after unzipping the runtime should be creating a copy of  openhab_default.cfg  to  openhab.cfg .  cd /usr/share/openhab/configurations sudo cp openhab_default.cfg openhab.cfg sudo nano  openhab.cfg All personal settings should always only be done in this copy. This ensures that your settings are not lost, if you unzip a new version of the runtime to your openHAB home directory. The  openhab_default.cfg  file comes with extensive comments which explain, what settings are avai

Install openHAB on Raspberry Pi

Background This guide will enable you to install openHAB on Raspberry Pi computer. Steps Install Java if 1.6 or higher is not already installed. The following will display your current Java version: java -version   Add the openHAB Bintray Repositories key to the apt-keyring  usin g curl: curl 'https://bintray.com/user/downloadSubjectPublicKey?username=openhab' | sudo apt-key add - Add openHAB apt repository to the apt sources list (Note: the current openhab.list file will be overwritten) echo "deb http://dl.bintray.com/openhab/apt-repo stable main" | sudo tee /etc/apt/sources.list.d/openhab.list Resynchronize the package index sudo apt-get update Install the openHAB runtime sudo apt-get install openhab-runtime If you have more than one OpenHAB binding with a USB device (Z-Wave, RFXCOM, etc), refer to  symlinks Start openHAB - manually sudo /etc/init.d/openhab start sudo /etc/init.d/openhab status Start openHAB - at system startup sudo update-rc.