ZHA Binding

I’ve tried two ZigBee buttons and tried to bind them to a ZigBee bulb but it never seems to work. Is there something with binding that I’m missing?

I’ve tried the SNZB-01 and the ThirdReality Button. Has anyone gotten these to bind correctly? I also use the SkyConnect as my coordinator

When you say bind together… are you talking about how (for example) IKEA bulbs and buttons can be ‘bound’ together without the need for a hub ?

in Home assistant, you join your devices to the network by pairing with the coordinator, but there is no association at that point between say the button and the bulb. You’d need to create an automation to link the action of the button to whatever you wanted the bulb to do (say turn on or off).

Yes. I mean binding, for example, a sonoff button to an innr bulb so the button can control the bulb without going through the coordinator. I’ve paired the devices to the coordinator and written automations so when the zha event happens it turns on or off the lights but I wanted to make it so those lights can be controlled even if home assistant went down.

I dont think you can do that, the device can only be paired to one thing at a time, in this case its already ‘connected’ the coordinator.

I’m confused. There is actually a binding tab in the ZigBee device management interface. It says binding and then provides options to bind to a device and bind to a ZigBee group.

I think the documentation on ZHA even indicates that binding is possible.

“ZHA support for binding and unbinding. Binding is an action in Zigbee which defines relations between two Zigbee devices, specific endpoints, and cluster id. It provides a mechanism for attaching an endpoint on one Zigbee node to one or more endpoints on another Zigbee node or Zigbee group (a group of Zigbee devices).”

Yes you can. My Ikea bulb and Ikea button are ‘bound’, and I still can operate them through HA. But I can’t answer OP’s question, since I use Zigbee2MQTT

Side question. Did you start with zigbee2mqtt or migrate from zha to it. I’ve heard of a lot of success with zigbee2mqtt in binding and other areas and have considered migrating over and wondered if it’s worth it.

I started with Zigbee2MQTT when then CC2531/CC2530 was the only supported adapter, and ZHA did not support these yet. (beginning of 2019). Never saw the need to switch to ZHA.

You learn something new every day.

Am I right in understanding that this is a direct zigbee binding from device to device, so it bypasses Home Assistant ?

If HA is up, AND you have two devices bound, who ‘wins’ ? For example, if you directly bind a switch to (say) 4 bulbs, and for sake of example, HA has no automations based on that switch, what happens when you press the button and HA is running ?

Also, given my zigbee coordinator is running ZHA, which is intrinsically linked into HA, how might the zigbee network still even be up if HA is down ?

Very interested to learn more about this.

Nobody wins. If I press the button to on the light, or to increase brightness, it shows in HA, If I use HA to on the light, or to increase brightness, it just works.

This is kind of house the insteon pairing worked before. I could link the switches together and then link it all to home assistant. I haven’t figured out how to do it with ZigBee or zwave yet. I thought it would be as simple as going to binding but I do that and it flat out doesn’t work with zha.

I just tried another button and still can’t get it to bind. I grabbed zha toolkit and checked the bindings for each of the devices and nothing is there. I don’t think the binding feature is even functional in zha but now I’m wondering when it started failing

It appears there was an issue with Zigbee Binding on the v6.1 of HaOS and v6.2 came out last night to apparently fix that. I gave the generic steps a try and it works. So I can finally say i wasn’t doing anything wrong besides not reading the bug reports hahah

And its broken again with v7.2.

User error. My best guess is that the device was already bound and that is why it wasn’t working but i kept trying for 2 days and it finally worked.

Just resurrecting this thread.

Whats the use case for binding vs using automations ?

Could I bind (say) an ikea remote dimmer to a tuya bulb and would the tuya bulb understand the command to dim ? Or does this rely on both devices conforming properly to the zigbee spec ?

For me it’s that the lights work even when home assistant is down when you bind a switch or a button to a light then it sends the command to turn off or on or dim directly to the light without going through the hub.

I had recently run into migrating home assistant to a different device and it was down for 3 days and I’m that time I couldn’t turn off the lights. Lol.

Could you explain how you did that for those of us new to ZHA toolkit?

Also, could you identify in ZHA toolkit how many bindings a device can have. ZHA docs states it is device dependent and for some devices it’s only one. This seems important, as in that scenario if the device is bound to the ZHA coordinator it’s a waste of time trying to bind it to any other device!

I honestly do not remember how I got the zha toolkit to report how many bindings were there. I think there is a bind_get service but outside of that I can’t remember. I was able to bind the devices in ZHA addon within home assistant. You can click on manage devices and then bindings.

I was able to bind Philips Hue RWL022 dimmer switches and ROM001 buttons to lights and groups of lights without any problem. Didn’t need the ZHA tooklit. There’s a post about it here:

Don’t know if the process is similar for other manufacturer’s devices. As far as Hue goes, I believe it’s the RWL021 dimmer switch that can only bind to one device.