So my surveillance cam now only records when I am not at home. But what if I forget to turn off the TV? That should happen automaticly, too! But fear not: There is a solution – at least if you own a harmony hub. With the help of the “HarmonyHubControl” – tool (written in c++) this is done quite easily.

First of all you need to put the source onto the Raspberry. Don’t be afraid. No rocket science here. All needed tools should be already on your Linux distribution. The easiest way would be to clone the source via git:

If you prefer you may – of course – also use the long way and download those files in a zip file.

Now after you have the source code on your Pi you have to compile it. Done with ease. Just a single

and you created the file “HarmonyHubControl” in that directory. Now all you need to know is the IP-address from your hub. You usually can find it in your WiFi-Router under the name “HarmonyHub”

Let’s try if the connection works:

Warning! Double-check your password. If you enter a wrong one, you can still stert the activities, but on the next login in your “MyHarmony”-application you will be thrown out for a while. Don’t ask why this works this way. Better ask Logitech instead.

The Login is your email-address. If username and password are right you should see the following result:

So let’s list all activities:

As you can see there is an activity with the id “-1”. This activity shuts down all devices. For testing let’s just start an activity:

does start the FireTV in my case,

does shut em all down.

If you want to, do some fancy stuff with that possibilities. Use your stereo as an alarm clock? Have fun! (your neighbours, too, btw) 🙂