Homebridge plugin for HomeKit support and automations

I assembled a Raspberry Pi and used the DIY method to install the HOOBS software: https://support.hoobs.org/docs/5e875b610ab68b0344e872c5

HOOBS takes all of my non-HomeKit IoT devices, and makes them HomeKit compatible. There are plugins for Nest cameras, game consoles, streaming boxes, Ring doorbells, Rachio sprinklers, anything under the sun, you name it! If it's IP-addressable, chances are there's a HOOBS plugin for it: https://plugins.hoobs.org/search/aG9tZWJyaWRnZQ

Anyway, with a HOOBS plugin for Channels, there are so many things we could do, very easily with HomeKit automation, like "if someone rings the doorbell, pause the TV." Or "When I tap play, dim the lights, and when I tap pause, brighten the lights." Or even just give us an easy button in HomeKit to quickly toggle closed captions. Maybe make them automatically appear when the volume is quiet? The possibilities seem endless.

So this is a feature request for a Channels plugin for HOOBS (and maybe its compatriot, homebridge?)

1 Like

I run Homebridge myself. You could do some cool stuff for sure.

Homebridge is great, but you should check out Home Assistant. It is much more powerful. And you can run it side by side with Homebridge.

There is a Home Assistant integration for Channels:

You can expose that (or anything else in HA) to HomeKit for your automations. Or write automations directly in HA, which is WAY better than what you can do in HomeKit! I ended up migrating all devices to HA so I can write custom automations, but then I expose it all back to HomeKit so I can use the Home app and Siri.

I see this has been discussed, there was talk of a homebridge plugin at some point:

And in the meantime I might be able to handle some basics via the http switch plugin using the Channels API

https://getchannels.com/api/

I’d love any pointers if anyone has done this before, What is the full http command for “TOGGLE CC”? I can edit the config.json and handle the rest from there, I think :slight_smile:

Thanks, Home Assistant has been on my radar for awhile, been meaning to check it out. Your post may have pushed me over the edge :slight_smile: Do you know it it can live alongside HOOBS on the same Raspberry Pi 4? What would be the best/ safest way to install it?

1 Like

Hi Mike! I have the Channels media player added to Home Assistant but I can’t figure out how to trigger anything with it to an automation. It would be great to trigger the lights off in the evening when a show is played on Channels. Do you have any guidance here?

2 Likes

I don't know a Raspberry Pi, so I'm not sure. I have Homebridge and Home Assistant (and Channels and Plex and lots of other stuff) installed on a Synology DS918+. All works well together in that environment, but that is way more robust than an RPI.

HA has a bigger learning curve than Homebridge, but you can do soooo much more with it. Especially if you have a programming/scripting background. I still run Homebridge, but only to easily get Ring and Harmony into HomeKit.

I actually don't have any automations set up for my Channels integration. It really depends on what you're trying to do. I'm sure could trigger off of the state = 'playing'.

And if you wanted to trigger based on a particular show, you would add something like:

condition: template
value_template: "{{ states.media_player.your_channels.attributes.media_title == 'Your show' }}"

1 Like

Hoobs is actually just HomeBridge under the hood with a fancy coat of paint on it.

A homebridge plugin wouldn't be so tough, I just didn't have time to build it. I'd be happy to collaborate if anyone starts one though. Just ping me and point me to the repo.

FWIW, I have everything in Home Assistant and I expose particular things to HomeKit with Home Assistant.

4 Likes

@maddox Just curious - What have you found useful to expose to HomeKit?

I expose room lights and really anything I want to use with Siri.

I do NOT use HomeKit for ALL my things or ANY automations. I use HomeKit as a voice UI to use with Siri. Which is to mean, not that much stuff. I use Alexa around the house.

I also put my cameras in there, it works great for that and will be real neat with the tvOS 14 integrations.

2 Likes

@maddox Gotcha. I misunderstood and thought you were saying you expose particular Channels-related entities to HomeKit. I was curious if you had any cool/useful ideas. And same here - All of my automations now happen in HA. HomeKit is really just for Siri and the Home app.

I wrote the Home Assistant Channels integration. You can add it and point it at your devices.

It will show what's currently playing and. you can write automations based off that and it's play station. Beware though, there will be some latency as it is a polling integration, so there might be 1-2 seconds in latency on updating state.

I use mine together with my TVs. When my TVs turn off, i send a command to the corresponding Channels instance to stop playing. That way if the tv is turned off, Channels stops playing back video too (since Apple doesn't give us an event in tvOS :rage:)

2 Likes

Since this post, I've switched over from HOOBS to Homebridge. Homebridge's official image now includes Config-UI-X, which is an even fancier web wrapper than HOOBS, and the devs have added some great features lately, like "child bridges." Everything's gotten more stable lately, and the platform keeps maturing. HOOBS fell far behind and plugin support is a problem.

Anyone else interested going down this road, I'd recommend starting with Homebridge (or Home Assistant, if that fits your use case better) and skipping over HOOBS. It's not worth it.

2 Likes

Just adding some newer info, at least for Homebridge users, there's also this plugin which works with PyATV:

This is a Homebridge plugin that exposes Apple TVs to HomeKit, noteably the power state as a switch and optionally the device state (playing, paused, etc.) as motion sensors.

This might be useful for some automations, but the specific implementation also sheds a bit of light on the awkwardness involved. Still, I could see it helping others out there! PyATV lets you issue remote control commands, list and launch installed apps, retrieve metadata, stream via AirPlay, and more.

Personally I've also got Home Assistant, so set up a few automations there. Channels and AppleTV support is built in there. I've now got it set up to enable Hue Sync's ambilighting in the living room automatically at night when video starts playing there. And they turn off when I pause or stop. Cool stuff :+1:t3:

What is the plugin you refer to? Looks like you meant to post a link for "this plugin" but is was not a link.

Perhaps he meant:

Although, after hearing @maddox's responses for why there is no first-party Homebridge option, I don't really see the value. Apple's Home options don't expose the media player functionality that Home Assistant does, and the gap filled with Shortcuts makes adding an AppleTV to Homebridge seem superfluous. (Of course, this is just my opinion, and your needs and use case will probably differ.)

1 Like

Thanks!

1 Like

I meant this even newer one. Apologies for the link formatting, I fixed it just now in the previous post:

1 Like

Cool, I’ll have to check that out. Haven’t gotten Home Assistant set up yet and am using Homebridge for some other things. I think I played with some other ATV plugins but hadn’t seen this one.