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

You must remove the other one. This is doing some nasty stuff. I will update the install section.

This is interesting… I only have 4 bulbs so hard to test, can you send me the logs when you got the error ? Was it working with the Official HueConnect? (because I didn’t change anything related to the bulbs AFAICR).

Yes, I had the same issue with Hue (Connect) as well. I have removed it and replaced with Hue (ReConnect). Also, I cannot seem to get any of the scene devices to push hue scene to lights although the device shows momentary push event occurred.

Log at time of momentary event: 86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:33 PM:

info Bridge response: [{β€œerror”:{β€œtype”:5,β€œaddress”:"/groups/0",β€œdescription”:β€œinvalid/missing parameters in body”}}]
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:33 PM: trace Parsing description
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:33 PM: debug Parsing β€˜index:0F, mac:00178810959A, ip:C0A80168, port:0050, requestId:4d1f14db-199d-4acc-97b6-19c1c5497266, headers:SFRUUC8xLjEgMjAwIE9LDQpDYWNoZS1Db250cm9sOiBuby1zdG9yZSwgbm8tY2FjaGUsIG11c3QtcmV2YWxpZGF0ZSwgcG9zdC1jaGVjaz0wLCBwcmUtY2hlY2s9MA0KUHJhZ21hOiBuby1jYWNoZQ0KRXhwaXJlczogTW9uLCAxIEF1ZyAyMDExIDA5OjAwOjAwIEdNVA0KQ29ubmVjdGlvbjogY2xvc2UNCkFjY2Vzcy1Db250cm9sLU1heC1BZ2U6IDM2MDANCkFjY2Vzcy1Db250cm9sLUFsbG93LU9yaWdpbjogKg0KQWNjZXNzLUNvbnRyb2wtQWxsb3ctQ3JlZGVudGlhbHM6IHRydWUNCkFjY2Vzcy1Db250cm9sLUFsbG93LU1ldGhvZHM6IFBPU1QsIEdFVCwgT1BUSU9OUywgUFVULCBERUxFVEUsIEhFQUQNCkFjY2Vzcy1Db250cm9sLUFsbG93LUhlYWRlcnM6IENvbnRlbnQtVHlwZQ0KQ29udGVudC10eXBlOiBhcHBsaWNhdGlvbi9qc29u, body:W3siZXJyb3IiOnsidHlwZSI6NSwiYWRkcmVzcyI6Ii9ncm91cHMvMCIsImRlc2NyaXB0aW9uIjoiaW52YWxpZC9taXNzaW5nIHBhcmFtZXRlcnMgaW4gYm9keSJ9fV0=’
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:31 PM: info Bridge response: [{β€œerror”:{β€œtype”:5,β€œaddress”:"/groups/0",β€œdescription”:β€œinvalid/missing parameters in body”}}]
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:31 PM: trace Parsing description
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:31 PM: debug Parsing β€˜index:0F, mac:00178810959A, ip:C0A80168, port:0050, requestId:6fabac13-dfd1-4dc8-831a-c437283af102, headers:SFRUUC8xLjEgMjAwIE9LDQpDYWNoZS1Db250cm9sOiBuby1zdG9yZSwgbm8tY2FjaGUsIG11c3QtcmV2YWxpZGF0ZSwgcG9zdC1jaGVjaz0wLCBwcmUtY2hlY2s9MA0KUHJhZ21hOiBuby1jYWNoZQ0KRXhwaXJlczogTW9uLCAxIEF1ZyAyMDExIDA5OjAwOjAwIEdNVA0KQ29ubmVjdGlvbjogY2xvc2UNCkFjY2Vzcy1Db250cm9sLU1heC1BZ2U6IDM2MDANCkFjY2Vzcy1Db250cm9sLUFsbG93LU9yaWdpbjogKg0KQWNjZXNzLUNvbnRyb2wtQWxsb3ctQ3JlZGVudGlhbHM6IHRydWUNCkFjY2Vzcy1Db250cm9sLUFsbG93LU1ldGhvZHM6IFBPU1QsIEdFVCwgT1BUSU9OUywgUFVULCBERUxFVEUsIEhFQUQNCkFjY2Vzcy1Db250cm9sLUFsbG93LUhlYWRlcnM6IENvbnRlbnQtVHlwZQ0KQ29udGVudC10eXBlOiBhcHBsaWNhdGlvbi9qc29u, body:W3siZXJyb3IiOnsidHlwZSI6NSwiYWRkcmVzcyI6Ii9ncm91cHMvMCIsImRlc2NyaXB0aW9uIjoiaW52YWxpZC9taXNzaW5nIHBhcmFtZXRlcnMgaW4gYm9keSJ9fV0=’
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:26 PM: info Bridge response: [{β€œerror”:{β€œtype”:5,β€œaddress”:"/groups/0",β€œdescription”:β€œinvalid/missing parameters in body”}}]
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:26 PM: trace Parsing description
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:26 PM: debug Parsing β€˜index:0F, mac:00178810959A, ip:C0A80168, port:0050, requestId:09cba05b-1883-4cdf-8d41-7da00b484da1, headers:SFRUUC8xLjEgMjAwIE9LDQpDYWNoZS1Db250cm9sOiBuby1zdG9yZSwgbm8tY2FjaGUsIG11c3QtcmV2YWxpZGF0ZSwgcG9zdC1jaGVjaz0wLCBwcmUtY2hlY2s9MA0KUHJhZ21hOiBuby1jYWNoZQ0KRXhwaXJlczogTW9uLCAxIEF1ZyAyMDExIDA5OjAwOjAwIEdNVA0KQ29ubmVjdGlvbjogY2xvc2UNCkFjY2Vzcy1Db250cm9sLU1heC1BZ2U6IDM2MDANCkFjY2Vzcy1Db250cm9sLUFsbG93LU9yaWdpbjogKg0KQWNjZXNzLUNvbnRyb2wtQWxsb3ctQ3JlZGVudGlhbHM6IHRydWUNCkFjY2Vzcy1Db250cm9sLUFsbG93LU1ldGhvZHM6IFBPU1QsIEdFVCwgT1BUSU9OUywgUFVULCBERUxFVEUsIEhFQUQNCkFjY2Vzcy1Db250cm9sLUFsbG93LUhlYWRlcnM6IENvbnRlbnQtVHlwZQ0KQ29udGVudC10eXBlOiBhcHBsaWNhdGlvbi9qc29u, body:W3siZXJyb3IiOnsidHlwZSI6NSwiYWRkcmVzcyI6Ii9ncm91cHMvMCIsImRlc2NyaXB0aW9uIjoiaW52YWxpZC9taXNzaW5nIHBhcmFtZXRlcnMgaW4gYm9keSJ9fV0=’
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:23 PM: info Bridge response: [{β€œerror”:{β€œtype”:5,β€œaddress”:"/groups/0",β€œdescription”:β€œinvalid/missing parameters in body”}}]
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:23 PM: trace Parsing description
86bf792a-01b4-46b3-b427-3d1742f34d66 1:52:23 PM: debug Parsing β€˜index:0F, mac:00178810959A, ip:C0A80168, port:0050, requestId:5431988c-d7c4-4e3d-85a9-39aeacd32d3a, headers:SFRUUC8xLjEgMjAwIE9LDQpDYWNoZS1Db250cm9sOiBuby1zdG9yZSwgbm8tY2FjaGUsIG11c3QtcmV2YWxpZGF0ZSwgcG9zdC1jaGVjaz0wLCBwcmUtY2hlY2s9MA0KUHJhZ21hOiBuby1jYWNoZQ0KRXhwaXJlczogTW9uLCAxIEF1ZyAyMDExIDA5OjAwOjAwIEdNVA0KQ29ubmVjdGlvbjogY2xvc2UNCkFjY2Vzcy1Db250cm9sLU1heC1BZ2U6IDM2MDANCkFjY2Vzcy1Db250cm9sLUFsbG93LU9yaWdpbjogKg0KQWNjZXNzLUNvbnRyb2wtQWxsb3ctQ3JlZGVudGlhbHM6IHRydWUNCkFjY2Vzcy1Db250cm9sLUFsbG93LU1ldGhvZHM6IFBPU1QsIEdFVCwgT1BUSU9OUywgUFVULCBERUxFVEUsIEhFQUQNCkFjY2Vzcy1Db250cm9sLUFsbG93LUhlYWRlcnM6IENvbnRlbnQtVHlwZQ0KQ29udGVudC10eXBlOiBhcHBsaWNhdGlvbi9qc29u, body:W3siZXJyb3IiOnsidHlwZSI6NSwiYWRkcmVzcyI6Ii9ncm91cHMvMCIsImRlc2NyaXB0aW9uIjoiaW52YWxpZC9taXNzaW5nIHBhcmFtZXRlcnMgaW4gYm9keSJ9fV0=’

For completeness, following is my β€œScene Object” on the hue bridge:

{
β€œDusk”: {
β€œname”: β€œDusk”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ34”,
β€œ35”,
β€œ36”,
β€œ37”,
β€œ38”,
β€œ39”,
β€œ43”,
β€œ44”
],
β€œactive”: true
},
β€œ6b6f8fcd6-on-0”: {
β€œname”: β€œPencils on 0”,
β€œlights”: [
β€œ3”,
β€œ12”,
β€œ21”
],
β€œactive”: true
},
β€œ073bedc16-on-0”: {
β€œname”: β€œPencils on 0”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ34”,
β€œ35”,
β€œ36”
],
β€œactive”: true
},
β€œbe784eb03-on-0”: {
β€œname”: β€œKathy on 0”,
β€œlights”: [
β€œ3”,
β€œ12”,
β€œ21”
],
β€œactive”: true
},
β€œ07e89cf8e-on-0”: {
β€œname”: β€œKathy on 0”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ34”,
β€œ35”,
β€œ36”
],
β€œactive”: true
},
β€œNight”: {
β€œname”: β€œNight”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ34”,
β€œ35”,
β€œ36”,
β€œ37”,
β€œ38”,
β€œ39”,
β€œ43”,
β€œ44”
],
β€œactive”: true
},
β€œLate”: {
β€œname”: β€œLate”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ34”,
β€œ35”,
β€œ36”,
β€œ37”,
β€œ38”,
β€œ39”,
β€œ43”,
β€œ44”
],
β€œactive”: true
},
β€œEvening”: {
β€œname”: β€œEvening”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ34”,
β€œ35”,
β€œ36”,
β€œ37”,
β€œ38”,
β€œ39”,
β€œ43”,
β€œ44”
],
β€œactive”: true
},
β€œGoodnight”: {
β€œname”: β€œGoodnight”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ34”,
β€œ35”,
β€œ36”,
β€œ37”,
β€œ38”,
β€œ39”,
β€œ43”,
β€œ44”
],
β€œactive”: true
},
β€œNetflix”: {
β€œname”: β€œNetflix”,
β€œlights”: [
β€œ2”,
β€œ10”,
β€œ12”,
β€œ13”,
β€œ29”,
β€œ37”,
β€œ38”
],
β€œactive”: true
},
β€œ316435f31-on-0”: {
β€œname”: β€œReading on 0”,
β€œlights”: [
β€œ2”,
β€œ3”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ29”,
β€œ30”
],
β€œactive”: true
},
β€œecb3c0d42-on-0”: {
β€œname”: β€œVarulv on 0”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ43”,
β€œ44”
],
β€œactive”: true
},
β€œeabda7d84-on-0”: {
β€œname”: β€œVarulv on 0”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ43”,
β€œ44”
],
β€œactive”: true
},
β€œ9f0386d6f-on-0”: {
β€œname”: β€œReading on 0”,
β€œlights”: [
β€œ1”,
β€œ2”,
β€œ3”,
β€œ4”,
β€œ5”,
β€œ6”,
β€œ7”,
β€œ8”,
β€œ9”,
β€œ10”,
β€œ11”,
β€œ12”,
β€œ13”,
β€œ14”,
β€œ15”,
β€œ16”,
β€œ17”,
β€œ18”,
β€œ19”,
β€œ20”,
β€œ21”,
β€œ22”,
β€œ23”,
β€œ24”,
β€œ25”,
β€œ26”,
β€œ27”,
β€œ28”,
β€œ29”,
β€œ30”,
β€œ43”,
β€œ44”
],
β€œactive”: true
}
}

First something get wrong here, you should not have null next to your scene name.

I will need:

  • The logs when you launch the smartApp and it starts refreshing bulb and scenes.
  • The content of the smartApp (My Location, List SmartApps, Click on Hue connect and capture the entire pop over).
  • Devices, click on one of the Scene created as device and copy the entire page as well.

Please paste the logs in a gist.

I need the error you got (in a gist) when trying to install more than 20 bulbs at the same time.

I’m attempting to reset my hub. I want to rule out these problems. I cannot even reset my hub through the IDE or STM app. Something went really wrong, not certain what the reason…

I tried the app… it did not work.

Maybe it’s a coincidence, but the post update problems that have been plaguing a lot of people started doing the same to me as soon as this was installed.

Without logs I can’t tell works fine for me and others. Thanks to provide feedback with logs.

It’s a coincidence, I didn’t get a chance to install this, but my problems started yesterday. Maybe works backwards for me and after I install this my other problems go away :wink:

2 Likes

What kind of issue did you have? That’s funny…

Major zigbee issues with my entire mesh…

It was a joke… I know this app had nothing to do with it…

I can’t wait until the problems are fixed so I can install this app and use it like it’s meant to be.

2 Likes

This is too cool! Everything worked smoothly here. And being able to add the scenes in routines is double awesome! Thanks again…

3 Likes

Works really good.

How can I add new scenes? If I add a scene in the Hue App, it doesnt show up in the re-connect search and find area

1 Like

When you add a scene on your app, be sure to trigger it one or two times (this will push the scene to the hue bridge). Then it should appear. Beware, you can have duplicate of scene due to HUE Bridge limitation with scenes.

Can you elaborate on this?

Read this:

https://github.com/CyrilPeponnet/smartthings/tree/master/smartapp/HueConnect#important-notes

1 Like

NOW WORKING FOR ME! The object β€œit.value.lights” is null on my hub and it was not being mapped correctly; therefore, I added an additional condition check in code. The following code revision beginning at line 254 fixed this issue for me:

Map scenesDiscovered() {
def scenes = getHueScenes()
def scenemap = [:]
if (scenes instanceof java.util.Map) {
scenes.each {
def value = null
if (!it.value.lights){
value = β€œ${it.value.name.minus(~/ on \d+/)} Scene”
} else {
value = β€œ${it.value.name.minus(~/ on \d+/)} ${it.value.lights}”
}
log.debug it.value // See if lights value exists in map
def key = app.id +"/"+ it.value.id
scenemap["${key}"] = value
}
} else { //backwards compatable
scenes.each {
def value = β€œ${it.name}β€œ
def key = app.id +”/”+ it.id
scenemap["${key}"] = value
}
}
return scenemap
}

EDIT: I wonder if the number of lights displayed in the scene selection dialog is causing a problem? All of my scenes have in excess of 25-30 lights associated with each scene.

This code fixed the issue for me, and I am very happy with the results!

Thanks for the great addition to this app!!!

1 Like

This is really weird, could you so something for me?

curl "http://<IP_OF_YOUR_HUB>/api/<USERNAME>/scenes"

An replace:

PS: if you don’t have curl just pour the URL β€œhttp://<IP_OF_YOUR_HUB>/api//scenes” in your browser and paste me the result in a gist (https://gist.github.com) and give me the link to it. I’d really to understand what is going on.