[BETA] Hue (Re)Connect - with scene handling

Cool, ill try out the all 4 hue app :slight_smile:

The LivingWhites Adapter basically is a zigbee plug with an included dimmer

I keep getting the below error when trying to get setup.

21:42:49: error physicalgraph.app.exception.UnknownDeviceTypeException: Device type ‘Hue Bridge’ in namespace ‘smartthings’ not found. @ line 598

Urmm forgot the device handlers lol :grinning:

Got it working, but odd thing is if you don’t select device or hub quick it drops out of the list within 3 seconds if you don’t hit the done confirmation. Scenes are not being detected for me are they working for others?

Do you plan to support the new Hue app or is it not possible?

Its not my code originally, I have done my best to improve this app I have tried to do more but I end up breaking things. Last week while modifying I broke the app and I had to remove all of my lights and have moved to Hue & Improved as it supports multiple bridges.

I would recommend waiting for a new version of Hue Lights & Groups & Scenes (OH MY!) to be released it can create scenes and groups etc though I havent tried it my self

1 Like

Here is the Beta version of the Hue B Smart service manager and
version 1 of the DTHs. This replaces my older HLGS service manager app (which will not be updated).

Does it handle Hue Beyond and the lights that come with the Dimmer Switch?

It has been tested on the dimmer switch lights. Haven’t tested it with hue beyond.

I’ll volunteer for the latter sometime this week when I get a spare hour or so.

(“Yes dear, you’re not going to be able to control the living room lights via Alexa for about half an hour. Sorry.”)

Has anyone had issues importing scenes? I installed this app, and it’s able to see the bridge, bulbs and groups, but isn’t able to see any scenes. I created two custom ones, and it keeps saying 0 scenes on the smartapp config screen. Any ideas?

Here’s a relevant section of the logfile

4605071e-0a53-427a-942e-d4f45a8257e2  5:33:08 PM: debug parse() - [name:saturation, value:79,     isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) saturation is 79]
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:08 PM: debug Its a scene
4605071e-0a53-427a-942e-d4f45a8257e2  5:33:08 PM: debug parse() - [name:alert, value:select, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) alert is select]
e4be3c27-7de1-4cbd-b233-d7de4c6f03e5  5:33:08 PM: debug parse() - [name:effect, value:none, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) effect is none]
f7a9e72e-bee8-4d05-90d9-35a5420cd719  5:33:08 PM: trace Get state for [QO0Nd6BbTr0mbhd, LlmyaiW8EblzFOb, ZABK2GQoEOLmISR, x5t9c8p1rpGJKKf, 1sxNEF0V7KghpNI, F7n9YQxLttVO2mG, xhsmphYH2eMMVwC, oiyeVVxtYmS5Ox6, i8GYnoka9NDXIBI, eHpctNCGjQ8B0Mb, qVJnm5z68zYgJJD, vYpABTxIuTZY08V]
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:08 PM: debug Its a scene
e4be3c27-7de1-4cbd-b233-d7de4c6f03e5  5:33:08 PM: debug parse() - [name:alert, value:select, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) alert is select]
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:08 PM: debug Its a scene
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:08 PM: debug Its a scene
4605071e-0a53-427a-942e-d4f45a8257e2  5:33:08 PM: debug parse() - [name:color, value:#E4571A, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) color is #E4571A]
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:08 PM: trace Adding items to state...
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:08 PM: debug Its a scene
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:08 PM: debug Its a scene
e4be3c27-7de1-4cbd-b233-d7de4c6f03e5  5:33:08 PM: debug parse() - [name:color, value:#FD013D, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) color is #FD013D]
e4be3c27-7de1-4cbd-b233-d7de4c6f03e5  5:33:08 PM: debug parse() - [name:level, value:76, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) level is 76]
e4be3c27-7de1-4cbd-b233-d7de4c6f03e5  5:33:08 PM: debug parse() - [name:switch, value:on, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) switch is on]
7c66d160-33b0-473e-a122-0d35bc00da11  5:33:08 PM: debug parse() - [name:alert, value:select, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) alert is select]
7c66d160-33b0-473e-a122-0d35bc00da11  5:33:08 PM: debug parse() - [name:effect, value:none, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) effect is none]
7c66d160-33b0-473e-a122-0d35bc00da11  5:33:08 PM: debug parse() - [name:saturation, value:99, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) saturation is 99]
7c66d160-33b0-473e-a122-0d35bc00da11  5:33:08 PM: debug parse() - [name:hue, value:100, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) hue is 100]
7c66d160-33b0-473e-a122-0d35bc00da11  5:33:08 PM: debug parse() - [name:color, value:#FD0101, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) color is #FD0101]
7c66d160-33b0-473e-a122-0d35bc00da11  5:33:07 PM: debug parse() - [name:level, value:76, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) level is 76]
7c66d160-33b0-473e-a122-0d35bc00da11  5:33:07 PM: debug parse() - [name:switch, value:on, isStateChange:true, displayed:true, linkText:Hue (ReConnect), descriptionText:Hue (ReConnect) switch is on]
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:07 PM: trace Bridge: 00178846337E - Host: 192.168.1.11:80
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:07 PM: trace Bridge: 00178846337E - Host: 192.168.1.11:80
416d0290-e9f8-4eb0-8f75-c79591bf890e  5:33:07 PM: debug Discovering New Groups

Figured it out. It looks like the Hue API response may have changed. The logic that filtered out ‘default’ scenes relied on the scene name containing a timestamp in it, but that isn’t the case anymore (or at least on my bridge). If you run into the same issue, you just need to comment out 3 lines in the sceneDiscovered function (around line 300)

if (it.value.id == sceneTime?."${it.value.name.minus(~/ on \d+/)}"?.id && it.value.name ==~ /.* on \d+$/)

This if as well as the following else and associated brackets need to be commented out. Then it works. You do end up with the default scenes, but that’s not a huge deal. It’s also possible to filter them out by name if it bothers you too much. That would be done in the same spot, just a simple name check there.

I just installed and everything was going perfect until no scenes appeared, i have pasted a bit of the log file not sure what part would help. Plus i’m not sure what the funny groups names are.

80f27002-a68e-4271-b4ff-a8692e14813d 11:46:50 PM: debug Its a scene

80f27002-a68e-4271-b4ff-a8692e14813d 11:46:50 PM: debug Its a scene
80f27002-a68e-4271-b4ff-a8692e14813d 11:46:50 PM: debug Its a scene
80f27002-a68e-4271-b4ff-a8692e14813d 11:46:50 PM: debug getChildDevices(false), children=10
80f27002-a68e-4271-b4ff-a8692e14813d 11:46:50 PM: debug Response Body: {“ULikZHX-vKJptLN”:{“name”:“Relax”,“lights”:[“1”,“2”,“3”],“owner”:“Q8p9DQBV0jzI33UMrwhuu7WBaawbx8LzFtRh47a6”,“recycle”:false,“locked”:false,“appdata”:{“version”:1,“data”:“VPv0B_r01_d01”},“picture”:"",“lastupdated”:“2016-11-17T13:55:16”,“version”:2},“atmPem7BMOiChCq”:{“name”:“Read”,“lights”:[“1”,“2”,“3”],“owner”:“Q8p9DQBV0jzI33UMrwhuu7WBaawbx8LzFtRh47a6”,“recycle”:false,“locked”:false,“appdata”:{“version”:1,“data”:“UnTWS_r01_d02”},“picture”:"",“lastupdated”:“2016-11-17T13:55:16”,“version”:2},“a1wyxSk2h2CSWf3”:{“name”:“Concentrate”,“lights”:[“1”,“2”,“3”],“owner”:“Q8p9DQBV0jzI33UMrwhuu7WBaawbx8LzFtRh47a6”,“recycle”:false,“locked”:false,“appdata”:{“version”:1,“data”:“wmoNk_r01_d03”},“picture”:"",“lastupdated”:“2016-11-17T13:55:16”,“version”:2},“eor9jfu0O3SFIjZ”:{“name”:“Energize”,“lights”:[“1”,“2”,“3”],“owner”:“Q8p9DQBV0jzI33UMrwhuu7WBaawbx8LzFtRh47a6”,“recycle”:false,“locked”:false,“appdata”:{“version”:1,“data”:“7DOHW_r01_d04”},“picture”:"",“lastupdated”:“2016-11-17T13:55:16”,“version”:2},"bDSSKcVqZLf1n6p…[TRUNCATED]
80f27002-a68e-4271-b4ff-a8692e14813d 11:46:50 PM: debug Its a scene

Uh… literally the two posts above yours.

lol, it was getting very late last night.

I will give that a go now, i wonder if that’s the same reason my Logitech Harmony cannot see scenes?

Worked a treat thanks kolosy

Glad to hear it.

Logitech scenes - you mean an integration between the Harmony home and Hue? Or something through ST? I have both of those, but haven’t looked to hook them together yet…

Question: Is there a way to install this without removing the original connect and or a way to remove the original connect without loosing the current lights in the database? I have lots of things setup using the original connect so it would basically require me to completely overhaul the entire system. Thx.

Any help with this error will be greatly appreciated.

error physicalgraph.app.exception.UnknownDeviceTypeException: Device type ‘Hue Bridge’ in namespace ‘smartthings’ not found. @ line 598

I received this error after installing ReConnect, connecting to the Hue bridge, selecting the Hue bulbs and selecting the Hue Groups. It happens when click Done with a red “An unexpected error occurred.” message

BTW it happens when if I don’t select any of the bulbs or Groups.

Line 598 is d = addChildDevice(“smartthings”, “Hue Bridge”, selectedHue, vbridge.value.hub)

You get this error if you didn’t install the DeviceTypes that are needed.

Thanks Arnoud, that sent me in the right direction.

For those with the same issue here is a bit more detail:

Login to https://graph.api.smartthings.com
Go to My Device Handlers section
Click on Create New Device Handler
Select From Template
Select Phillips Bridge then Create
Select Phillips Bulb then Create