Closed walthowd closed 6 years ago
Hi @walthowd the first error block is not severe and creates just logs, for the second please get the dev_switch branch. I had not looked into switches 2 weeks ago, and it seems there is an indent error. In the meantime I added switch support and for my switches its' working ok. The switch code now supports attribute reporting and polling of state.
you need to define a device config, when bellows can't detect the model from endpoint 1/cluster 0/attrib 4. For this case I added the template option: Eg the tradfri dimmable bulbs, they report themself as ZLL devices, but you need to talk ZHA to them. With this you have no change to get the manufacturer or model. Here you need to add the device config with the template. Where the template is a device specific python file. In the case of the Tradfri bulbs it just overrides the detected ZLL profile to a ZHA profil. With this the discovery identication is back on track. when the model is visible, device specific code is called to from templates/device_handlers, then you need no extra configuration entries. Can you send over the device information from bellows for your bulbs. That would be helpful.
Switching to dev_switch branch, I receive this error on Home Assistant startup and the component never fully loads to allow light control.
2018-01-22 19:17:16 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/asyncio/tasks.py", line 180, in _step result = coro.send(None) File "/Users/hass/.homeassistant/custom_components/zha_new.py", line 268, in async_device_initialized _custom_endpoint_init(endpoint,node_config,dev_func) UnboundLocalError: local variable '_custom_endpoint_init' referenced before assignment
I then tried manually assigning the default template, but same results:
zha_new:
usb_path: /dev/tty.GoControl_zigbee
database_path: /Users/hass/.homeassistant/zigbee.db
device_config:
"00:17:88:01:03:5d:32:c1":
template: default
"b0:ce:18:14:03:00:f1:7e":
template: default
Attached is the output from my bellows devices. I'm particularity looking at b0:ce:18:14:03:00:f1:7e which is an Sengeld Element Plus that should support color_temperature. I'm also chasing the three full Philips Hue bulbs (00:17:88:01:02:88:ce:3f, 00:17:88:01:02:88:d3:8c and 00:17:88:01:02:e8:01:14) which randomly lose the ability to set the color temperature via the Home Assistant front end.
I added better exception handling and added also debugging to the light component. you should not see the error anymore. The orginal code tries to get an attribute from the color control cluster. Based on the result it decides if it's an color bulb or a white-colortone bulb. Please update the dev_switch branch and try it again. Please have a look on the switch.zha_new logs You say, it works sometimes and sometimes not? Can you pin-point, when it fails? Maybe after a HA restart?
I pulled the latest from your master bellows branch and the latest dev_switch branch of zha-new.
Seeing multiple errors logged at startup, zha never fully loads and doesn't create any entities.
Home Assistant log is attached.
sorry, my badness. I forgot to push the changes to github. At least it should load now.
Loading and working now, still not seeing color temperature being configurable from the HA frontend at times for my Phillips Hue bulbs, but that has been an issue in the original bellows/zha component too. I can submit some info to track that separately.
Thank you!
@walthowd yes, please provide the debug logs for lights.zha_new and bellows for the initialization. thanks
Home Assistant Version: 0.60.1
Latest ha-zha new and latest of your fork of bellows. Trying to do a drop in replacement for the existing bellows and ZHA component as I am chasing an issue with color temperature not being controllable from the HA front end for Phillips LCT bulbs and trying to add support for Sengled Element Plus bulbs.
Do I need to specify a device_config for each bulb that's already in zigbee.db?
Config:
Multiple errors: