Skip to main content

Posts

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 ne...

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 ex...

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....

Scanning & Filing Electronic Receipts

Scanning & storing receipts is my new raison d'etre! I use Evernote , Google Drive, an Android phone and want to store receipts. I am not the most organized person, rather I aspire to being organized, and in the main I am able to achieve some modicum of success. I have a bit of a system ... when my wallet is bulging with paper I sift through and separate cash notes from receipts and other dendrites I have picked up.  The receipts are then put on a receipt spike. I have noticed that after a few months some receipts fade and become unreadable (is this by design... perhaps my paranoia?), so having an electronic copy available would be a great idea. Receipt Spike :) Scanning I started off using my multi-function inkjet printer for scanning, but realized that this was all too time-consuming. I decided to opt for using my android smartphone as it is more versatile. Applications I went on the hunt for a good app. There is a big choice out there, and I am not a fan of havin...

The Blue Spinning Doughnut, or Office 2007!

I remember the days of Wordstar on DOS 2.01. WYZIWYG was probably a children's character on "Watch With Mother", GUI was something on the bottom of your shoe, and a mouse new where it should hide. Excel was something to be done at school, Microsoft Mutliplan and later, Lotus 1-2-3 were serious applications for number jugglers.  On the word processor front, the Wordstar guru knew his way around the keyboard (rather like programming a Sinclair ZX81 without murdering the nerve endings in your fingers), committing a myriad of key combinations to memory to be recalled at a moments notice in the quest to complete a document and finally print it out on a 9-pin dot matrix printer. It was all so innocent, there was a certain pleasure to be had in seeing what the final document would look like (Print Preview also was something to be dreamt about, and would probably be an invention of Gerry Anderson's), and saving trees wasn't even on the guilt agenda.  Over the years thing...

Home Theater Computer (HTPC) - it's a journey!

I'm currently battling my way through building a Home Media/Automation Center PC. As usual I don't take the easy route and buy something off the shelf. There seems to be a switch within me that flicks on when approaching situations, rather than trying to solve the immediate issue, I step back and look at what I can encompass beyond the initial opportunity, and then resolutely pursue a course of action that I know in my deepest innards will cause me blood, sweat and tears, and leave me feeling that I should have just done what millions of people do and buy a product that works out of the box. Perhaps there is a masochistic streak in me, or perhaps tinkering with technology is my yin and yang, but here I am again, and my feet keep plodding forward :-)