Just thought I’d mention this in case anyone is having similar problems…
I’ve been experimenting with a Philips Hue smart button, with a view to using it to launch things other than lights (alarms, for example). Set up in the Philips app, it turned a local Hue light on and off successfully and it appeared in the HA integration, but I had a lot of trouble using it to trigger automations.
(The spotlights are not Hue devices - I’m just using them as a target for the automation.)
In practice the automation was not triggered when the button was pressed, though the appropriate Hue bulb turned on and off. I noticed too that the battery level sensor for the button was showing “?”.
Back in the Philips app I saw that I was still using the default name for the button. Changed it to something more sensible, reloaded the integration and suddenly the automation is working and battery shows 100%.
I’m sure somebody will understand why. It’s beyond me.
Go to Developer Tools > Events, enter “hue_event” in “Listening to” and click “Start Listening”. Perform a few short and long button presses and see what’s reported for each action.
There’s also this but I haven’t seen those exact values reported in the Events viewer.
I’m a technical guy, but am still pretty new to HA. That said, I think I may have a pretty large-ish setup already, and DO feel like I know my way around a bit already.
But in that context, I found this post and it’s responses to be a little confusing, and I’m still left not understanding how to integrate a Hue Smart button.
I am using ZHA for everything, and this is how the button is integrated into my HA (not through a Hue bridge).
I absolutely DO understand that the button creates an event, not a state.
I see above the advice and code that @123 has given about how to listen for the event, but no combination of me going the Developer Tools> Events and entering anything like this produces information for me.
Is there something I’m needing to code into my congfiguration.yaml or something before I’m able to use this?
Sorry… just really confused at the moment, but I’m pretty confident in my ability to keep up if someone can back up a couple of steps or reference something more.
Thank you!!
EDIT: OK! I got as far as figuring out that I was going to be listening for a ZHA event, vs. Hue event. (Duh). Here’s what ONE, short button press gives me. Now… I just need to figure out what to do with this!
EDIT Number 2: Ok… for anyone that comes looking for this answer from here on it, and didn’t ask questions out loud on a forum like I did, here’s the resolution! It works flawlessly with my ZHA integration of Hue Smart Buttons.