SmartThings Community

[UPDATED 4/19/17] Hue B Smart (Smart and FAST Hue Lighting)

hue
smartapp_lighting
dth_lighting
scenes
groups

(Daniel McIvor) #588

Okay, thank you. I was using the infofiend github, I will change to the tmleafs and take from there.


(Joe) #589

I tried to use setToGroup(7) and the Energize scene. when group ID 7 (Kitchen) was triggered by motion it actually tuned on group 12. I assume you setToGroup the group ID and then push the momentary button energize.

If that’s correct, what am I doing wrong?


(Justin) #590

So I have an issue with the app (bug). When I try to add an additional light I get past the screen where it finds my linked bridge, but then the next screen simply tries to detect all the lights and scenes (which it has done before) and nothing happens?

The wheel appears as if it is working, but nothing is detected after about 20 minutes. Anyone ever see this before?


(Hendre) #591

I had the same issue. @tmleafs was very kind and spent a substantial amount of time to determine the cause of the problem. I even removed the app and reinstalled (a major hassle, because all lights have to be re-added to your webCoRE pistons). I managed to do one discovery after the reinstall, but after that, the old issue returned. I had to revert to the native Philips Hue app. :disappointed:


(www.smartukhome.co.uk) #592

Are you using my fork? Update all DH and App to this code https://github.com/tmleafs/Hue_B_Smart if not


(Brandt) #593

I am having the same issue. I updated the app and DH from your Github, still no dice. Any other suggestions?

Here are some of the logs, including the errors:

b8d0cc57-4628-404b-8566-9eb06b00ed88 6:49:03 PM: error groovy.json.JsonException: Expected a value on line: 1, column: 22125.
But got an unterminated object. @ line 270
b8d0cc57-4628-404b-8566-9eb06b00ed88 6:48:59 PM: error groovy.json.JsonException: Expected a String key on line: 1, column: 10861.
5edae44f-da9b-4d43-874b-9776020978c1 6:48:28 PM: error java.lang.NullPointerException: Cannot get property ‘value’ on null object @ line 58
5edae44f-da9b-4d43-874b-9776020978c1 6:48:28 PM: debug Manage Bridge null
5edae44f-da9b-4d43-874b-9776020978c1 6:48:28 PM: error java.lang.NullPointerException: Cannot get property ‘value’ on null object @ line 58
5edae44f-da9b-4d43-874b-9776020978c1 6:48:28 PM: debug Manage Bridge null
5edae44f-da9b-4d43-874b-9776020978c1 6:48:28 PM: error java.lang.NullPointerException: Cannot get property ‘value’ on null object @ line 58
5edae44f-da9b-4d43-874b-9776020978c1 6:48:28 PM: debug Manage Bridge null
5edae44f-da9b-4d43-874b-9776020978c1 6:48:27 PM: debug Bridges Linked MAC 0017882BF09A
5edae44f-da9b-4d43-874b-9776020978c1 6:48:27 PM: debug Bridges Linked IP 192.168.86.49
1ad61bdf-d1f1-4fa3-ab65-2f6a6addfcbe 6:48:06 PM: error groovy.lang.GroovyRuntimeException: Ambiguous method overloading for method java.lang.Integer#div.
Cannot resolve which method to invoke for [null] due to overlapping prototypes between:
[class java.lang.Character]
[class java.lang.Number] @ line 631
5edae44f-da9b-4d43-874b-9776020978c1 6:48:04 PM: debug Manage Bridge uuid:2f402f80-da50-11e1-9b23-0017882bf09a={schedules={3={id=3, groupId=16, status=disabled, sceneId=null, name=Dimmer Switch 15 Reset, type=schedule}, 2={id=2, groupId=5, status=disabled, sceneId=null, name=Dimmer Switch 4 Reset, type=schedule}, 1={id=1, groupId=3, status=disabled, sceneId=null, name=Dimmer Switch 2 Reset, type=schedule}}, ssdpUSN=uuid:2f402f80-da50-11e1-9b23-0017882bf09a, itemsDiscovered=false, networkAddress=C0A85631, ssdpNTS=null, serialNumber=0017882bf09a, bulbs={3={id=3, name=Hallway Light Mid, state={bri=1, effect=none, sat=143, hue=14929, alert=none, reachable=true, on=false, colormode=xy, ct=366, xy=[0.4589, 0.4103]}, type=Extended color light}, 2={id=2, name=Hallway Light Far, state={bri=1, effect=none, sat=143, hue=14929, alert=none, reachable=true, on=false, colormode=xy, ct=366, xy=[0.4589, 0.4103]}, type=Extended color light}, 1={id=1, name=Hallway Light Door, state={bri=1, effect=none, sat=143, hue=14929, alert=none, reachable=true, on=false, colormode=xy, ct=366, xy=[0.4589, 0.4103]}, type=Extended color light}, 7={id=7, name=Master Bathroom 1, state={bri=254, effect=none, sat=251, hue=10778, alert=none, reachable=true, on=true, colormode=xy, ct=500, xy=[0.5609, 0.4042]}, type=Extended color light}, 6={id=6, name=Office Left, state={bri=0, effect=none, sat=251, hue=10778, alert=none, reachable=false, on=false, colormode=xy, ct=367, xy=[0.5610, 0.4042]}, type=Extended color light}, 5={id=5, name=Office Right, state={bri=0, effect=none, sat=251, hue=10778, alert=none, reachable=false, on=false, colormode=xy, ct=367, xy=[0.5610, 0.4042]}, type=Extended color light}, 4={id=4, name=Bloom, state={bri=1, effect=none, sat=0, hue=0, alert=none, reachable=true, on=false, colormode=xy, xy=[0.4350, 0.4050]}, type=Color light}, 8={id=8, name=Master Bathroom 2, state={bri=254, effect=none, sat=251, hue=10778, alert=none, reachable=true, on=true, colormode=xy, ct=500, xy=[0.5609, 0.4042]}, type=Extended color light}}, mac=0017882BF09A, deviceAddress=0050, hub=306765ce-b4e5-4780-8ec2…[TRUNCATED]
5edae44f-da9b-4d43-874b-9776020978c1 6:48:14 PM: debug Groups = [3:[lights:[4], id:3, action:[bri:254, effect:none, sat:254, hue:38727, alert:select, on:true, colormode:xy, xy:[0.1552, 0.2657]], label:Living room, any_on:true, type:Room, all_on:true], 2:[lights:[5, 6], id:2, action:[bri:254, effect:none, sat:140, hue:14956, alert:none, on:true, colormode:ct, ct:366, xy:[0.4571, 0.4097]], label:Office, any_on:true, type:Room, all_on:true], 1:[lights:[1, 2, 3], id:1, action:[bri:84, effect:none, sat:143, hue:14925, alert:none, on:false, colormode:xy, ct:366, xy:[0.4589, 0.4103]], label:Hallway Hue, any_on:false, type:Room, all_on:false], 5:[lights:[11, 10, 9], id:5, action:[bri:254, effect:none, sat:140, hue:8418, alert:select, on:true, colormode:ct, ct:366, xy:[0.4573, 0.4100]], label:Kitchen, any_on:true, type:Room, all_on:true], 4:[lights:[7, 8], id:4, action:[bri:203, effect:none, sat:141, hue:14957, alert:none, on:false, colormode:xy, ct:366, xy:[0.4576, 0.4099]], label:Bathroom Shower, any_on:false, type:Room, all_on:false]]
5edae44f-da9b-4d43-874b-9776020978c1 6:48:09 PM: error java.lang.NullPointerException: Cannot get property ‘lights’ on null object @ line 1263


(Brandt) #594

Diving further into the logs, the error I see the most seems to be attached to my Bloom. I wonder if that’s the issue. Do you happen to have one to test with?


(Brandt) #595

Deleting the Bloom light from my existing devices cleared that error. Now I’m just left with the other error. It seems to be present for all of the rooms and scenes that it’s pulling through. The actual bulbs themselves don’t seem to have the error. Happy to DM you more logs if needed.


(Brandt) #596

Ok, I edited your code and now have it working. I removed bits from 4 lines:

Starting with Line 1254:
if (it.deviceNetworkId.contains(“SCENE”)) {
log.trace “it.deviceNetworkId contains SCENE = ${it.deviceNetworkId}”

			log.trace "contains SCENE / DNI = ${it.deviceNetworkId}"
	        def sceneId = it.deviceNetworkId.split("/")[1] - "SCENE"
    	    log.debug "sceneId = ${sceneId}"     
            def sceneFromBridge = bridge.value.scenes[sceneId]
            log.trace "sceneFromBridge = ${sceneFromBridge}"
            def sceneLights = []
            sceneLights = sceneFromBridge
            def scenelightStates = sceneFromBridge
            log.trace "bridge.value.scenes[${sceneId}].lights = ${sceneLights}"                    
			log.trace "bridge.value.scenes[${sceneId}].lightStates = ${scenelightStates}"                    

        	if (bridge.value.scenes[sceneId]) {	
				it.updateStatus("scene", "lights", bridge.value.scenes[sceneId])
            }
            if (scenelightStates) {	
				it.updateStatus("scene", "lightStates", scenelightStates)
			//	it.updateStatus("scene", "schedule", "off")                    
            }
    	}

Removed the .lights and .lightStates from lines 1263, 1264, 1268, 1269.


#597

Hi all,

I have just installed Hue B Smart and having some issue. I have added and published all of the relevant and device handlers. When I try to add I get some errors messages…

edit
*logs deleted

The message just repeats until the smart things app becomes unresponsive and crashes.

I have tried to factory reset the hue bridge without any luck.


(www.smartukhome.co.uk) #598

Are you using the latest code from here https://github.com/tmleafs/Hue_B_Smart the original code no longer works


#599

thanks! That helped!


(Ahmed ElSerafy) #600

Was anyone able to activate hue effects? such as the candle effect?

i want to be able to activate that effect using alexa or google home


(Ahmed ElSerafy) #601

guys i can’t seem to have it work…

i installed the smartapp, published and authorized it
and installed all handlers and published them
i uninstalled the hue connect app
but i cannot seem to be able to remove the hue bridge and devices from My Devices at all…
the delete action is done but they are not removed, and when i go to the hue b smartapp, keeps telling me searching for hubs and nothing found…

whats wrong here?


(Ahmed ElSerafy) #602

ok so i factory reset my hub, now the hue hub do not exist, tried settings up hue b app asap, still wont find the bridge…


(www.smartukhome.co.uk) #603

Are you using the latest code from here https://github.com/tmleafs/Hue_B_Smart the original code no longer works


(Ahmed ElSerafy) #604

yes, using that one


#605

I am trying to install this, and have added the DTH and SmartApps. I’ve deleted the bridge from the list of devices from my previous ST Hue Connect installation. There is no mention of Hue in my devices list of the SmartApp list (except the Hue B Smart app)

I can’t get the bridge to connect. Can anyone help? When I choose the bridge from the list and it says “please press the link button on your Hue bridge” and I do that, nothing happens. It just sits there doing nothing forever.

There is no issue with the bridge, as I can connect it to my Philips Hue app doing the same process, or I can add it to ST normally via the “add things” route.

I’ve seen a few people mention this in this thread but haven’t seen a solution yet. Anyone any ideas?


#606

update on this… I used TMLeafs version of the SmartApp and it worked fine. Note sure why!


#607

The original link in the OP thread no longer works, have to use TMLeafs. Really should start a new thread lol.