[RELEASE] HubConnect - Share Devices across Multiple Hubs (no longer SmartThings!)

Lutron will work simultaneously across multiple hubs all by itself!! Doesn't need HubConnect :slight_smile: ASSUMING you have a SmartBridgePRO.

Just install the Lutron Integration on Hubitat and ID all the devices.

Just to be clear, the UniversalDrivers have no tiles, thus can be used in both platforms without bloating the code. They were not mean to provide a UI on SmartThings. Not that you can't add the tile definitions within ST and give them an interface. However for now, they at least allow the devices to be exposed for use in automations like WebCoRE.

SmartThings is a hot mess.. That defiantely is a ST Cloud Issue.

No signature of method: physicalgraph.app.AppStateCacheService.getAppState()

That implies that ST is unable to load the state map from cassandraDB.

Try adding the devices one at a time.

Even after updating clientURI to state.clientURI on the Server Instance, I'm still having issues getting the mode to sync with the remote hubs. I keep seeing this on the server's logs (IP & Token removed):

app:1302019-03-22 10:57:24.946 pm errorjava.net.URISyntaxException: Illegal character in path at index 45: http://XXXXXXXXXX/apps/api/1737/modes/Home (Dawn)?access_token=XXXXXXXXXXXXXXXXXXXXXXXXXXXX on line 598 (realtimeModeChangeHandler)

I changed to Home (Dawn) location mode on the coordinator hub as a test on these logs.

Special char perhaps: those parenthesis

Just hypothesizing out loud.

Yes, I tested on my hubs with a Mode with paren's and it does error.

1 Like

Hmmm, so it still only created the first unless I unchecked the first and then checked only the second, and I'm not sure the devices are actually "syncing" between the hubs, nor am I sure they're actually working on ST (no "data" in the ST IDE for the device, where I'm guessing I should see, say, on/off status and level for a dimmer, which these are). Still getting the errors above on both the Hubitat and ST sides, so probably no surprise there.

Got it all setup this morning (Hubitat to Hubitat). Very nice job @srwhite.

I only have a few devices coming across, as I have to write a custom stub or two. But the devices coming across are working as expected.

By following the directions, except the configuring OAuth part that is missing in the write-up (but I knew about that from reading this thread anyway), it was pretty easy and worked exactly as written for me.

Kudos!

I'll update my modes without special characters to see if that fixes it, thanks for the suggestion.

One more question - @csteele or @srwhite , is there any guidance on creating the custom drivers?

I've tried a few simple/test ones, and haven't gotten one to work yet. As soon as I type the first attribute all field get wiped out/blanked when I click off of the attribute field I just typed and the screen updates.

So I am likely doing something wrong / it is not passing validation.

The #1 thing I need is a custom thermostat driver/device with one additional attribute and one additional command.

Hello all, I need some help. I've got one HE and one ST hub. Working to migrate (slowly) to HE.

I installed all of the requested HubConnect Drivers in Driver Code.
I installed HubConnect Server for Hubitat in Apps Code.
I installed HubConnect Remote Client in My SmartApps on ST hub.
I added the user app HubConnect Server for Hubitat.
I added a Server Instance with the IP address of my ST hub
Using my ST App in Smart Apps I added HubConnect Remote Client with the IP address of my HE and the proper unique code from HE. I also added one device from several categories including one each of a motion sensor, light and contact sensor.

I don't get any status of the individual devices

I can control the light, but don't get anything from the other devices.

I've tried removing everything and starting over, with no change.
I've tried deleting the individual devices.

When I add the device again from the ST app I get a message that the device exists and it's skipping it.

I did get two errors
groovyx.net.http.HttpResponseException: Internal Server Error on line 598
org.apache.http.client.ClientProtocolException: null on line 598

Any advice would be welcome.
Thanks
Steve

Server has a Manage Custom Drivers section.. allows up to 8 attributes.

You build a stub driver and then fill in the form.

29%20AM

Effectively that page builds this:

"thermostat":		[driver: "Thermostat", selector: "genericThermostats", attr: ["coolingSetpoint", "heatingSetpoint", "schedule", "supportedThermostatFanModes", "supportedThermostatModes", "temperature", "thermostatFanMode", "thermostatMode", "thermostatOperatingState", "thermostatSetpoint"]],

and completes all the other hooks.

Create a new stub driver, in your case, use the Thermostat one as a starting point, probably, with a unique name: "JasonThermo" for example and then fill out the form.

Ok - not sure what I did wrong but my ST remote hub events are not being sent to HE.

The devices selected on my ST hub are being created in HE without issue. I can then control the ST device through HE without issue. However, the state of lights, motion and contacts is not being sent to HE from ST.

I have ST debug logging on, but there is nothing in the log. Thoughts? What did I miss?

OK, That makes more sense. I'll give it a try after lunch...

I was doing the custom driver def in the app before the new stub driver was present.

That's OK, as long as you don't mind error messages... LOL

Well, it is wasn't ok... As it wouldn't let me do it...

I filled out the attribute class name (I used "test1" as I wasn't 100% sure what to put - probably the real issue??), then gave a name, and as soon as I typed anything in the attribute field - all three blanks were wiped out after clicking off of the attribute entry field.

Never could get it to the point I could click NEXT at the bottom.

EDIT: Nope. As soon as I type anything in the attribute #1 field, and then hit ENTER or click off the field it erases the values in Attribute Class Name and Driver Name. I'm probably still doing something stupid/wrong.

Even a space is getting this error as well from the looks at it

app:992019-03-23 11:56:32.540 am errorjava.net.URISyntaxException: Illegal character in path at index 47: http://10.100.xxxxx/apps/api/321/modes/Daytime Mode?access_token=xxxxxxxxxxxxxxx on line 598 (realtimeModeChangeHandler)

it's true for me too.

Strange, I tried this on Wed, evening,

1 Like

Yes, it's a URL issue since the name of the Mode is just passed straight through in the URL.

You can't browse to "amazon.com/anything with spaces either"

Does the namespace entry matter when making custom stub drivers? I set my custom apps/drivers to "Botched1".

I just wanted to make sure we didn't have top leave it as "shackrat" for some non-obvious-to-me reason.

Is the GitHub code and readMe now up to date with the original issues that were identified a couple of days ago? Wanting to make my first try this weekend as easy as possible.