Introduction

I own a Xiaomi Robot Vacuum. This robot can be controlled by the Xiaomi app, however, I don’t like it very much. The idea is to control this robot over HomeKit. To use HomeKit, I use an old Raspberry Pi 1B. The software will be HomeBridge.

Setting up the Pi

Installation and Configuration of Raspbian

Use Etcher to write the image to the SD card. Remount that SD card and add a file called „ssh“ in the root of the mounted partition. This will enable SSH from the beginning so that you can login directly to the Pi. I don’t want to attach a screen or keyboard to that machine so it will only be reachable over the network. Now boot your Pi from this SD card.

Identify the Pi’s IP (e.g. by looking at the network overview in your router). Now connect to that IP with user „pi“. The default password is „raspberry“. Please change the password now with passwd and assign a new user password.

Update everything with apt:

1

2

3

4

5

sudo apt-get update

sudo apt-get upgrade

sudo apt-get dist-upgrade

sudo apt-get clean

sudo reboot

Install nodejs 8.9.4

According to Wojtek only this version works currently with HomeBridge. I did not test any other version so I’m just describing what I did on my machine:

Download nodejs for the PI into your users homefolder, e.g. with wget https://nodejs.org/dist/v8.9.4/node-v8.9.4-linux-armv6l.tar.xz

Generate a new MAC address separated by : using this website. You’ll need the IP address of your Xiaomi robot as well as the token. There are several ways to get the token. I’ve extracted mine from the iOS backup. Instead of uploading the token I’ve used this command on the token taken from the sqlite database:

Check if everything is working by starting homebridge for the first time. It should show a QR code. If it does, cancel the process with ctrl+c

Automate HomeBridge startup

1

2

3

4

5

6

7

cp~/.homebridge/config.json/var/homebridge

sudo cp-r~/.homebridge/persist/var/homebridge

sudo chmod-R0777/var/homebridge

sudo systemctl daemon-reload

sudo systemctl enable homebridge

sudo systemctl start homebridge

sudo systemctl status homebridge

Adding the HomeBridge to iOS devices

Install the Home app, if you’ve removed it from your device. You can reinstall it from the App store.

Open the Home app and add a new device

If you’ve give the app access to your camera, you can scan the QR code you’ve seen earlier. However, HomeBridge is now running as a daemon in the background so you won’t see that QR code. You can add the bridge manually by using the PIN you’ve set in the config.

I recently upgraded my ambilight clone from 50 to 104 LEDs and I’ve also updated my OpenElec installation on my Raspberry Pi B+ to 6.0.0. However, the hyperiond wasn’t able to communicate properly with Kodi so that no ambilight information was send to the LEDs: The LEDs would always be black, if I want to watch something on the Raspberry Pi.

I’ve opened an issue on github but I didn’t get a useable response so far. The configuration and installation worked fine when I’ve connected with the iOS app or from the command line.

Today I’ve tried to use OSMC as surrogate for OpenElec and I’m really impressed: it worked almost out of the box with my old configuration. So I want to share what’s necessary to migrate from OpenElec to OSMC:

Create a backup from your OpenElec .kodi folder. You’ll find this folder on OpenElec in /storage/.kodi

Backup your hyperion.config.json or create a new one with HyperCon according to your setup

Install OSMC on a SD card

Boot from this SD card and follow the initial configuration screen

Connect via SSH to OSMC. default user/password are osmc/osmc.

Install hyperion according to nadnerb’s instructions. The spi part is important, since OSMC has SPI disabled by default. You’ll also want to remove the lirc line since this blocks the pins necessary for the default installation of WS2801 LEDs.

Copy your hyperion.config.json to /etc. Be sure that you’ve changed the path to your effects folder from /storage/hyperion/effects to /usr/hyperion/effects

I’ve recently bought a Heos HomeCinema and a Heos 1. The Heos devices are created by Denon and offer a multi room wifi speaker setup, similar to Sonos. Since Sonos did not offer a DTS compatible speakerbar for my TV, I’ve decided to give the Heos devices a try.

Its absolutely amazing how easy these devices are setup. You install the power and install an Android or iOS App on your phone. You can start the Heos app and can configure a new speaker. The speaker will be configured over a regular stereo audio cable. After this configuration step, the speaker will be available to all devices running the Heos app on your local network.

Denon currently promotes the GoPack: A battery pack for the Heos 1 and a bluetooth dongle which adds support for bluetooth connections on all Heos devices. However, Denon only sells the bluetooth adapter in combination with the battery pack. Since I don’t require the battery pack, I was wondering what kind of bluetooth dongle is required.

I’ve searched for a few weeks but finally found on amazon.com a bluetooth dongle which was used by a fellow Heos user. At the same time I tried to contact the Denon chat support and they recommended me this Bluetooth dongle. Regardless which one you’ll select, you’ll need a bluetooth 4.0 dongle with BCM20702 chipset:

Just put the stick into the USB port of the Heos speaker:

You can now press and hold the connect button until the Heos starts to blink green:

The Heos is now in discovery mode and can be easily paired with your bluetooth enabled device. This also works for the Heos HomeCinema soundbar: