Jump to content
C4 Forums | Control4

Homebridge Driver for HomeKit Support?


Joshua Pressnell

Recommended Posts

How are folks using this driver?  Is it being used to allow you to use HomeKit and Siri to control C4 devices in your C4 system?  Or are people using it to allow C4 to control devices that are supported in HomeKit/HomeBridge but which aren't supported in C4?  If it is the latter then I am thinking that this could be useful to allow me to control certain types of lights/lighting controllers that aren't supported in C4.  And what about devices, like Hue bulbs, that aren't native C4 devices?  Does it make sense to install the drivers for C4 or for HomeKit or both?  Or does it matter?

Link to comment
Share on other sites


I won't have the docker version for a while.  There's a lot to do, and getting things setup so that all my appliance code works properly involves a lot of low-level linux IT setup.  My Pi images are solid, though.

The system is intended to expose the Control4 project to HomeKit.  All supported devices in Control4 become devices in HomeKit, and you can use those devices as if they were HomeKit-compatible.  This lets you control C4 lights, dimmers, garage doors, security systems, etc from Home app and with Siri.  

What you put where depends on how you want things setup.  If you install drivers for your Hue bulbs in C4, and those bulbs support the light proxy, then my HomeKit setup will automatically pick them up, and allow you to also control them in HomeKit, by routing HomeKit communications through C4.  I believe Hue bulbs are also directly HomeKit compatible, so you could just add them to Home directly, and add them to C4 and move them to my system's ignore list, so they don't show up twice.

There's lots of options.

Link to comment
Share on other sites

  • 1 month later...
9 hours ago, VINCELdUB said:

Joshua has worked over and above in helping me keep my clients happy and this driver and its appliance is a great product.

 

I wanted to jump in and agree!  And it's not about customers...its about me!  Joshua has helped above and beyond through beta and after.

That said...  Everyone go out and sell this driver!  I've had C4 in my home for almost 10 years.  This driver has brought new life to a system!

Hopefully Joshua will master the challenge of finding a way to use my phone to automate the theater and I would never buy another C4 remote again...(hint hint)

Link to comment
Share on other sites

39 minutes ago, ekohn00 said:

Hopefully Joshua will master the challenge of finding a way to use my phone to automate the theater and I would never buy another C4 remote again...(hint hint)

You can kind of do that now, it's just not as elegant as a truly native HomeKit solution would be.  The basic idea is that you create a HomeKit room that represents your AV system and then add a bunch of virtual switches to it, using something like the Clipsal Legacy Relay Light driver.  Then you use programming on the C4 side to set the switch states appropriately and react to HomeKit changes.  Because it relies on C4 programming and lots of virtual drivers to represent system states and remote buttons, it's a lot more work to setup and maintain than I'd like, and I don't recommend it to the general public, but it is possible.

I continue to hope that future releases of HomeKit will actually include AV capability, beyond just the "speaker" representation added in iOS 11 (which only allows volume control).

Link to comment
Share on other sites

4 minutes ago, Joshua Pressnell said:

You can kind of do that now, it's just not as elegant as a truly native HomeKit solution would be.  

I'm almost tempted.....but think volume control would be a real pain.  At least on/off and flipping between tv/appletv should be simple enough.

 

 

Link to comment
Share on other sites

1 minute ago, creede said:

Any update on support of shades? I have 6 Mechoshades running on my C4 system and I would love to have homekit support. I'd be happy to beta too if it's helpful.

 

I took a brief look at it yesterday.  It looks like the C4 system only supports the "up" and "down" position for shades/blinds, and doesn't handle tilt/rotation at all?  Is that right?  If we're talking about the most basic shade function (traveling up and down), I might be able to get that in relatively shortly.  

Link to comment
Share on other sites

Just now, Joshua Pressnell said:

I took a brief look at it yesterday.  It looks like the C4 system only supports the "up" and "down" position for shades/blinds, and doesn't handle tilt/rotation at all?  Is that right?  If we're talking about the most basic shade function (traveling up and down), I might be able to get that in relatively shortly.  

That sounds right. I've got roller shades. Physical switches will do set stops (25% etc) but in C4 I just get up down and stop, which is fine by me.

Link to comment
Share on other sites

1 minute ago, creede said:

That sounds right. I've got roller shades. Physical switches will do set stops (25% etc) but in C4 I just get up down and stop, which is fine by me.

Right.  The problem is that there are too many "options" that exist in the abstract concept of a "blind".  It looks like the Control4 stuff "might" support "target position", for instance, but I can't see any way to control/set it in programming.  In HomeKit, you can set any position from closed to open and in between (represented by 0-100), so I was looking for a way to check target and current position.  It looks like most relay-based blinds only know about "up" and "down" and the C4 driver figures that out based on timing, which seems fraught with potential issues.

Link to comment
Share on other sites

In C4, blinds that are smart, like QMotion and some Lutron, you can set them to percentages.

but most blind systems are only relay based and have no logic at all, so typically you get up, down and stop.  You can try to create the logic necessary but I wouldn't bother because eventually it does get out of whack.

the only experience I've had with Somfy is all relay based so not sure if they have anything smarter. 

Link to comment
Share on other sites

On 6/23/2017 at 9:16 AM, Joshua Pressnell said:

 using something like the Clipsal Legacy Relay Light driver.  

Anyone have some sample code...I might have missed a step.

I created a test room.

Added the driver.  went to programming, when Clipsal Top pressed -> turn on media room TV., when Bottom pressed -> turn off Tv.

as a test went to C4 remote....nothing is working.  

 

UPDATE:  Strangely the V2 driver works.

Edited by ekohn00
updated
Link to comment
Share on other sites

Use only the v2 drivers! This is something I have learned recently. No proper reason why. Just experience.

 

 

On another note. Wonder if there is a way to leverage the room volume driver for Alexa integration that populates

 

 

 

 

Happy Automating!!

Link to comment
Share on other sites

On 7/5/2017 at 9:30 PM, VINCELdUB said:

Use only the v2 drivers! This is something I have learned recently. No proper reason why. Just experience.

 

Looks like version 2 was the trick.  I notice it’s executives on status change...makes things interesting since on and off on the switch could result in off or on.

My next test will be to match the devices’ physical status (on or off) onto the Virtual Swiches’ status.  Any recommendations?  I assume as the status changes on the physical deceive i can set the virtual swtich.

Link to comment
Share on other sites

I use on and off for it all the time. Hey Siri, turn off family room power. Family room power is switch name and when off, turns family off... then name a switch cable tv. Hey Siri turn on cable tv in family room. When switch called cable tv is on, select cable tv as video source in family room and turn on family room power switch as well.

 

 

 

 

Happy Automating!!

Link to comment
Share on other sites

This is exactly what i have.

however, i notice the virtual switch can get confused.  For instance.  If I start with all switches off, and do a “hey Siri turn on family room” it turns on the TV and Stereo easy enough.

But then if I use the C4 remote to turn everyhting off, I can’t so hey Siri again as the virtual switch is still shows everything on.  (It never shut off with the room.)

Can I assume you some how tied the room to the clipsal driver?

Link to comment
Share on other sites

 

Yes at the room level always.

 

 

My last post was done with voice to text in a hurry. My apologies. Ultimately, you want to add an additional action at the room level. In programming on the left side select the room, then press the right arrow on your keyboard a few times to expose the room variables.

 

 

Select power_state

 

 

Turn on the right side select the room again.

 

Then select conditionals and if room is on and if room is off. But both of those questions in the center.

 

 

Now you will nest all of your virtual media light switches and the corresponding state under each of those conditioners.

 

 

Example:

 

 

?if family room off

 

--> set family room power OFF

 

--> set cable tv OFF

 

--> set media player power OFF

 

?if family room on

 

--> set family room power ON

 

 

This way, whenever you turn the room off it will also turn off the cable TV in the media player switches as well.

 

 

This will close the loop.

 

 

 

 

 

Happy Automating!!

 

Link to comment
Share on other sites

  • 1 month later...
  • 2 weeks later...
On 11/4/2016 at 11:30 AM, Joshua Pressnell said:

I've been working on developing a homebridge plugin to fully enable HomeKit control/reporting of various Control4 devices.  Initially I'm supporting lights, dimmers, door contact sensors, window contact sensors, generic contact sensors, motion sensors and security systems (because that's what I have in my home).  I'm also working on a Control4 driver that will communicate with the homebridge plugin for all system devices without additional programming needed.

 

I purchased and installed the plugin a couple of weeks ago. It works pretty well. I have a Synology Diskstation and installed homebridge in a docker container.

The only issue is the configuration JSON. Is it possible to request/update it automatically? At the moment, I have to manually copy and paste JSON every time there is change in Control4 configuration.

 

Link to comment
Share on other sites

1 hour ago, roustem said:

 

I purchased and installed the plugin a couple of weeks ago. It works pretty well. I have a Synology Diskstation and installed homebridge in a docker container.

The only issue is the configuration JSON. Is it possible to request/update it automatically? At the moment, I have to manually copy and paste JSON every time there is change in Control4 configuration.

 

I don't provide an automatic way to do that, for a number of reasons.  Generally, I can think of quite a few scenarios where "auto-importing" would result in undesirable behavior and additional admin overhead.  If you run my appliance firmware (either by purchasing one from me or by installing my licensed OS image on your own pi) then my firmware makes the import a one-click process via an easy-to-use web-based configuration portal.

Link to comment
Share on other sites

4 hours ago, Joshua Pressnell said:

I don't provide an automatic way to do that, for a number of reasons.  Generally, I can think of quite a few scenarios where "auto-importing" would result in undesirable behavior and additional admin overhead.  If you run my appliance firmware (either by purchasing one from me or by installing my licensed OS image on your own pi) then my firmware makes the import a one-click process via an easy-to-use web-based configuration portal.

Thank you. I think you also worked on the Docker image but it seems that this work was put on hold.

Can I implement the semi-automatic refresh myself? Is there a URL I could use to retrieve the JSON from the plugin?

Link to comment
Share on other sites

12 hours ago, roustem said:

Thank you. I think you also worked on the Docker image but it seems that this work was put on hold.

Can I implement the semi-automatic refresh myself? Is there a URL I could use to retrieve the JSON from the plugin?

You could potentially, but it wouldn't be dead simple.  You'd want to compare the old list to the new list, for example, so you don't double up.  You wouldn't want to just drop the old list and replace with the new list, because you might have non-C4 devices in the HomeKit setup (as an example).  And you'd need to restart the homebridge service after each change.  If you want to try and take that on, PM me.

Link to comment
Share on other sites

  • 3 weeks later...
This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.