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

  1. for now, no. Next version will update groups and bulbs after scene

  2. setToGroup() accepts a single parameter. I could add setTo2Groups() / setTo3Groups() in future… But what I do now in your situation is create a group consisting of the bulbs of multiple rooms and then just call that group number.

Not sure what you mean. Please explain.

So as I mentioned in my previous post I have a Hue Tap, I like to be able to set a scene via the tap (how Hue normally works) but I’d also like an ST SmartApp know that event has happened.

So the scene change is triggered by Hue and not your App. I would expect that your app would need to have visibility of a scene action within Hue and then feed that back to the scene device type… that way there would be an event to subscribe to in ST?

Unfortunately, no.

The Hue Tap (as well as Philips’ other Hue switches and Hue sensors) works via Philips’ own zigbee-based protocols. Such events are handled exclusively within the Hue Hub. Currently, the Hue Hub doesn’t provide the option to “push” such events to a third-party system like SmartThings. So there is no way to subscribe to those events and the only way to have SmartThings update the status of the affected bulbs / groups is to “fetch” those devices’ status – which my app (and other Hue Connect smartapps) does periodically.

I bought a couple Hue Taps back in 2014, and was veeeerrrrrry disappointed when I discovered this.

OK, I can definitely wait for 1 to be implemented. But for 2) It would just
be nice if it could accept multiple parameters or have a different way of
calling multiple parameters. I am trying to do a lot with micro-location,
so a lot of my lights are “directional” ie if X sensor changes to active
AND Y sensor was active within the last minute then turn on the lights
ahead. So, almost every sensor turns on a different combination of 2 groups
(room youre in and room youre going to be in). It would be really nice if I
didn’t have to create 100 different groups consisting of two groups. Its
not the end of the world, but it would be a great addition.

Thanks again

Great thanks, unfortunately I has suspected that was the case… but thought that if anyone would know the answer it would be you! :slight_smile: Even if you could poll for the scene change and have some why of identifying when it took place you could work around that, but by the sounds of it you can only poll for the device individually, I was aware that you couldn’t directly integrate due ot the different protocols which is a real shame!

I’m not a massive fan of the Tap TBH, but the dimmer I really like, partly because you can wall mount but you can then remove from it’s surround as it’s magnetic and it looks and feels nice. I’m in the UK and basically we have no decent wall switches, pretty much the only affordable nice looking ones are ligwaverf, which isn’t directly compatible with ST either without IFTTT or a Pi… back to the drawing board I guess…

Thanks for taking the time to respond though!

1 Like

The real shame is that it’s not a protocol issue - it’s just that Philips refuses to allow it.

Updated the Hue B Scene DTH on Github. It now has the requested setTo2Groups( group1, group2) functionality.

1 Like

I am a total noob to this stuff. This is the first app I installed.

I followed the instructions, linked up GitHub and forked your code, installed and published to my apps. I see it in my MarketPlace > My Apps and try to run it, but when it asks me to push the button on my Hue Bridge to link, it says “I’m not authorized to to do that”. I’m probably missing something REALLY basic but what am I doing wrong?

EDIT: I found my issue, I had to load and publish the My Device Handlers, which I assume are your DTH that you mentioned in your post. Works now! :slight_smile: Thanks for your work!

Glad you got it up and running! Welcome!

1 Like

Morning Tony.

Firstly - Thank you!!! this is the first SmartApp I’ve used for Hue that I can get my scenes working, I had been using ReConnect but could never make it pull in scenes from the gen 1 app…

Thought I would list my lighting setup below to build a clear picture of what I’m installing with:

21 Hue lights - mix of Colour, White Ambiance, Bloom, Lightstrip and Lightstrip Plus.
Hue hub v2
ST hub v2

I’m using CoRE as the rules engine.

Physical control of the lighting is by way of 7 x Hue Tap and 4 x Hue Dimmer.
Also have 3 of the new hue motion sensors (which I have to say work rather well)

Other control inputs are Aeon Multisensor 6 and ST motion and contact sensors.

Installation of SmartApp and DTH all ok - I have not installed the DTH’s for LUX bulbs as we have none of those.
Discovery and adding of bulbs, scenes and groups all successful.

Experience so far:

1- As mentioned above - light states in ST app, I have a couple of core pistons that control WeMo switches, one in particular looks for the state of a hue bulb then switches on on/off a wemo switch connected to a none hue light - eg, “When Office Light 1 is on switch Office Wemo 1 On” and vice versa.

This works well if I switch on the light directly from the piston but if I trigger a scene push the update to ST means the Wemo switch will not fire for some time. Equally the main use of this scenario is when I push turn on “Office Light 1” using a Hue Dimmer Switch, again the update delay in the piston means the Wemo will not switch on/off.

I know you are working on the update frequency but just thought I would mention my particular usage setup.

2- Refresh, In order to solve the above I have a piston that does refresh - initially on all the lights but I found that it froze the ST hub for a bit - so I changed the piston to only refresh 1 light. To my surprise when this happens all of the lights get updated from the hue hub, however this then runs into the problem below.

3- IOS app crash. Since installation the IOS app crashes very frequently, Hue B Smart is the only recent edition to my smartapps/devices. If I refresh a the light devices the app crashes approx 50% of the time - same If I change a piston or if I edit the Hue B Smart setup to include or delete a device. Its not previously been happening and may not be related at all.

Restarting the app and all is fine again until one of the above - It’s something I can live with as it only happens when doing the above edit tasks - once a piston/setup is done I don’t have any crash issues when just running anything.

If there are any logs for the IOS device I can send over, if you can point me in the right direction to get them I shall do so.

As it’s a PITA to rebuild the lighting system for app changes I shall be sticking with your smartapp as it’s by far the best hue controller I’ve come across, anything I can do to help with debug or testing please let me know.

cheers (and apologies if all the above it a bit too much info!)
Matt

I was just about to write the exact same post of this one. I love the scenes and app and most of the time they work very well but…

When my hub does a refresh on lights status at minutes ending in 2 and 7 then during this time:

  1. Lights cannot be turned on or off during this period
  2. ST main app sometimes crashes, sometimes while I am actively using it, sometimes while the app is just open but not being actively used.

I think both of these issues are caused by the ST hub being hammered with requests every 5 minutes.

The main effects of this are:
a) If I happen to walk into a room at the time the hub is updating the lights don’t come on
b) creating/editing CoRE pistons is very laborious as if it takes > 5 minutes to do the edit in CORE then the hue polling kills the app and I have to start again loading the app, loading core, etc.

EDIT to give extra info:
iOS, 27 scenes, 11 groups, 30 lights.

Tino -

I sincerely doubt that my smartapp is causing your entire ST app to crash or cause such a delay in creating CoRE Pistons. I have about the same number of scenes, groups, and bulbs as you do and have never experienced anything like that (and haven’t heard anyone else having such severe problems).

Nonetheless, if you PM me a copy of the IDE logs of the smartapp when you experience either a crash and/or during the hub refresh periods, I would love to take a look at what’s going on for you.

Also let me know what version of the Hue Hub and ST Hub you have.

Thanks.

Hi Tony - not sure if this helps or not.

On refresh of the lights I receive the following in the IDE.

For the white ambiance bulbs:
8:15:00 AM: error java.lang.NullPointerException: Cannot invoke method multiply() on null object @ line 1469

For the Bloom and LightStrips
8:14:52 AM: 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 427

No errors on the colour bulbs or Lightstrip Plus.

On groups, when a group contains a white ambiance light I see the Cannot invoke method multiply() on null object @ line 1469 error. and when a group contains a lightstrip or bloom I see the Cannot resolve which method to invoke for [null] due to overlapping prototypes between: error.

Matt-

Could you send me the surrounding IDE log information? One log entry is
hard to understand in isolation.

But I can tell you that the Bloom is not supported as it contains multiple
(and individually addressable LEDs).

Thanks,
Tony

–Anthony Pastor

Also - Did you download the Hue Lux Group DTH?

I still think that the crashing and delays have absolutely nothing to do
with my app!

Hi Tony - I’ve PM’d you the IDE logs.

As for the app crashes you may well be correct, I’ve been reading a fair bit of chatter about the latest IOS OS updates and ST app crashing with it - so entirely possible that’s the cause.

I’ve not installed the Lux DTH’s - would you recommend I do so?

If the bloom is not supported am I best off removing it from my system?

cheers
matt

The Lux bulb DTH is for Philips bulbs without color capability. The Lux Group DTH is for a group containing at least one of those bulbs. I believe that the error you are getting is due to using the wrong DTH.

But your lightstrip should be working. I have an older lightstrip (I actually don’t know the difference between a lightstrip and a lightstrip plus). What is the model number of each?

I don’t have a bloom, so I am not going to be able to test for that. So I guess remove IT for now.

Hi Tony - adding DTH now.

Should I change the White Ambiance bulbs in the devices section to Lux bulbs?

The Lightstrip has Model number LST001 and s/w version 5.23.1.13452
The Plus has Model LST002 and s/w version 5.50.2.19052

The physical difference is the Plus has a seperate White LED along with a mixed colour LED’s.

The Plus strips can do colour temperature.