No white channel on RGBW controller 'TS0504B'
I just bought the same model of controller "TS0504B" but I do not understand how to control the white channel?
Originally posted by @rmickael62 in https://github.com/Koenkk/zigbee2mqtt/issues/6299#issuecomment-783249778
devices.js { fingerprint: [{modelID: 'TS0504B', manufacturerName: '_TZ3000_ukuvyhaa'}], model: 'TS0504B', vendor: 'TuYa', description: 'Zigbee smart mini led strip controller 5V/12V/24V RGBW', extend: preset.light_onoff_brightness_colorxy(), <= preset.light_onoff_brightness_colortemp_colorxy() ? meta: {applyRedFix: true}, }, small precision the led strip used with this controller is in RGBWW so it lacks "white_value". Any ideas ?
The Zigbee ZCL spec does not define anything like a white_value. Did you try with preset.light_onoff_brightness_colortemp_colorxy() does it work then?
Can you also share the data/database.db entry of this device?
preset.light_onoff_brightness_colortemp_colorxy() => does not work.
database.db : {"id":52,"type":"Router","ieeeAddr":"0x60a423fffee28dac","nwkAddr":60195,"manufId":4098,"manufName":"_TZ3000_ukuvyhaa","powerSource":"Mains (single phase)","modelId":"TS0504B","epList":[1,242],"endpoints":{"1":{"profId":260,"epId":1,"devId":269,"inClusterList":[0,3,4,5,6,4096,8,768],"outClusterList":[25,10],"clusters":{"genBasic":{"attributes":{"modelId":"TS0504B","manufacturerName":"_TZ3000_ukuvyhaa","powerSource":1,"zclVersion":3,"appVersion":66,"stackVersion":0,"hwVersion":1,"dateCode":""}},"lightingColorCtrl":{"attributes":{"colorCapabilities":25}}},"binds":[],"configuredReportings":[],"meta":{}},"242":{"profId":41440,"epId":242,"devId":97,"inClusterList":[],"outClusterList":[33],"clusters":{},"binds":[],"configuredReportings":[],"meta":{}}},"appVersion":66,"stackVersion":0,"hwVersion":1,"dateCode":"","zclVersion":3,"interviewCompleted":true,"meta":{"configured":2},"lastSeen":1614102988277}
Given that is only has 1 endpoint. It seems the white channel is controlled in some non standard way. You will need to sniff the traffic with the original gateway while controlling the white channel and post it here: https://www.zigbee2mqtt.io/how_tos/how_to_sniff_zigbee_traffic.html
I don't have an original gateway, is it possible with a sonoff zigbee bridge? knowing that the device is compatible with tuya and alexa.
I don't know if you can set it with a sonoff zigbee bridge, you can try.
Hi @rmickael62, I have the same problem. Have you been able to solve it?
Hi @jti989, I think that the white channel cannot be controlled directly in zigbee (obligation to use the button) I would use this module only for RGB.
Hopefully a solution can be found. Unfortunately, I can not control white either.
I spent some time with the controller and recognised that there are zigbee messages that may be useful for implementing this. When I first changed the color mode to white (coming from RGB) with the hardware button, there was this message:
Zigbee2MQTT:debug 2021-03-23 12:30:26: Received Zigbee message from '0x60a423fffe94d1d8', type 'attributeReport', cluster 'lightingColorCtrl', data '{"tuyaRgbMode":2}' from endpoint 1 with groupID 0
When changing colors afterwards there are messages like this:
Zigbee2MQTT:debug 2021-03-23 12:40:43: Received Zigbee message from '0x60a423fffe94d1d8', type 'raw', cluster 'lightingColorCtrl', data '{"data":[24,15,10,3,240,72,10,2,0,14,13,0,15,0,0,232,232],"type":"Buffer"}' from endpoint 1 with groupID 0
And when switching to white again the message is longer:
Zigbee2MQTT:debug 2021-03-23 12:40:51: Received Zigbee message from '0x60a423fffe94d1d8', type 'raw', cluster 'lightingColorCtrl', data '{"data":[24,17,10,3,240,72,18,4,3,70,70,120,240,232,232,0,0,70,70,120,192,232,10,0,0],"type":"Buffer"}' from endpoint 1 with groupID 0
I don't know how to decode these messages, but I have the feeling that the information we need is in it. Could we reopen this topic @Koenkk and @rmickael62 ?
I'm interested in fixing this issue. Thanks
Me too! Thank you
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days
Problem still exists :(
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days
Unfortunately it still does not work!
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days
Still not working!
I managed to get it to work with this code:
const definition = {
fingerprint: [{modelID: 'TS0504B', manufacturerName: '_TZ3000_ukuvyhaa'}],
model: 'TS0504B',
vendor: 'TuYa',
description: 'Zigbee RGBW light',
toZigbee: [tz.on_off, tz.tuya_led_control],
fromZigbee: [fz.on_off, fz.tuya_led_controller, fz.brightness, fz.ignore_basic_report],
exposes: [e.light_brightness_colortemp_colorhs([498, 500]).removeFeature('color_temp_startup')],
meta: {applyRedFix: true, enhancedHue: false},
};
Just set any value as color temperature and the controller deactivates the RGB output and activates the W output with the respective brightness set.
It's not the best solution but at least it works. Better than nothing
@MattiaFochesato
Thanks for this idea! But how to go back to RGB? I do not come back when I enter a color...
And I can't control brightness after this change...