Hi all,
I think I've hit a snag and would appreciate some tips if someone could? It's been quite a mission just to get this far, I'm not very experienced in linux and even getting a machine up and running wasn't much fun.
I've taken two " 'Nue' 2 gang smart switches " off the supplied 'Nue' hub, and believe I have updated the 'devices.js' appropriately as they are being detected (copy of terminal below). Here's the model info lines from both entries in the 'devices' file:
zigbeeModel: ['FB56+ZSW1HKJ2.5']
and
zigbeeModel: ['FB56+ZSW1HKJ1.7']
Funnily enough I think these are the same model 2 switch devices.. Perhaps one is a later revision? Regardless, this is the two switch model. I am yet to test on the 1 switch, 3 switch, dimmer and also the 1 and four button 'scene' switches I have just installed. PRODUCT LINK
Once the 'devices.js' file is updated, and zigbee2mqtt is restarted, I'm struggling to see any immediate messages when the switches are turned on and off - there doesn't seem to be anything coming through, and no sort of pattern reflecting how I've switched them on/off.
Where should I go next?
I don't know if this is helpful or not, but others seem to have been attaching these switches to the SmartThigns hub, via a similar detection method which is supplied by the distributor - would this be useful? LINK TO PDF
Thanks!
Can you:
data/database.db (there are probably multiple)devices.js and check if you see any No converter available messages when pressing one of the buttons on the switch: // Nue
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 1);
execute(device, [(cb) => device.bind('genOnOff', coordinator, cb)], callback);
},
},
Thanks @Koenkk
I will try this tonight and let you know how I get on, and will gather all the other model details I can for the other devices
@Koenkk ,
This is the database.db contents. Below I will post the shepherd results, but there were not any "no converter available" messages. I hope this helps and appreciate your time.
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1530775671,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"Iir7FWKHwlHAGayt"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530775707,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
{"$$indexCreated":{"fieldName":"id","unique":true,"sparse":false}}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1530777270,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"Iir7FWKHwlHAGayt"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"offline","joinTime":null,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530777271,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530777271,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScene{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1530775671,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"Iir7FWKHwlHAGayt"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530775707,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
{"$$indexCreated":{"fieldName":"id","unique":true,"sparse":false}}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1530777270,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"Iir7FWKHwlHAGayt"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"offline","joinTime":null,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530777271,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":1772,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530777271,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1371668480,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
s":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1371668480,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"QvXnFnosVrO4lSis"}
SHEPHERD DUMP:
(I have tried pairing, keeping pairing alive, and also switch presses during this dump but no response was noted to switches again)
Thanks, can you check with this code:
// Nue
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
execute(ep16, [(cb) => ep16.bind('genOnOff', coordinator, cb)], () => {
const ep17 = shepherd.find(ieeeAddr, 17);
execute(ep17, [(cb) => ep17.bind('genOnOff', coordinator, cb)], callback);
});
},
},
Thanks @Koenkk again for your help.
I've tried the new code, debug below. I still cannot detect any messages coming through with state changes from the switch. Is there something else I should be doing?
For info, I am running the dongle on a laptop with Debian, which is connecting back to the Hass.io MQTT server on my Pi okay.
Here's the latest log:
DATABASE.db
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1530839641,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"Ga9UJCSjxYwJ7w4y"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":41819,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530839681,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1220411392,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"oefxCQ8kiRfFmtbx"}
{"$$indexCreated":{"fieldName":"id","unique":true,"sparse":false}}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1530840127,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"Ga9UJCSjxYwJ7w4y"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":41819,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"offline","joinTime":null,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1220411392,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"oefxCQ8kiRfFmtbx"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":41819,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530840127,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1220411392,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"oefxCQ8kiRfFmtbx"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":41819,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1530840127,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1455685632,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}}},"_id":"oefxCQ8kiRfFmtbx"}
Can you try with this code:
// Nue
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const ep17 = shepherd.find(ieeeAddr, 17);
const actions = [
(cb) => ep16.bind('genOnOff', coordinator, cb),
(cb) => ep17.bind('genOnOff', coordinator, cb),
(cb) => ep16.report('genOnOff', 'onOff', 0, 1000, 0, cb),
(cb) => ep17.report('genOnOff', 'onOff', 0, 1000, 0, cb),
];
execute(ep16, actions, callback);
},
},
Dump below (just Shepherd in debug, let me know if you need all debugged). Still no movement when switches triggered, though the board itself looks like it is probably universal between 1, 2 and 3 gang models, this one is just missing the resistors and switches in the other position (e.g. this 2 gang has positions 1 and 3 populated). Thanks @Koenkk
Can you try with:
// Nue
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const ep17 = shepherd.find(ieeeAddr, 17);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 10, repChange: 0};
const actions = [
(cb) => ep16.bind('genOnOff', coordinator, cb),
(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
(cb) => ep17.bind('genOnOff', coordinator, cb),
(cb) => ep17.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(ep16, actions, callback);
},
},
Hi @Koenkk , I have tried the new code, below is a debug log. Again I did not see any new messages when cycling the switches, and I also have a MQTT sniffer subscribed to the topic in case something was missed, but no luck. Could it be something I'm doing wrong? Thanks for you continuing efforts in helping! Much appreciated.
Strange that still nothing is reported.
In the meantime somebody got a different Nue model working: https://github.com/Koenkk/zigbee-shepherd-converters/pull/29#issuecomment-403803514
Hi @Koenkk ,
I haven't given up... yet! But I'm getting close I'm afraid, as this is all a bit beyond my skill level getting this far. I would really like this to work however as a lot of my plans for the smart side of our renovation rely on this, and I mistakenly thought this would be easy (hah!). I figured that if Alexa can do it then I could too!
I'm wondering though if this will be of benefit:
The SmartThings guys seem to have most of this figured out for HomeAssistant/MQTT and utilising the Smart Things hub - I'm just hoping that the device handlers for that hub may in fact be ported over to Zigbee2MQTT easily in this case?
As always, your help and great interface is very much appreciated!
Could you try the following code? According to the smartthings docs these are the commands that are executed in the configure method:
// Nue
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 10, repChange: 0};
const actions = [
(cb) => ep16.read('genOnOff', 'onOff', cb),
(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(ep16, actions, callback);
},
},
Hi @Koenkk , sorry for the delay in trying this, and thanks again for continuing to help. I decided to try reflashing the firmware on the CC2531 first to see if that made a difference (I'm currently using your latest with the large buffer - let me know if that's a bad idea!)
I have used the above code you provided for the devices.js file.
The good news is that I've noticed some new lines in the log - but at this time cycling the switches does not result in immediate messages, however I have seen them appear once seemingly out of the blue:
Log.txt file:
2018-08-16T11:47:31.668Z - debug: Using zigbee-shepherd with settings: '{"net":{"panId":6754,"channelList":[11]},"dbPath":"/opt/zigbee2mqtt/data/database.db","sp":{"baudrate":115200,"rtscts":true}}'
2018-08-16T11:47:31.690Z - info: Starting zigbee2mqtt version 0.1.2 (commit #7dd1c75)
2018-08-16T11:47:31.690Z - info: Starting zigbee-shepherd
2018-08-16T11:47:32.079Z - info: zigbee-shepherd started
2018-08-16T11:47:32.080Z - debug: zigbee-shepherd info: {"enabled":true,"net":{"state":"Coordinator","channel":11,"panId":"0x1a62","extPanId":"0xdddddddddddddddd","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0},"firmware":{"transportrev":2,"product":0,"version":"2.6.3","revision":20180815},"startTime":1534420052,"joinTimeLeft":0}
2018-08-16T11:47:32.082Z - info: Currently 1 devices are joined:
2018-08-16T11:47:32.082Z - info: 0x00124b0014afe1fb (0x00124b0014afe1fb): TODO - Nue Smart light switch - 2 gang (Router)
2018-08-16T11:47:32.084Z - warn: `permit_join` set to `true` in configuration.yaml.
2018-08-16T11:47:32.084Z - warn: Allowing new devices to join.
2018-08-16T11:47:32.085Z - warn: Set `permit_join` to `false` once you joined all devices.
2018-08-16T11:47:32.085Z - info: Zigbee: allowing new devices to join.
2018-08-16T11:47:32.086Z - info: Connecting to MQTT server at mqtt://192.168.0.101
2018-08-16T11:47:32.144Z - info: zigbee-shepherd ready
2018-08-16T11:47:32.151Z - info: Connected to MQTT server
2018-08-16T11:47:32.151Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/state', payload: 'online'
**2018-08-16T11:47:32.447Z - debug: Recieved zigbee message with data {"cid":"genOnOff","data":{"onOff":1}}
2018-08-16T11:47:32.447Z - warn: No converter available for 'TODO' with cid 'genOnOff', type 'devChange' and data '{"cid":"genOnOff","data":{"onOff":1}}'**
2018-08-16T11:47:32.447Z - warn: Please see: https://github.com/Koenkk/zigbee2mqtt/wiki/How-to-support-new-devices.
2018-08-16T11:47:32.810Z - info: Succesfully configured 0x00124b0014afe1fb
2018-08-16T11:48:02.426Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:02.483Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:02.538Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:02.654Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:02.867Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:02.922Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:02.980Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:03.096Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:03.102Z - debug: Recieved zigbee message with data "0x00124b0014afe1fb"
2018-08-16T11:48:03.103Z - info: Device incoming...
2018-08-16T11:48:03.104Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"device incoming"}'
2018-08-16T11:48:03.106Z - debug: Recieved zigbee message with data "online"
2018-08-16T11:48:32.098Z - debug: Check online 0x00124b0014afe1fb
2018-08-16T11:49:32.113Z - debug: Check online 0x00124b0014afe1fb
2018-08-16T11:50:32.127Z - debug: Check online 0x00124b0014afe1fb
2018-08-16T11:51:32.141Z - debug: Check online 0x00124b0014afe1fb
2018-08-16T11:52:32.154Z - debug: Check online 0x00124b0014afe1fb
2018-08-16T11:53:32.169Z - debug: Check online 0x00124b0014afe1fb
2018-08-16T11:54:32.181Z - debug: Check online 0x00124b0014afe1fb
2018-08-16T11:55:32.194Z - debug: Check online 0x00124b0014afe1fb
This is a segment from the debug terminal:
2018-8-16 11:47:32 INFO zigbee-shepherd started
2018-8-16 11:47:32 DEBUG zigbee-shepherd info: {"enabled":true,"net":{"state":"Coordinator","channel":11,"panId":"0x1a62","extPanId":"0xdddddddddddddddd","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0},"firmware":{"transportrev":2,"product":0,"version":"2.6.3","revision":20180815},"startTime":1534420052,"joinTimeLeft":0}
2018-8-16 11:47:32 INFO Currently 1 devices are joined:
2018-8-16 11:47:32 INFO 0x00124b0014afe1fb (0x00124b0014afe1fb): TODO - Nue Smart light switch - 2 gang (Router)
2018-8-16 11:47:32 WARN `permit_join` set to `true` in configuration.yaml.
2018-8-16 11:47:32 WARN Allowing new devices to join.
2018-8-16 11:47:32 WARN Set `permit_join` to `false` once you joined all devices.
2018-8-16 11:47:32 INFO Zigbee: allowing new devices to join.
2018-8-16 11:47:32 INFO Connecting to MQTT server at mqtt://192.168.0.101
zigbee-shepherd:request REQ --> ZDO:mgmtPermitJoinReq +53ms
2018-8-16 11:47:32 INFO zigbee-shepherd ready
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +14ms
spinlock: false []
zigbee-shepherd:request REQ --> ZDO:nodeDescReq +2ms
2018-8-16 11:47:32 INFO Connected to MQTT server
2018-8-16 11:47:32 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/state', payload: 'online'
zigbee-shepherd:msgHdlr IND <-- ZDO:permitJoinInd +17ms
zigbee-shepherd:msgHdlr IND <-- ZDO:mgmtPermitJoinRsp +18ms
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +17ms
zigbee-shepherd:request REQ --> ZDO:activeEpReq +0ms
zigbee-shepherd:msgHdlr IND <-- ZDO:activeEpRsp +38ms
zigbee-shepherd:request REQ --> ZDO:simpleDescReq +1ms
zigbee-shepherd:msgHdlr IND <-- ZDO:simpleDescRsp +43ms
zigbee-shepherd:request REQ --> ZDO:simpleDescReq +0ms
zigbee-shepherd:msgHdlr IND <-- ZDO:simpleDescRsp +42ms
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 1 +13ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +13ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +27ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 1 +1ms
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 2 +11ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +5ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +17ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
zigbee-shepherd Identified Device: { manufacturer: Feibit Inc co. , product: FB56+ZSW1HKJ1.7 } +2ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +3ms
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 3 +6ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +2ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 2 +0ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +10ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +9ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
2018-8-16 11:47:32 DEBUG Recieved zigbee message with data {"cid":"genOnOff","data":{"onOff":1}}
2018-8-16 11:47:32 WARN No converter available for 'TODO' with cid 'genOnOff', type 'devChange' and data '{"cid":"genOnOff","data":{"onOff":1}}'
2018-8-16 11:47:32 WARN Please see: https://github.com/Koenkk/zigbee2mqtt/wiki/How-to-support-new-devices.
zigbee-shepherd-converters:devices Configured '(cb) => ep16.read('genOnOff', 'onOff', cb)' with result 'OK' +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +13ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 3 +0ms
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 4 +293ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +9ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +30ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 4 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +15ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +3ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
zigbee-shepherd-converters:devices Configured '(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb)' with result 'OK' +361ms
2018-8-16 11:47:32 INFO Succesfully configured 0x00124b0014afe1fb
2018-8-16 11:48:02 DEBUG Recieved zigbee message with data "0x00124b0014afe1fb"
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 5 +30s
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +11ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +24ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 5 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +14ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +3ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-16 11:48:02 DEBUG Recieved zigbee message with data "0x00124b0014afe1fb"
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 6 +5ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +11ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +22ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 6 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +19ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-16 11:48:02 DEBUG Recieved zigbee message with data "0x00124b0014afe1fb"
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 7 +1ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +14ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +23ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 7 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +12ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +6ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 8 +3ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +13ms
This is now populated into the database.db:
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1534420052,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"gQuNFAzty9asR4kN"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":19235,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"offline","joinTime":null,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1657339904,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"JqvG0hCarzOZ6oZP"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":19235,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1534420052,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1657339904,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"JqvG0hCarzOZ6oZP"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":19235,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1534420052,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1085997056,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"JqvG0hCarzOZ6oZP"}
I feel like I'm getting close!!! Does this look like it's going in the right direction now?
I'm just still using the one device (for reference the 2 gang switch model number is "HGZB-042") and I'm leaving the manufacturers hub switched off, and re-pairing the switch on each reboot.
Once I get one working, I'll be happy to find and properly format the settings data for the 5 or so related devices I have and create a PR, so hopefully this will help others also.
Any further steps forward would be great!! Thank you again.
After 2018-08-16T11:47:32.810Z - info: Succesfully configured 0x00124b0014afe1fb. Do you still see any No converter available messages when toggling the switch?
No, that was the first time I've ever seen the "no converter available" message appear, and the associated payloads, eg.:
2018-8-16 11:47:32 DEBUG Recieved zigbee message with data {"cid":"genOnOff","data":{"onOff":1}}
2018-8-16 11:47:32 WARN No converter available for 'TODO' with cid 'genOnOff', type 'devChange' and data '{"cid":"genOnOff","data":{"onOff":1}}'
Toggling the switch does not produce any messages that I can see on the debug output or the log. Is this due to needing to further setup
(Sorry closed issue by accident on my phone)
The one report is because of the read in the configure method. Somehow, the device just refuses to report it's state change :(.
Could you try pairing your FB56+ZSW1HKJ2.5 ?
@Koenkk sure thing. I just need to find which switch it is in the house!
For the time being, I also added a Nue "FB56-ZSW05HG1.2" in-line switch whilst debugging, before I forever sealed it in plasterboard tomorrow.
This device is that referred to in Nue in wall switch #29
Log below - I'll try some other model switches now. Thanks again.
I believe this is the same FB56+ZSW1HKJ2.5,
Debug output:
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +25ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 22 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +20ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +7ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
zigbee-shepherd Identified Device: { manufacturer: Feibit Inc co. , product: FB56+ZSW1HKJ2.5 } +0ms
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 23 +5ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +14ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +23ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 23 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +12ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +2ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
2018-8-18 12:30:05 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:05 INFO Connecting with device...
2018-8-18 12:30:05 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 24 +7ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +12ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +26ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 24 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +12ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +3ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-18 12:30:05 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:05 INFO Connecting with device...
2018-8-18 12:30:05 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 25 +7ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +13ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +24ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 25 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +10ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +4ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
2018-8-18 12:30:05 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:05 INFO Connecting with device...
2018-8-18 12:30:05 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 26 +9ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +17ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +336ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 26 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +11ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +3ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-18 12:30:06 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:06 INFO Connecting with device...
2018-8-18 12:30:06 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 27 +14ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +15ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +348ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 27 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +12ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-18 12:30:06 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:06 INFO Connecting with device...
2018-8-18 12:30:06 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 28 +2ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +13ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +171ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 28 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +13ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +3ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
2018-8-18 12:30:06 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:06 INFO Connecting with device...
2018-8-18 12:30:06 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 29 +4ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +16ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +300ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 29 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +6ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-18 12:30:07 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:07 INFO Connecting with device...
2018-8-18 12:30:07 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 30 +1ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +13ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +588ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 30 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +10ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-18 12:30:07 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:07 INFO Connecting with device...
2018-8-18 12:30:07 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
zigbee-shepherd Device: 0x00124b0019e14fa6 join the network. +1ms
2018-8-18 12:30:07 DEBUG Recieved zigbee message with data "0x00124b0019e14fa6"
2018-8-18 12:30:07 INFO Device incoming...
2018-8-18 12:30:07 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"device incoming"}'
2018-8-18 12:30:07 INFO New device with address 0x00124b0019e14fa6 connected!
2018-8-18 12:30:07 INFO MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"device_connected","message":"0x00124b0019e14fa6"}'
2018-8-18 12:30:07 DEBUG Recieved zigbee message with data "online"
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 31 +305ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +14ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +34ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 31 +0ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +13ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +1ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +0ms
2018-8-18 12:30:08 DEBUG Recieved zigbee message with data {"cid":"genOnOff","data":{"onOff":0}}
2018-8-18 12:30:08 WARN No converter available for 'TODO' with cid 'genOnOff', type 'devChange' and data '{"cid":"genOnOff","data":{"onOff":0}}'
2018-8-18 12:30:08 WARN Please see: https://github.com/Koenkk/zigbee2mqtt/wiki/How-to-support-new-devices.
zigbee-shepherd-converters:devices Configured '(cb) => ep16.read('genOnOff', 'onOff', cb)' with result 'OK' +20m
zigbee-shepherd:request REQ --> AF:dataRequest, transId: 32 +304ms
zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0 +15ms
zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object] +23ms
zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 32 +0ms
2018-8-18 12:30:14 DEBUG Check online 0x00124b0014afe1fb
zigbee-shepherd:request REQ --> ZDO:nodeDescReq +6s
2018-8-18 12:30:14 DEBUG Check online 0x00124b000bd6d293
zigbee-shepherd:request REQ --> ZDO:nodeDescReq +2ms
2018-8-18 12:30:14 DEBUG Check online 0x00124b0019e14fa6
zigbee-shepherd:request REQ --> ZDO:nodeDescReq +0ms
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +65ms
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +2ms
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +403ms
zigbee-shepherd-converters:devices Configured '(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb)' with result 'Error: Timed out after 30000 ms' +30s
2018-8-18 12:30:38 ERROR Failed to configure 0x00124b0019e14fa6
2018-8-18 12:31:14 DEBUG Check online 0x00124b0014afe1fb
zigbee-shepherd:request REQ --> ZDO:nodeDescReq +60s
2018-8-18 12:31:14 DEBUG Check online 0x00124b000bd6d293
zigbee-shepherd:request REQ --> ZDO:nodeDescReq +1ms
2018-8-18 12:31:14 DEBUG Check online 0x00124b0019e14fa6
zigbee-shepherd:request REQ --> ZDO:nodeDescReq +0ms
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +57ms
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +3ms
zigbee-shepherd:msgHdlr IND <-- ZDO:nodeDescRsp +268ms
Log.txt:
2018-08-18T12:30:05.634Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:05.635Z - info: Connecting with device...
2018-08-18T12:30:05.636Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:05.696Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:05.697Z - info: Connecting with device...
2018-08-18T12:30:05.698Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:05.758Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:05.759Z - info: Connecting with device...
2018-08-18T12:30:05.761Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:06.138Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:06.139Z - info: Connecting with device...
2018-08-18T12:30:06.141Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:06.521Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:06.522Z - info: Connecting with device...
2018-08-18T12:30:06.522Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:06.724Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:06.726Z - info: Connecting with device...
2018-08-18T12:30:06.726Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:07.051Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:07.051Z - info: Connecting with device...
2018-08-18T12:30:07.052Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:07.665Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:07.665Z - info: Connecting with device...
2018-08-18T12:30:07.665Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"connecting with device"}'
2018-08-18T12:30:07.666Z - debug: Recieved zigbee message with data "0x00124b0019e14fa6"
2018-08-18T12:30:07.667Z - info: Device incoming...
2018-08-18T12:30:07.667Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"pairing","message":"device incoming"}'
2018-08-18T12:30:07.667Z - info: New device with address 0x00124b0019e14fa6 connected!
2018-08-18T12:30:07.668Z - info: MQTT publish, topic: 'zigbee2mqtt/bridge/log', payload: '{"type":"device_connected","message":"0x00124b0019e14fa6"}'
2018-08-18T12:30:07.669Z - debug: Recieved zigbee message with data "online"
2018-08-18T12:30:08.034Z - debug: Recieved zigbee message with data {"cid":"genOnOff","data":{"onOff":0}}
2018-08-18T12:30:08.035Z - warn: No converter available for 'TODO' with cid 'genOnOff', type 'devChange' and data '{"cid":"genOnOff","data":{"onOff":0}}'
2018-08-18T12:30:08.035Z - warn: Please see: https://github.com/Koenkk/zigbee2mqtt/wiki/How-to-support-new-devices.
2018-08-18T12:30:14.641Z - debug: Check online 0x00124b0014afe1fb
2018-08-18T12:30:14.644Z - debug: Check online 0x00124b000bd6d293
2018-08-18T12:30:14.644Z - debug: Check online 0x00124b0019e14fa6
2018-08-18T12:30:38.341Z - error: Failed to configure 0x00124b0019e14fa6
2018-08-18T12:31:14.655Z - debug: Check online 0x00124b0014afe1fb
2018-08-18T12:31:14.657Z - debug: Check online 0x00124b000bd6d293
2018-08-18T12:31:14.657Z - debug: Check online 0x00124b0019e14fa6
This is my devices.js entry:
// Nue
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 10, repChange: 0};
const actions = [
(cb) => ep16.read('genOnOff', 'onOff', cb),
(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(ep16, actions, callback);
},
},
{
zigbeeModel: ['FB56+ZSW05HG1.2'],
model: 'Nue Smart Inline Switch',
vendor: 'Nue',
descritpion: 'Smart inline switch',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
},
The configure failed:
zigbee-shepherd-converters:devices Configured '(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb)' with result 'Error: Timed out after 30000 ms' +30s
2018-8-18 12:30:38 ERROR Failed to configure 0x00124b0019e14fa6
Can you try repairing?
Sorry I'm currently away with work - the device might be difficult to get to now but I can try.
Is there any chance this is related to the sniffer, and/or firmware? I'm holding out for some changes to Zigbee2MQTT that allow modification of the .js files, as this will make the process much easier to debug.
Something else (a little off topic) that I've been wondering about for a while now is if/when I get this up and running, is how to continue to utilise Alexa integration.
The supplied usb hub I assume will become redundant, but therefore so will the links to the hub via the app, which is the Alexa link. Is it possible to utilise the CC2531 as a repeater, rather than a coordinator, but still to pass/receive messages to HASS.io?
You could try updating to: https://github.com/Koenkk/Z-Stack-firmware/tree/increased_buffer/coordinator/CC2531/bin
No this is not possible, as zigbee2mqtt has to be the coordinator. (and you cannot have more than one coordinator in a zigbee network).
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
@highground88 how did you go in the end. As, seemingly, the only AU approved switches there should be interest.
Hi @ryanbeaton, I haven't got any further myself, but am still planning to try. There seems to be some great new features added in the past week which will make sniffing easier - unfortunately when I moved from ResinOS to HassOS, I had issues getting Zigbee2MQTT up and running as before. I think this may have resolved itself now and hopefully I'll have a look at my system again soon. If/when I do get anything definitive, I'll make sure I push it through. Still keen to hear from anyone else who's made more progress - it seems these have been selling pretty well, so I'm surprised really.
Still not having much luck but will kepp trying. I notcied that in addition to SmartThings, the Hubitat users have also managed to import the handlers etc into their ecosystem and can utilise this with HA (although there seems to be problems getting the 3rd switch from the 3 gang units working). Unfortunately WAF too low to purchase a new hub right now....
I have also found this information on the Feibet site which I'm hoping might help those smarter than me figure out more of the problem perhaps? (translated into Chinglish from here: http://www.feibit.com/changjianwenti.html ). Unsure if this is referencing the app control or communication to the gateway unit.
Interface Protocol: TCP Socket Interface
Port number: 8001
The illuminance data is parsed high in the previous low position and converted to decimal in D554 . The illuminance intensity is 54612.
Interface protocol: socket and web socket
Port number: socket 8090 , web socket 8092
Format: packet length (2 bytes ) data type (2 bytes ) data length (2 bytes ) data ( variable length )
Hi @Koenkk & @ryanbeaton ,
My apologies for the delay in getting back to this - just getting a bit of time now to re-visit, and see that there's been some more revisions.
I've updated to a fresh version (1.0.1) of the add-on and have had a clean up, and I think I'm finally starting to see some of the messages based on switch activation which I wasn't able to see previously. Still trying to get my head around this but I think I'm getting somewhere now!
Unfortunately I've tried a few variants of the handler that you originally kindly provided me with Koen, but the device isn't being accepted fully, e.g. _(Message without device / Device with modelID 'undefined is not supported')_
From what I can tell, there's two end points (sorry if not correct terminology), 16 and perhaps 17. The last device handler you gave me seems to only relate to 16, therefore this is perhaps why both activations of the switches appear with the same output data without differentiation? I'm currently trying to piece together some code that might work for the two based on your previous examples and I'll update if I make a breakthrough - but I have very limited programming knowledge.
If you could offer any sort of further advice, I'd be really appreciative - I feel I'm very close, and then hopefully I'll be able to start getting some of this together without so much help for the other 4 or 5 models of these switches I have.
devices.js entry:
`` {
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 10, repChange: 0};
const actions = [
(cb) => ep16.read('genOnOff', 'onOff', cb),
(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(ep16, actions, callback);
},
},
That indeed looks good! Some how the modelID is not correct.
Can you:
0x00124b0014bdea20 from database.dbThanks very much again @Koenkk ...
I've followed your instructions (and quite sure I've tried this before too) but seem to get the same result.
(Stopped Z2MQTT, cleared out the relevant lines containing the coordinator address, restart Z2MQTT, allow rejoin, hold pairing button on device until the pairing light appears, activate the switches a few times). I've also fully removed the database before with no change.
Is this 'undefined' message relating to the switch or the coordinator (CC2531)? The message: _Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":0}}' of device 'undefined' (0x00124b0014bdea20)_ appears when activating a switch - but the ID of "0x00124b0014bdea20" appears to be the coordinator, not the switch?
Following doing above, this is the log output:
This is the current devices.js entry I'm trying:
` {
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'TODO',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const ep17 = shepherd.find(ieeeAddr, 17);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 10, repChange: 0};
const actions = [
(cb) => ep16.bind('genOnOff', coordinator, cb),
(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
(cb) => ep17.bind('genOnOff', coordinator, cb),
(cb) => ep17.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(ep16, actions, callback);
},
},`
0x00124b0014bdea20 is indeed the coordinator, which is very strange.
You are sure that Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0014bdea20) this message is produced when you click the switch (I've never seen before that the message is then reported by the coordinator).
Happy New Year @Koenkk
I can confirm that those messages above have been produced by activating the switch, and appear to come from the coordinator. In fact, I reflashed the firmware to your latest, reinstalled Z2MQTT, and re-paired the switch. Same thing is happening. I haven't changed the device handler from that above (not sure if this is correct for the device still or perhaps part of the problem?). Very strange - @danielwelch have you perhaps seen this happening?
Here are the new logs, switch activations occur around 13:50:30...
2019-1-2 13:45:33 - info: Logging to directory: '/share/zigbee2mqtt/log/2019-01-02.13-45-32'
2019-1-2 13:45:33 - debug: Removing old log directory '/share/zigbee2mqtt/log/2018-12-29.15-12-55'
2019-1-2 13:45:37 - debug: Using zigbee-shepherd with settings: '{"net":{"panId":6754,"channelList":[11]},"dbPath":"/share/zigbee2mqtt/database.db","sp":{"baudRate":115200,"rtscts":true}}'
2019-1-2 13:45:43 - debug: Loaded state from file /share/zigbee2mqtt/state.json
2019-1-2 13:45:45 - info: Starting zigbee2mqtt version 1.0.1 (commit #unknown)
2019-1-2 13:45:45 - info: Starting zigbee-shepherd
2019-1-2 13:46:30 - info: zigbee-shepherd started
2019-1-2 13:46:30 - info: Coordinator firmware version: '20181024'
2019-1-2 13:46:30 - debug: zigbee-shepherd info: {"enabled":true,"net":{"state":"Coordinator","channel":11,"panId":"0x1a62","extPanId":"0xdddddddddddddddd","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0},"firmware":{"transportrev":2,"product":0,"version":"2.6.3","revision":20181024},"startTime":1546400790,"joinTimeLeft":0}
2019-1-2 13:46:30 - info: Currently 0 devices are joined:
2019-1-2 13:46:30 - info: Zigbee: disabling joining new devices.
2019-1-2 13:46:30 - info: Connecting to MQTT server at mqtt://192.168.0.101:1883
2019-1-2 13:46:31 - info: zigbee-shepherd ready
2019-1-2 13:46:31 - info: Connected to MQTT server
2019-1-2 13:46:31 - info: MQTT publish: topic 'zigbee2mqtt/bridge/state', payload 'online'
2019-1-2 13:46:31 - debug: Mounted the cieApp (epId {epId})
2019-1-2 13:48:09 - debug: Received MQTT message on 'zigbee2mqtt/bridge/config/permit_join' with data 'true'
2019-1-2 13:48:09 - info: Zigbee: allowing new devices to join.
2019-1-2 13:48:09 - info: MQTT publish: topic 'zigbee2mqtt/bridge/config', payload '{"log_level":"debug","permit_join":true}'
2019-1-2 13:48:54 - debug: Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":0}}' of device 'undefined' (0x00124b0014bdea20)
2019-1-2 13:48:54 - warn: Device with modelID 'undefined' is not supported.
2019-1-2 13:48:54 - warn: Please see: https://koenkk.github.io/zigbee2mqtt/how_tos/how_to_support_new_devices.html
2019-1-2 13:48:59 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:48:59 - warn: Message without device!
2019-1-2 13:48:59 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:48:59 - warn: Message without device!
2019-1-2 13:48:59 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:48:59 - warn: Message without device!
2019-1-2 13:48:59 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:48:59 - warn: Message without device!
2019-1-2 13:49:00 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:49:00 - warn: Message without device!
2019-1-2 13:49:00 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:49:00 - warn: Message without device!
2019-1-2 13:49:00 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:49:00 - warn: Message without device!
2019-1-2 13:49:00 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:49:00 - warn: Message without device!
2019-1-2 13:49:00 - debug: Received zigbee message of type 'devIncoming' with data '"0x00124b0014afe1fb"' of device 'FB56+ZSW1HKJ1.7' (0x00124b0014afe1fb)
2019-1-2 13:49:00 - info: Device incoming...
2019-1-2 13:49:00 - info: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"pairing","message":"device incoming"}'
2019-1-2 13:49:00 - debug: Received zigbee message of type 'devStatus' with data '"online"' of device 'FB56+ZSW1HKJ1.7' (0x00124b0014afe1fb)
2019-1-2 13:49:02 - info: Succesfully configured 0x00124b0014afe1fb 0x00124b0014afe1fb
2019-1-2 13:49:17 - debug: Received zigbee message of type 'devLeaving' with data '"0x00124b0014afe1fb"'
2019-1-2 13:49:17 - warn: Message without device!
2019-1-2 13:49:52 - debug: Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0014bdea20)
2019-1-2 13:49:52 - warn: Device with modelID 'undefined' is not supported.
2019-1-2 13:49:52 - warn: Please see: https://koenkk.github.io/zigbee2mqtt/how_tos/how_to_support_new_devices.html
2019-1-2 13:50:03 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:03 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:04 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:04 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:04 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:04 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:04 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:04 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devInterview' with data '"0x00124b0014afe1fb"'
2019-1-2 13:50:04 - warn: Message without device!
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devIncoming' with data '"0x00124b0014afe1fb"' of device 'FB56+ZSW1HKJ1.7' (0x00124b0014afe1fb)
2019-1-2 13:50:04 - info: Device incoming...
2019-1-2 13:50:04 - info: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"pairing","message":"device incoming"}'
2019-1-2 13:50:04 - debug: Received zigbee message of type 'devStatus' with data '"online"' of device 'FB56+ZSW1HKJ1.7' (0x00124b0014afe1fb)
2019-1-2 13:50:36 - debug: Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":0}}' of device 'undefined' (0x00124b0014bdea20)
2019-1-2 13:50:36 - warn: Device with modelID 'undefined' is not supported.
2019-1-2 13:50:36 - warn: Please see: https://koenkk.github.io/zigbee2mqtt/how_tos/how_to_support_new_devices.html
2019-1-2 13:50:38 - debug: Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0014bdea20)
2019-1-2 13:50:38 - warn: Device with modelID 'undefined' is not supported.
2019-1-2 13:50:38 - warn: Please see: https://koenkk.github.io/zigbee2mqtt/how_tos/how_to_support_new_devices.html
2019-1-2 13:50:40 - debug: Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":0}}' of device 'undefined' (0x00124b0014bdea20)
2019-1-2 13:50:40 - warn: Device with modelID 'undefined' is not supported.
2019-1-2 13:50:40 - warn: Please see: https://koenkk.github.io/zigbee2mqtt/how_tos/how_to_support_new_devices.html
2019-1-2 13:50:43 - debug: Saving state to file /share/zigbee2mqtt/state.json
2019-1-2 13:50:54 - debug: Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0014bdea20)
2019-1-2 13:50:54 - warn: Device with modelID 'undefined' is not supported.
2019-1-2 13:50:54 - warn: Please see: https://koenkk.github.io/zigbee2mqtt/how_tos/how_to_support_new_devices.html
2019-1-2 13:50:58 - debug: Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0014bdea20)
2019-1-2 13:50:58 - warn: Device with modelID 'undefined' is not supported.
2019-1-2 13:50:58 - warn: Please see: https://koenkk.github.io/zigbee2mqtt/how_tos/how_to_support_new_devices.html
Database: (line breaks added)
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6,11],"status":"online","joinTime":1546400753,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"11":{"profId":260,"epId":11,"devId":1024,"inClusterList":[0,1281,3],"outClusterList":[1280,1282,3],"clusters":{"genBasic":{"dir":{"value":1},"acls":{"zclVersion":"R","hwVersion":"R","manufacturerName":"R","modelId":"R","dateCode":"R","powerSource":"R","locationDesc":"RW","physicalEnv":"RW","deviceEnabled":"RW"},"attrs":{"zclVersion":1,"hwVersion":1,"manufacturerName":"sivann inc.","modelId":"hiver0001","dateCode":"20170407","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"ssIasAce":{"dir":{"value":1}},"ssIasZone":{"dir":{"value":2},"cmdRsps":{"enrollReq":{"exec":"_exec_"},"statusChangeNotification":{"exec":"_exec_"}}},"ssIasWd":{"dir":{"value":2}},"genIdentify":{"dir":{"value":3},"acls":{"identifyTime":"RW"},"attrs":{"identifyTime":0}}}}},"_id":"Kh5XvjviRmhykh4Q"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":39693,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1546400973,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1170014208,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"PZYL316hqm259LaU"}
{"$$indexCreated":{"fieldName":"id","unique":true,"sparse":false}}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1546403739,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"Kh5XvjviRmhykh4Q"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":39693,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"offline","joinTime":null,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1170014208,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"PZYL316hqm259LaU"}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6,11],"status":"online","joinTime":1546403739,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"11":{"profId":260,"epId":11,"devId":1024,"inClusterList":[0,1281,3],"outClusterList":[1280,1282,3],"clusters":{"genBasic":{"dir":{"value":1},"acls":{"zclVersion":"R","hwVersion":"R","manufacturerName":"R","modelId":"R","dateCode":"R","powerSource":"R","locationDesc":"RW","physicalEnv":"RW","deviceEnabled":"RW"},"attrs":{"zclVersion":1,"hwVersion":1,"manufacturerName":"sivann inc.","modelId":"hiver0001","dateCode":"20170407","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"ssIasAce":{"dir":{"value":1}},"ssIasZone":{"dir":{"value":2},"cmdRsps":{"enrollReq":{"exec":"_exec_"},"statusChangeNotification":{"exec":"_exec_"}}},"ssIasWd":{"dir":{"value":2}},"genIdentify":{"dir":{"value":3},"acls":{"identifyTime":"RW"},"attrs":{"identifyTime":0}}}}},"_id":"Kh5XvjviRmhykh4Q"}
EDIT:
I've since added a Aqara door sensor just to ensure all is well, and it is working as expected.
I have sent through a graphviz message - below is the result. I noted that the Nue switch is aparently offline - it is not, and still sends a message via the coordinator seemingly when switched. The other strange entry is the line "0x00124b0014afe1fb" -> "0x00124b0014bdea20" [label="87"] . My knowledge of programming is similar to that of Fred Flintstone's, but could this be referring to the message from the switch looking like it's coming from the coordinator? And why would it be labelled '87'?
Please let me know if there's something else I should try.
Graphviz:
zigbee2mqtt:info 2019-1-2 16:01:16 MQTT publish: topic 'zigbee2mqtt/bridge/networkmap/graphviz', payload 'digraph G {
node[shape=record];
"0x00124b0014bdea20" [label="{0x00124b0014bdea20|Coordinator|No model information available|online}"];
"0x00124b0014afe1fb" [label="{0x00124b0014afe1fb|Router|Nue Smart light switch - 2 gang (TODO)|offline}"];
"0x00124b0014afe1fb" -> "0x00124b0014bdea20" [label="87"]
"0x00158d0002047314" [label="{0x00158d0002047314|EndDevice|Xiaomi Aqara door & window contact sensor (MCCGQ11LM)|online}"];
}'
Could you try sniffing the traffic from the device? This will give us some more insight on how it works: https://github.com/Koenkk/zigbee2mqtt/blob/dev/docs/how_tos/how_to_sniff_zigbee_traffic.md
I can sure try, but by chance is there a Windows compatible tool to do this? Otherwise I'll try to find a spare machine to put Ubuntu on.
Do you think this would help with the coordinator issue though? Thanks for your help as always.
I would recommend using ubuntu to do this (never tried it on windows).
Probably not, but perhaps it could give us insight on why this happens.
Sorry for the delay.... had fun getting this all to work/install/run over the last few days now......
I now have Ubuntu running on a laptop and have flashed the CC2531 with the sniffer software. I'm doing my best to follow along, and have interpreted based on trial and error that in your sniffing guide, the command to start wireshark should be "sudo whsniff -c 11 | wireshark -k -i -". Setting this to any other channel seemingly aside from 11 results in the error "unrecognised libpcap format or not libpcap data" (same if I use the command listed). Once I have it up and sniffing, the most I seem to get is a beacon request via IEEE 802.15.4once the switch is in pairing mode (03 08 67 ff ff ff ff 07 58 b2).
EDIT: I take this back..... I've had a breakthrough - it appears that the hub and switches are operating on channel 19. I didn't try this far up the sequence. If I browse to the "FBee Cloud Gateway" page ("Nue Smart Hub device") via IP, I'm greeted with this:
Version: | 聽
-- | --
Software Version | 2.5.5(Nov 22 2017_13:42:58)Light GW
Hardware version | FBF109CB V1.0
Serial No | XXXXXXXXXIP Mode | DHCP
IP Address | 192.168.XXX
IP Mask | 255.255.255.0
IP Gateway | 192.168.XXX
MAC Address | 10:A5:D4:XXXXXXXWAN | Connected
FBee Cloud | Full Control
User Name | XXXXXXXXCurrent Date: | 2019-01-09
Current Time | 18:12:23 (Time Zone:UTC +10:00)
Upload bytes | 1783
Download bytes | 16
Free Mem | 14832
Free Mini Mem | 9792
PanID | 5443-XXXXXXXXC60D004B1200-CH:19 Build:021203
Scene Mode: | 1
The CH19 part at the end of PanID tipped me off on the channel number!
I have also captured the Network Encryption Key, so have access to all broadcasts in wireshark now! (Is this a common key, or best I keep private?).
Thank you for getting me this far @koenkk - how can I best help from here with this access? Shall I capture and export a .pcap file or .csv or ..? I'm still treading water as far as understanding the Zigbee protocol, so unfortunately I'll still need a hand but I'd love to contribute as much as I can to both your project and help others with these devices.
From what I understand, the things that need finalisation with these switches for myself and a lot of others is getting them reliably onto the CC2531 platform and recognised under HA via Zigbee2MQTT - this might be device specific in some cases, due to dimming components, different numbers of gang switches, and "scene switch" devices which do not have a physical switch and still manage to retain their bind to other switches without a coordinator switched on.
I'll have a few more days I hope of time to play with this before being back at work, so please let me know what I can do to help. I'll post up some more info shortly once I work out how to get samba shares working...!
What messages do you see when you press a button on the switch?
Was having a few issues exporting correctly - please let me know if this is helpful instead. Below is probably the simplest record of the activation of both switches.
It seems that the messages are send to the zapp-cie, something that has been added in zigbee2mqtt 1.0.0. This also explains why the switch suddenly started to work.
Can you add the following to https://github.com/Koenkk/zigbee2mqtt/blob/master/lib/zapp/cie.js (before line 56)
cieClusters.init('genOnOff', 'dir', {value: 2}); // Client Side(Output)
cieClusters.init('genOnOff', 'cmds', {
off: (zapp, argObj, cb) => {
console.log("Hello there! this is off");
console.log(zapp, argObj);
},
on: (zapp, argObj, cb) => {
console.log("Hello there! this is ON");
console.log(zapp, argObj);
},
});
Thanks, looks promising. Is this zapp-cie change the likely culprit that has also caused the router device messages to appear as if they are coming from the coordinator perhaps?
I will have to look at setting up another HA device today, as I'm on Hassio and don't believe I can make those changes?
Hi @Koenkk ,
I think I have done as you suggested via a second Hasbian instance and a fork of your dev build with the modification to the cie.js file. This is the output: PASTEBIN LINK
It appears that the coordinator is still passing on the switch activation message unfortunately.
This is the point where the coordinator (0x00124b0014bdea20) starts acting funny and sending messages on activation of the switch (0x00124b0014afe1fb):
zigbee2mqtt:debug 1/10/2019, 6:51:18 AM Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0014bdea20)
zigbee2mqtt:warn 1/10/2019, 6:51:18 AM Device with modelID 'undefined' is not supported.
The device.js I used is below - again I really have no idea what I shoud be putting in this still, but I have included it for your reference.
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'on/off',
fromZigbee: [fz.nue_power_state, fz.ignore_onoff_change, fz.generic_state],
toZigbee: [tz.on_off],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 10, repChange: 0};
const actions = [
(cb) => ep16.read('genOnOff', 'onOff', cb),
(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(ep16, actions, callback);
},
},
Can you post the whole log? (I'm also interested in the startup part)
Sorry I'd just cut that part - I've re done another full log from the start.
FULL LOG
For info, this is the sequence in case it's difficult to see.:
Hope this helps, and thank you once more.
No luck yet, can you try with:
cieClusters.init('genOnOff', 'dir', {value: 1}); // Client Side(Output)
cieClusters.init('genOnOff', 'cmds', {
off: (zapp, argObj, cb) => {
console.log("Hello there! this is off");
console.log(zapp, argObj);
},
on: (zapp, argObj, cb) => {
console.log("Hello there! this is ON");
console.log(zapp, argObj);
},
});
Sure. Here is the log NEW LOG. I followed the same sequence as above re button presses etc, but it appears that this hasn't unfortunately fixed it either.
The above log did not have the change for the device in the devices.js file, the below log is after this has been modified. Are you able to confirm what the correct handler should be based on what you've seen yet perhaps, and I can update this? I assume this is unrelated to the zapp-cie issue?
DEVICES.JS UPDATED, NO PAIRING
Just in case I'm doing something wrong in the process of making these changes, I stop zigbee2mqtt, delete the /otp/zigbee2mqtt folder, and then made changes to the cie.js file in my fork. I then use sudo git clone https://github.com/highground88/zigbee2mqtt.git /opt/zigbee2mqtt to download the modified version and continue the install as usual.
I'm at least learning a lot about the CLI in this process... until yesterday I didn't know how to remove a folder. :-)
That's indeed the good procedure, I've added extra logging to your fork, could you update and provide the logging again?
Great, thank you - here are the results - lots more data so may have missed the very beginning as Putty appears to have a limit so I'll post a second bootup below the main log...
LOG - Update deviceReceive.js commit a8e6f80
This is the sequence this time:
This is the second (full) bootup, with permit join set false and device already added (& actuated switches on/off each):
The current problem is that we don't know that it come from the switch. In the logging I can't find any identifiers. I'm out of ideas again..
At least we have got some kind of reaction out of the switches I guess now. I'm still stumped why this switch isn't working but the other handlers already in shepherd for the other switches do.
Being that these seem to work in SmartThings, would this thread shed any secrets for you perhaps? The distributor '3asmarthome' is also active on that forum so I have reached out to him again.
I will wire up some different model switches perhaps today and see if anything comes up. I have ordered a second cc2531 so that one can stay connected to Zigbee2Mqtt whilst the other is used as a sniffer. By all means if you have any other ideas or anything else you want me to try please let me know as I'm not quite ready to give up yet! :-)
Thanks Koen
I've hooked up a different model switch (1 gang + dimmer up/down) which shows as a FB56+ZSC05HG1.0 Product Link and I've created a new dump (just added the model number in behind the previous 2 switches in the devices.js file).
Not sure if it's helpful or not. The other switch was powered off at the time. Pressing any of the buttons resulted in this output:
zigbee-shepherd:msgHdlr IND <-- ZDO:srcRtgInd +31s
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +12ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +10ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +2ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +6s
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +10ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +2ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +3s
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +10ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +2ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +978ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +10ms
From what I understand the Smart Things guys didn't have too much trouble with the other switches, but this dimmer seemed a little more complex.
Device internal images:
Both appear to have a CC2530 module with an CC2592 'range extender' chip on the same daughter board..
Can you add to: https://github.com/Koenkk/zigbee-shepherd/blob/master/lib/components/af.js#L689 console.log(msg.zclMsg.cmdId) and provide the log?
Sure: LOG with console.log(msg.zclMsg.cmdId)
Both model devices re-paired.
@Koenkk I've started clean after the above log and pulled your dev version in again, making the same change as above to the af.js file.
As I was going back through your documentation... something dawned on me when I re-read your debugging guide. I've been using DEBUG=zigbee-shepherd* npm start for all these logs when I think I should have been using just DEBUG=* npm start ...? :astonished:
Subsequently I now have a very much bigger and detailed log for you which I think might help with the communications..... very sorry if I've been doing this wrong all this time!
The 2 devices were already paired but I have re-paired each during the log and also actioned all switches. I really hope this is the breakthrough you need....
Can you point me to what output is produced when doing actions on the switches? (I don't see any useful in the current log)
Not sure if useful it did look different than before, but I believe this is a switch message:
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +14ms
readRsp
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +1ms
readRsp
serialport:poller received "readable" +38ms
serialport:bindings read +67ms
serialport:unixRead Starting read +39ms
serialport:unixRead Finished read 33 bytes +1ms
serialport:main binding.read finished +69ms
cc-znp { sof: 254,
cc-znp len: 28,
cc-znp type: 'AREQ',
cc-znp subsys: 'AF',
cc-znp cmd: 'incomingMsg',
cc-znp payload:
cc-znp { groupid: 0,
cc-znp clusterid: 8,
cc-znp srcaddr: 8910,
cc-znp srcendpoint: 11,
cc-znp dstendpoint: 11,
cc-znp wasbroadcast: 0,
cc-znp linkquality: 76,
cc-znp securityuse: 0,
cc-znp timestamp: 1736982,
cc-znp transseqnumber: 0,
cc-znp len: 8,
cc-znp data: <Buffer 18 f4 01 00 00 00 20 f8> },
cc-znp fcs: 35,
cc-znp csum: 35 } +62ms
serialport:main _read reading +10ms
serialport:bindings read +11ms
serialport:unixRead Starting read +11ms
cc-znp:AREQ <-- AF:incomingMsg, { groupid: 0, clusterid: 8, srcaddr: 8910, srcendpoint: 11, dstendpoint: 11, wasbroadcast: 0, linkquality: 76, securityuse: 0, timestamp: 1736982, transseqnumber: 0, len: 8, data: <Buffer 18 f4 01 00 00 00 20 f8> } +4ms
How do I donate to buy you a coffee or two?!?
That doesn't contain any useful information unfortunately, what code are you using for this device?
There is a donation link here: https://github.com/Koenkk/zigbee2mqtt/blob/master/README.md
{
zigbeeModel: ['FB56+ZSW1HKJ2.5', 'FB56+ZSW1HKJ1.7', 'FB56+ZSC05HG1.0'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'on/off',
fromZigbee: [fz.nue_power_state, fz.ignore_onoff_change, fz.generic_state],
toZigbee: [tz.on_off],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 10, repChange: 0};
const actions = [
(cb) => ep16.read('genOnOff', 'onOff', cb),
(cb) => ep16.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(ep16, actions, callback);
},
},
Can you provide the database.db of FB56+ZSC05HG1.0
Here you go, thanks:
{"id":3,"type":"Router","ieeeAddr":"0x00124b001545a430","nwkAddr":8910,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSC05HG1.0","epList":[11,13],"status":"online","joinTime":1547518256,"endpoints":{"11":{"profId":260,"epId":11,"devId":257,"inClusterList":[0,3,4,5,6,8],"outClusterList":[],"clusters":{"genBasic":{"dir":{"value":1},"attrs":{}},"genIdentify":{"dir":{"value":1},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{}},"genLevelCtrl":{"dir":{"value":1},"attrs":{}}}},"13":{"profId":49246,"epId":13,"devId":57694,"inClusterList":[4096],"outClusterList":[4096],"clusters":{"lightLink":{"dir":{"value":3},"attrs":{}}}}},"_id":"4UtIx3zVqzgjDM6y"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":14173,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1547518291,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"SYv4N45UlvOeo59l"}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6,11],"status":"online","joinTime":1547518207,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"11":{"profId":260,"epId":11,"devId":1024,"inClusterList":[0,1281,3],"outClusterList":[1280,1282,3],"clusters":{"genBasic":{"dir":{"value":1},"acls":{"zclVersion":"R","hwVersion":"R","manufacturerName":"R","modelId":"R","dateCode":"R","powerSource":"R","locationDesc":"RW","physicalEnv":"RW","deviceEnabled":"RW"},"attrs":{"zclVersion":1,"hwVersion":1,"manufacturerName":"sivann inc.","modelId":"hiver0001","dateCode":"20170407","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"ssIasAce":{"dir":{"value":1}},"ssIasZone":{"dir":{"value":2},"cmdRsps":{"enrollReq":{"exec":"_exec_"},"statusChangeNotification":{"exec":"_exec_"}}},"ssIasWd":{"dir":{"value":2}},"genIdentify":{"dir":{"value":3},"acls":{"identifyTime":"RW"},"attrs":{"identifyTime":0}}}}},"_id":"xyNF05O5uq7OmfpG"}
{"$$indexCreated":{"fieldName":"id","unique":true,"sparse":false}}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6],"status":"online","joinTime":1547518431,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}}},"_id":"xyNF05O5uq7OmfpG"}
{"id":3,"type":"Router","ieeeAddr":"0x00124b001545a430","nwkAddr":8910,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSC05HG1.0","epList":[11,13],"status":"offline","joinTime":null,"endpoints":{"11":{"profId":260,"epId":11,"devId":257,"inClusterList":[0,3,4,5,6,8],"outClusterList":[],"clusters":{"genBasic":{"dir":{"value":1},"attrs":{}},"genIdentify":{"dir":{"value":1},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{}},"genLevelCtrl":{"dir":{"value":1},"attrs":{}}}},"13":{"profId":49246,"epId":13,"devId":57694,"inClusterList":[4096],"outClusterList":[4096],"clusters":{"lightLink":{"dir":{"value":3},"attrs":{}}}}},"_id":"4UtIx3zVqzgjDM6y"}
{"id":2,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":14173,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"offline","joinTime":null,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":1}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{"16393":1287651328,"hwVersion":0,"manufacturerName":"Feibit Inc co. ","modelId":"FB56+ZSW1HKJ1.7","dateCode":"20161030 ","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{"onOff":0}}}}},"_id":"SYv4N45UlvOeo59l"}
{"id":1,"type":"Coordinator","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0,"manufId":0,"epList":[1,2,3,4,5,6,11],"status":"online","joinTime":1547518431,"endpoints":{"1":{"profId":260,"epId":1,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"2":{"profId":257,"epId":2,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"3":{"profId":261,"epId":3,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"4":{"profId":263,"epId":4,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"5":{"profId":264,"epId":5,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"6":{"profId":265,"epId":6,"devId":5,"inClusterList":[],"outClusterList":[],"clusters":{}},"11":{"profId":260,"epId":11,"devId":1024,"inClusterList":[0,1281,3],"outClusterList":[1280,1282,3],"clusters":{"genBasic":{"dir":{"value":1},"acls":{"zclVersion":"R","hwVersion":"R","manufacturerName":"R","modelId":"R","dateCode":"R","powerSource":"R","locationDesc":"RW","physicalEnv":"RW","deviceEnabled":"RW"},"attrs":{"zclVersion":1,"hwVersion":1,"manufacturerName":"sivann inc.","modelId":"hiver0001","dateCode":"20170407","powerSource":1,"locationDesc":" ","physicalEnv":0,"deviceEnabled":1}},"ssIasAce":{"dir":{"value":1}},"ssIasZone":{"dir":{"value":2},"cmdRsps":{"enrollReq":{"exec":"_exec_"},"statusChangeNotification":{"exec":"_exec_"}}},"ssIasWd":{"dir":{"value":2}},"genIdentify":{"dir":{"value":3},"acls":{"identifyTime":"RW"},"attrs":{"identifyTime":0}}}}},"_id":"xyNF05O5uq7OmfpG"}
{"$$deleted":true,"_id":"SYv4N45UlvOeo59l"}
{"id":4,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":64303,"manufId":0,"epList":[16,17],"status":"online","joinTime":1547518490,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{}}},"_id":"k0zWxYEwPSPsJ3Sr"}
{"id":4,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":64303,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1547518490,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{}}},"_id":"k0zWxYEwPSPsJ3Sr"}
{"id":4,"type":"Router","ieeeAddr":"0x00124b0014afe1fb","nwkAddr":64303,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSW1HKJ1.7","epList":[16,17],"status":"online","joinTime":1547518490,"endpoints":{"16":{"profId":260,"epId":16,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{}}}},"17":{"profId":260,"epId":17,"devId":2,"inClusterList":[0,4,5,6],"outClusterList":[0],"clusters":{"genBasic":{"dir":{"value":3},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{}}}}},"_id":"k0zWxYEwPSPsJ3Sr"}
{"id":3,"type":"Router","ieeeAddr":"0x00124b001545a430","nwkAddr":8910,"manufId":0,"manufName":"Feibit Inc co. ","powerSource":"Mains (single phase)","modelId":"FB56+ZSC05HG1.0","epList":[11,13],"status":"online","joinTime":1547518522,"endpoints":{"11":{"profId":260,"epId":11,"devId":257,"inClusterList":[0,3,4,5,6,8],"outClusterList":[],"clusters":{"genBasic":{"dir":{"value":1},"attrs":{}},"genIdentify":{"dir":{"value":1},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{}},"genLevelCtrl":{"dir":{"value":1},"attrs":{}}}},"13":{"profId":49246,"epId":13,"devId":57694,"inClusterList":[4096],"outClusterList":[4096],"clusters":{"lightLink":{"dir":{"value":3},"attrs":{}}}}},"_id":"4UtIx3zVqzgjDM6y"}
Can you add the following to devices.js:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TODO',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.bind('genLevelCtrl', coordinator, cb),
];
execute(device, actions, callback);
},
},
configuration.yaml set log_level: debug (https://koenkk.github.io/zigbee2mqtt/configuration/configuration.html) DEBUG=The button presses showed only as "readRsp" this time. I re-paired, but continued to do the same. I didn't delete the database first, just followed your instructions. Cheers
Can you try with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TODO',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 3, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.bind('genLevelCtrl', coordinator, cb),
(cb) => device.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
(cb) => device.report('genLevelCtrl', 'currentLevel', 0, 3, 0, cb),
];
execute(device, actions, callback);
},
},
Sure. For info the "readRsp" is definitely a button press - it just happens that this dimming device rapidly sends the command even when briefly held down, hence why so many,
> [email protected] start /opt/zigbee2mqtt
> node index.js
zigbee2mqtt:info 1/16/2019, 11:11:06 AM Logging to directory: '/opt/zigbee2mqtt/data/log/2019-01-16.11-11-06'
zigbee2mqtt:debug 1/16/2019, 11:11:07 AM Using zigbee-shepherd with settings: '{"net":{"panId":6754,"channelList":[11],"precfgkey":[1,3,5,7,9,11,13,15,0,2,4,6,8,10,12,13]},"dbPath":"/opt/zigbee2mqtt/data/database.db","sp":{"baudRate":115200,"rtscts":true}}'
zigbee2mqtt:debug 1/16/2019, 11:11:07 AM Loaded state from file /opt/zigbee2mqtt/data/state.json
zigbee2mqtt:info 1/16/2019, 11:11:07 AM Starting zigbee2mqtt version 1.0.1 (commit #9605e72)
zigbee2mqtt:info 1/16/2019, 11:11:07 AM Starting zigbee-shepherd
zigbee2mqtt:info 1/16/2019, 11:11:08 AM zigbee-shepherd started
zigbee2mqtt:info 1/16/2019, 11:11:08 AM Coordinator firmware version: '20181024'
zigbee2mqtt:debug 1/16/2019, 11:11:08 AM zigbee-shepherd info: {"enabled":true,"net":{"state":"Coordinator","channel":11,"panId":"0x1a62","extPanId":"0xdddddddddddddddd","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0},"firmware":{"transportrev":2,"product":0,"version":"2.6.3","revision":20181024},"startTime":1547637068,"joinTimeLeft":0}
zigbee2mqtt:info 1/16/2019, 11:11:08 AM Currently 2 devices are joined:
zigbee2mqtt:info 1/16/2019, 11:11:08 AM 0x00124b001545a430 (0x00124b001545a430): TODO - Nue ZigBee smart dimmer switch (Router)
zigbee2mqtt:info 1/16/2019, 11:11:08 AM 0x00124b0014afe1fb (0x00124b0014afe1fb): TODO - Nue Smart light switch - 2 gang (Router)
zigbee2mqtt:warn 1/16/2019, 11:11:08 AM `permit_join` set to `true` in configuration.yaml.
zigbee2mqtt:warn 1/16/2019, 11:11:08 AM Allowing new devices to join.
zigbee2mqtt:warn 1/16/2019, 11:11:08 AM Set `permit_join` to `false` once you joined all devices.
zigbee2mqtt:info 1/16/2019, 11:11:08 AM Zigbee: allowing new devices to join.
zigbee2mqtt:info 1/16/2019, 11:11:08 AM Connecting to MQTT server at mqtt://192.168.0.101
zigbee2mqtt:debug 1/16/2019, 11:11:09 AM Configuring 0x00124b001545a430 (0x00124b001545a430) ...
zigbee2mqtt:debug 1/16/2019, 11:11:09 AM Configuring 0x00124b0014afe1fb (0x00124b0014afe1fb) ...
zigbee2mqtt:info 1/16/2019, 11:11:09 AM zigbee-shepherd ready
zigbee2mqtt:info 1/16/2019, 11:11:09 AM Connected to MQTT server
zigbee2mqtt:info 1/16/2019, 11:11:09 AM MQTT publish: topic 'zigbee2mqtt/bridge/state', payload 'online'
zigbee2mqtt:debug 1/16/2019, 11:11:09 AM Mounted the cieApp (epId 11)
zigbee2mqtt:error 1/16/2019, 11:11:10 AM Failed to configure 0x00124b0014afe1fb (0x00124b0014afe1fb) ('Error: AF data request fails, status code: 233. MAC no ack.')
defaultRsp
defaultRsp
zigbee2mqtt:error 1/16/2019, 11:11:10 AM Failed to configure 0x00124b001545a430 (0x00124b001545a430) ('TypeError: Cannot read property 'status' of undefined')
readRsp
readRsp
readRsp
readRsp
Is something else in my setup possibly broken at the moment - would it be worth pulling it down again, and if so, would you like me to change the cie file or anything else? Thanks
If that is the case, can you add readRsp to this array: https://github.com/Koenkk/zigbee-shepherd/blob/master/lib/components/af.js#L687
I've edited this file in "/opt/zigbee2mqtt/node_modules/zigbee-shepherd/lib/components"
const cmdIDs = ['on', 'offWithEffect', 'step', 'stop', //Philips-RWL020-RWL021
'off', 'stepColorTemp', 'moveWithOnOff', 'move', 'readRsp', 'moveHue', 'moveToSat$
'stopWithOnOff', 'moveToLevelWithOnOff', 'toggle', 'tradfriArrowSingle', 'tradfri$
but unfortunately the output is the same.
Can you try with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TODO',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 3, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.bind('genLevelCtrl', coordinator, cb),
(cb) => device.report('genLevelCtrl', 'currentLevel', 0, 3, 0, cb),
];
execute(device, actions, callback);
},
},
No change sorry.... LOG
This is the resulting log of both devices powered up on boot.
Could you siff the zigbee traffic of the FB56+ZSC05HG1.0 ?
Will do - but it will have to be tomorrow unfortunately as I have to flash the sniffer firmware again etc and the wife is into me for still being up... I'll get to it as soon as I can tomorrow and edit this. Thanks again for your help...
Hi @Koenkk - my apologies for not getting back to you sooner, life and an unexpected rebuild of my LAN got in the way....
But I think I have some good news. My latest sniffing attempt of the FB56+ZSC05HG1.0 turned up another device trust centre key.... I had assumed the previously discovered key was a single key that might be manufacturer specific across all devices, but maybe not? The new key looks to have a different format too (see link below). I've also got the second CC2531 I ordered now so I can use the sniffer at the same time.
The latest capture shows the attribute fields that coincide with the button presses of the FB56+ZSC05HG1.0 and also the FB56+ZSW1HKJ1.7, using Zigbee HA and ZDP protocols. These are located here in pcap format with the necessary codes, it might be easier perhaps for you: LINK
I'm running two instances of HA to try to debug this and currently experiencing a few issues with the Hassbian flavour, but I am about to test out your latest dev build on my Hassio build, as I see you've been busy with the code and everyone elses issues.... thanks mate.
I'm still not entirely sure how this part works, but in analysing the pcap files I think I have determined what each devices 'supports' from the attributes response. As far as determining precisely what to put in the from/to zigbee, I'm really only guessing and using previous device entries. This is the current devices.js entry:
{
zigbeeModel: ['FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'Basic, On/Off, Scenes, Groups',
fromZigbee: [fz.generic_state],
toZigbee: [tz.on_off],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
execute(ep16, [(cb) => ep16.bind('genOnOff', coordinator, cb)], () => {
const ep17 = shepherd.find(ieeeAddr, 17);
execute(ep17, [(cb) => ep17.bind('genOnOff', coordinator, cb)], callback);
});
},
},
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'On/Off, Level Control, Scenes, Groups, ZLL Commissioning, Power Source, Identify',
fromZigbee: [],
toZigbee: [],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 3, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.bind('genLevelCtrl', coordinator, cb),
(cb) => device.report('genLevelCtrl', 'currentLevel', 0, 3, 0, cb),
];
execute(device, actions, callback);
},
},
I did notice the coordinator issue which looked like the switch messages were sent by the co-ord ID has gone, a new one perhaps has arrived. I've highlighted the true device details below (..1fb), followed by some random ID (...6f2) which seems to be the same bug as before, but with a different ID?
Device was FB56+ZSW1HKJ1.7.
2019-01-20T08:34:02.329Z zigbee-shepherd-converters:devices Configured '(cb) => ep17.bind('genOnOff', coordinator, cb)' with result 'OK'
zigbee2mqtt:info 2019-1-20 18:34:02 Succesfully configured 0x00124b0014afe1fb (****0x00124b0014afe1fb****)
2019-01-20T08:35:02.104Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-01-20T08:35:02.121Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-01-20T08:35:02.123Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 2019-1-20 18:35:02 Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":0}}' of device 'undefined' (****0x00124b0018df46f2****)
zigbee2mqtt:debug 2019-1-20 18:35:02 Ignoring message from coordinator
2019-01-20T08:35:43.330Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-01-20T08:35:43.337Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-01-20T08:35:43.338Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 2019-1-20 18:35:43 Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":0}}' of device 'undefined' (0x00124b0018df46f2)
zigbee2mqtt:debug 2019-1-20 18:35:43 Ignoring message from coordinator
2019-01-20T08:36:04.641Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-01-20T08:36:04.651Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-01-20T08:36:04.655Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 2019-1-20 18:36:04 Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0018df46f2)
zigbee2mqtt:debug 2019-1-20 18:36:04 Ignoring message from coordinator
2019-01-20T08:36:08.807Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-01-20T08:36:08.844Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-01-20T08:36:08.845Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 2019-1-20 18:36:08 Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'undefined' (0x00124b0018df46f2)
zigbee2mqtt:debug 2019-1-20 18:36:08 Ignoring message from coordinator
This is the Wireshark capture of the same device (FB56+ZSW1HKJ1.7) "on" of a single switch which in the debug outputs as above:
Frame 8: 52 bytes on wire (416 bits), 52 bytes captured (416 bits) on interface 0
Interface id: 0 (-)
Interface name: -
Encapsulation type: IEEE 802.15.4 Wireless PAN (104)
Arrival Time: Jan 1, 1970 10:00:37.973621000 AEST
[Time shift for this packet: 0.000000000 seconds]
Epoch Time: 37.973621000 seconds
[Time delta from previous captured frame: 6.054649000 seconds]
[Time delta from previous displayed frame: 6.054649000 seconds]
[Time since reference or first frame: 36.150941000 seconds]
Frame Number: 8
Frame Length: 52 bytes (416 bits)
Capture Length: 52 bytes (416 bits)
[Frame is marked: True]
[Frame is ignored: False]
[Protocols in frame: wpan:zbee_nwk:zbee_aps:zbee_zcl]
IEEE 802.15.4 Data, Dst: 0x0000, Src: 0x4aab
Frame Control Field: 0x8861, Frame Type: Data, Acknowledge Request, PAN ID Compression, Destination Addressing Mode: Short/16-bit, Frame Version: IEEE Std 802.15.4-2003, Source Addressing Mode: Short/16-bit
.... .... .... .001 = Frame Type: Data (0x1)
.... .... .... 0... = Security Enabled: False
.... .... ...0 .... = Frame Pending: False
.... .... ..1. .... = Acknowledge Request: True
.... .... .1.. .... = PAN ID Compression: True
.... ...0 .... .... = Sequence Number Suppression: False
.... ..0. .... .... = Information Elements Present: False
.... 10.. .... .... = Destination Addressing Mode: Short/16-bit (0x2)
..00 .... .... .... = Frame Version: IEEE Std 802.15.4-2003 (0)
10.. .... .... .... = Source Addressing Mode: Short/16-bit (0x2)
Sequence Number: 225
Destination PAN: 0x1a62
Destination: 0x0000
Source: 0x4aab
[Extended Source: TexasIns_00:14:af:e1:fb (00:12:4b:00:14:af:e1:fb)]
[Origin: 2]
FCS: 0xa1ee (Correct)
ZigBee Network Layer Data, Dst: 0x0000, Src: 0x4aab
Frame Control Field: 0x0248, Frame Type: Data, Discover Route: Enable, Security Data
.... .... .... ..00 = Frame Type: Data (0x0)
.... .... ..00 10.. = Protocol Version: 2
.... .... 01.. .... = Discover Route: Enable (0x1)
.... ...0 .... .... = Multicast: False
.... ..1. .... .... = Security: True
.... .0.. .... .... = Source Route: False
.... 0... .... .... = Destination: False
...0 .... .... .... = Extended Source: False
..0. .... .... .... = End Device Initiator: False
Destination: 0x0000
Source: 0x4aab
Radius: 15
Sequence Number: 126
[Extended Source: TexasIns_00:14:af:e1:fb (00:12:4b:00:14:af:e1:fb)]
[Origin: 2]
ZigBee Security Header
Security Control Field: 0x28, Key Id: Network Key, Extended Nonce
...0 1... = Key Id: Network Key (0x1)
..1. .... = Extended Nonce: True
Frame Counter: 119
Extended Source: TexasIns_00:14:af:e1:fb (00:12:4b:00:14:af:e1:fb)
Key Sequence Number: 0
Message Integrity Code: 8f9500f2
[Key: 01030507090b0d0f00020406080a0c0d]
[Key Label: NUE Dimmer Code Discovered]
ZigBee Application Support Layer Data, Dst Endpt: 11, Src Endpt: 16
Frame Control Field: Data (0x00)
.... ..00 = Frame Type: Data (0x0)
.... 00.. = Delivery Mode: Unicast (0x0)
..0. .... = Security: False
.0.. .... = Acknowledgement Request: False
0... .... = Extended Header: False
Destination Endpoint: 11
Cluster: On/Off (0x0006)
Profile: Home Automation (0x0104)
Source Endpoint: 16
Counter: 27
ZigBee Cluster Library Frame, Command: Report Attributes, Seq: 8
Frame Control Field: Profile-wide (0x08)
.... ..00 = Frame Type: Profile-wide (0x0)
.... .0.. = Manufacturer Specific: False
.... 1... = Direction: Server to Client
...0 .... = Disable Default Response: False
Sequence Number: 8
Command: Report Attributes (0x0a)
Attribute Field
Attribute: OnOff (0x0000)
Data Type: 8-Bit Unsigned Integer (0x20)
On/off Control: On (0x01)
It seems we have the same issue again, it looks like the messages are send by the coordinator.
I'm wondering if you are able to control the device
Can you send to zigbee2mqtt/0x00124b0014afe1fb/set payload ON or OFF
Yes!!!! That (and 'off') now control a switch from the 2 gang (FB56+ZSW1HKJ1.7) switch! Great work!
How does the handler need to be setup (code wise) to reach the various different end-points for the different gang switches? This is something I still don't follow due to my lack of programming skills... Once I work this out I will start to compile a list of the models I have and hopefully get them up and running!
What else do you need me to try to help with in regards to some of the other bugs still present?
Further to the above, after looking through the Z2M logs, I noticed the other dimmer device wasn't paired, so I have paired it. I'm unsure if it was this or something happened on its own when I was trying to send "on1", "on2" etc, but I left it for a bit while I reviewed the earlier sniffing logs and now the on/off commands do not work, and this error appears:
zigbee2mqtt:info 2019-1-24 12:36:26 Zigbee publish to device '0x00124b0014afe1fb', genOnOff - on
- {} - {"manufSpec":0,"disDefaultRsp":0} - null
With the following you should be able to control both:
{
zigbeeModel: ['FB56+ZSW1HKJ1.7'],
model: 'TODO',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'Basic, On/Off, Scenes, Groups',
fromZigbee: [fz.generic_state],
toZigbee: [tz.on_off],
ep: (device) => {
return {'left': 16, 'right': 17};
},
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
execute(ep16, [(cb) => ep16.bind('genOnOff', coordinator, cb)], () => {
const ep17 = shepherd.find(ieeeAddr, 17);
execute(ep17, [(cb) => ep17.bind('genOnOff', coordinator, cb)], callback);
});
},
}
Using: zigbee2mqtt/0x00124b0014afe1fb/left/set and zigbee2mqtt/0x00124b0014afe1fb/right/set
Thanks Koen, yes this does indeed work for both switches! I've added the pull request and included the specific model.
I do get this message in the log - unsure if this needs to be addressed?
zigbee2mqtt:debug 2019-1-27 14:04:03 Received zigbee message of type 'devChange' with data '{"cid":"genOnOff","data":{"onOff":0}}' of device 'FB56+ZSW1HKJ1.7' (0x00124b0014afe1fb)
zigbee2mqtt:warn 2019-1-27 14:04:03 No converter available for 'HGZB-042' with cid 'genOnOff', type 'devChange' and data '{"cid":"genOnOff","data":{"onOff":0}}'
Moving forward, how would I learn what the device is wanting in regards to these strings? i.e., I have a three gang switch to also port in, I'd imagine this would work similarly, but I don't recall ever seeing and "lefts" or "rights" mentioned in the sniffer logs of the 2 gang switch. Is this a Zigbee standard thing or is this just based on your device handler?
Thanks again, I'll keep pushing forward with the rest of these.
@highground88 the left right thing is just a mapping done by zigbee2mqtt to address the right endpoint. You can name it whatever you want as long as it is in the following array: https://github.com/Koenkk/zigbee2mqtt/blob/master/lib/extension/devicePublish.js#L8
Can you try adding to https://github.com/Koenkk/zigbee2mqtt/blob/master/lib/zapp/cie.js#L15 cieClusters.init('genOnOff', 'dir', {value: 1}); and check when you press the button on the switch; if it is still reported by the coordinator?
Let me know if you are still interested in supporting this device, Ive probably found a way to.
@koenkk , yes definitely mate, thank you. The next time I'm home to try will probably be this weekend
@highground88 good, you should use the following firmware: https://drive.google.com/open?id=1QPs4aDKQE4wTmaHlh-GBtDYrtuKCDml8
I have good confidence that this will fix the problems.
Thanks very much Koen - shall I try with a vanilla Hassio install or ?
I prefer vanilla, as it allows for faster development (easier to change files).
OK great - I'll try to rebuild a Pi for testing. I also found this: Feibit Chart which is from THIS THREAD for those following along...
I am indeed getting feedback now with the new fw and Hassio (v1.1.1), thank you very much! @Koenkk
EDIT: About 24 hrs and 15 edits later.....progress. Very sorry about the length of this post....
FB56+ZSW1HKJ1.7 (2 GANG LIGHT SWITCH)
I originally wasn't getting feedback MQTT messages from the device button presses, but after using this device handler (which was just experimentation from comparing other devices), I now get them. I don't know that these are correct/optimised even though they appear to work, so I'd like to check with you before creating a pull request and moving onto some of the other models.
devices.js
{
zigbeeModel: ['FB56+ZSW1HKJ1.7'],
model: 'HGZB-042',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'Basic, On/Off, Scenes, Groups',
fromZigbee: [fz.nue_power_state],
ep: (device) => {
return {'left': 16, 'right': 17};
},
toZigbee: [tz.on_off],
ep: (device) => {
return {'left': 16, 'right': 17};
},
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
execute(ep16, [(cb) => ep16.bind('genOnOff', coordinator, cb)], () => {
const ep17 = shepherd.find(ieeeAddr, 17);
execute(ep17, [(cb) => ep17.bind('genOnOff', coordinator, cb)], callback);
});
},
},
I have some confusion with the MQTT status message below re the first 'state:' not changing (relevant?), and whether 'fz.ignore_onoff_change' and/or if 'fz.generic_state' is needed or would cause issues? The first state topic doesn't seem to reflect on whether left, right, both or none are on or off.
e.g:
Left ON/OFF
{"state":"OFF","linkquality":70,"state_left":"ON","state_right":"OFF"}
{"state":"OFF","linkquality":70,"state_left":"OFF","state_right":"OFF"}
Right ON/OFF
{"state":"OFF","linkquality":70,"state_left":"OFF","state_right":"ON"}
{"state":"OFF","linkquality":70,"state_left":"OFF","state_right":"OFF"}
Both ON
{"state":"OFF","linkquality":70,"state_left":"ON","state_right":"ON"}
The below manually added HA entities both work in all directions (more experimenting/guessing).
configuration.yaml
light:
- platform: "mqtt"
name: "TEST LEFT"
state_topic: "zigbee2mqtt/2Gang"
availability_topic: "zigbee2mqtt/bridge/state"
payload_off: "OFF"
payload_on: "ON"
value_template: "{{ value_json.state_left }}"
command_topic: "zigbee2mqtt/2Gang/left/set"
unique_id: 0x00124b001xxxxxxbL
- platform: "mqtt"
name: "TEST RIGHT"
state_topic: "zigbee2mqtt/2Gang"
availability_topic: "zigbee2mqtt/bridge/state"
payload_off: "OFF"
payload_on: "ON"
value_template: "{{ value_json.state_right }}"
command_topic: "zigbee2mqtt/2Gang/right/set"
unique_id: 0x00124b001xxxxxxbR
FB56+ZSC05HG1.0 (1 GANG DIMMER)
I have not yet had as much luck with the dimmer, but I can see that the changes in the firmware are providing a difference in the feedback, just not sure what.... This is what I have so far but the dimming and switch doesn't get recognised. I have tested and determined that the brightness range is 0 to 254, but the attribute commands sent appear to be just OnOff (only On) and then a second message stating attribute 'Current Level' and then the brightness figure (0 to 254), both endpoint 11, regardless whether it is the up or down button being used. The button also really needs to be held down, so there are pairs of these messages rapidly sent and probably out of order (see below).
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'On/Off, Level Control, Scenes, Groups, ZLL Commissioning, Power Source, Identify',
fromZigbee: [fz.generic_state, fz.ignore_onoff_change],
toZigbee: [tz.on_off],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 3, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.bind('genLevelCtrl', coordinator, cb),
(cb) => device.report('genLevelCtrl', 'currentLevel', 0, 3, 0, cb),
];
execute(device, actions, callback);
},
},
Z2M LOG output on switching:
2019-02-19T10:20:23.012Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
2019-02-19T10:20:23.273Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-02-19T10:20:23.281Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
ZigBee Cluster Library Frame, Command: Read Attributes Response, Seq: 255
Frame Control Field: Profile-wide (0x18)
.... ..00 = Frame Type: Profile-wide (0x0)
.... .0.. = Manufacturer Specific: False
.... 1... = Direction: Server to Client
...1 .... = Disable Default Response: True
Sequence Number: 255
Command: Read Attributes Response (0x01)
Status Record
Attribute: OnOff (0x0000)
Status: Success (0x00)
Data Type: 8-Bit Unsigned Integer (0x20)
On/off Control: On (0x01)
ZigBee Cluster Library Frame, Command: Read Attributes Response, Seq: 250
Frame Control Field: Profile-wide (0x18)
.... ..00 = Frame Type: Profile-wide (0x0)
.... .0.. = Manufacturer Specific: False
.... 1... = Direction: Server to Client
...1 .... = Disable Default Response: True
Sequence Number: 250
Command: Read Attributes Response (0x01)
Status Record
Attribute: Current Level (0x0000)
Status: Success (0x00)
Data Type: 8-Bit Unsigned Integer (0x20)
Current Level: 116
Let's do one device at a time and start with FB56+ZSW1HKJ1.7.
Can you try with:
devices.js
{
zigbeeModel: ['FB56+ZSW1HKJ1.7'],
model: 'HGZB-042',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'on/off',
fromZigbee: [fz.generic_state_multi_ep],
toZigbee: [tz.on_off],
ep: (device) => {
return {'left': 16, 'right': 17};
},
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
execute(ep16, [(cb) => ep16.bind('genOnOff', coordinator, cb)], () => {
const ep17 = shepherd.find(ieeeAddr, 17);
execute(ep17, [(cb) => ep17.bind('genOnOff', coordinator, cb)], callback);
});
},
},
fromZigbee.js
generic_state_multi_ep: {
cid: 'genOnOff',
type: 'attReport',
convert: (model, msg, publish, options) => {
const ep = msg.endpoints[0];
const key = `state_${getKey(model.ep(ep.device), ep.epId)}`;
const payload = {};
payload[key] = msg.data.data['onOff'] === 1 ? 'ON' : 'OFF';
return payload;
},
},
Thanks @Koenkk . Is there a better way to modify the fromZigbee.js files than using a seperate install of Hassbian and the CLI via Putty on a Windows machine? I really hate+struggle with vi. I've tried using the Portainer addon and it's CLI, but obviously the changes aren't persistent.
The setup prior I did with Hassio 1.1.1, the almost instant modifications of the devices.js file is awesome.
I'm getting the following error:
pi@hassbian:/opt/zigbee2mqtt $ npm start
> [email protected] start /opt/zigbee2mqtt
> node index.js
zigbee2mqtt:info 2/21/2019, 1:03:05 PM Logging to directory: 'data/log/2019-02-21.13-03-05'
zigbee2mqtt:debug 2/21/2019, 1:03:05 PM Removing old log directory 'data/log/2019-02-21.12-19-44'
zigbee2mqtt:debug 2/21/2019, 1:03:06 PM Using zigbee-shepherd with settings: '{"net":{"panId":6754,"channelList":[11],"precfgkey":[1,3,5,7,9,11,13,15,0,2,4,6,8,10,12,13]},"dbPath":"/opt/zigbee2mqtt/data/database.db","sp":{"baudRate":115200,"rtscts":true}}'
zigbee2mqtt:debug 2/21/2019, 1:03:06 PM Loaded state from file /opt/zigbee2mqtt/data/state.json
zigbee2mqtt:info 2/21/2019, 1:03:06 PM Starting zigbee2mqtt version 1.1.1 (commit #92d88b6)
zigbee2mqtt:info 2/21/2019, 1:03:06 PM Starting zigbee-shepherd
zigbee2mqtt:info 2/21/2019, 1:03:07 PM zigbee-shepherd started
zigbee2mqtt:info 2/21/2019, 1:03:07 PM Coordinator firmware version: '20190217'
zigbee2mqtt:debug 2/21/2019, 1:03:07 PM zigbee-shepherd info: {"enabled":true,"net":{"state":"Coordinator","channel":11,"panId":"0x1a62","extPanId":"0xdddddddddddddddd","ieeeAddr":"0x00124b0014bdea20","nwkAddr":0},"firmware":{"transportrev":2,"product":0,"version":"2.6.3","revision":20190217},"startTime":1550754187,"joinTimeLeft":0}
zigbee2mqtt:info 2/21/2019, 1:03:07 PM Currently 0 devices are joined:
zigbee2mqtt:warn 2/21/2019, 1:03:07 PM `permit_join` set to `true` in configuration.yaml.
zigbee2mqtt:warn 2/21/2019, 1:03:07 PM Allowing new devices to join.
zigbee2mqtt:warn 2/21/2019, 1:03:07 PM Set `permit_join` to `false` once you joined all devices.
zigbee2mqtt:info 2/21/2019, 1:03:07 PM Zigbee: allowing new devices to join.
zigbee2mqtt:info 2/21/2019, 1:03:07 PM Connecting to MQTT server at mqtt://192.168.0.101
zigbee2mqtt:info 2/21/2019, 1:03:08 PM zigbee-shepherd ready
zigbee2mqtt:info 2/21/2019, 1:03:08 PM Connected to MQTT server
zigbee2mqtt:info 2/21/2019, 1:03:08 PM MQTT publish: topic 'zigbee2mqtt/bridge/state', payload 'online'
zigbee2mqtt:debug 2/21/2019, 1:03:08 PM Mounted the cieApp (epId 11)
zigbee2mqtt:error 2/21/2019, 1:04:05 PM Cannot get the Node Descriptor of the Device: 0x00124b0014afe1fb (Error: Timed out after 10000 ms)
@highground88 can you try to repair the device? (I don't understand why you didn't get this error before, what has been changed?)
The above log was whilst trying to re-pair.
Not really sure what broke - I upgraded to 0.88.0, and also the latest Z2M, then did the changes you suggested. I will try having a play around to see if anything fixes it.
I've not been able to determine what happened, but I've started fresh with a new 0.88.1 build, and the new code does produce accurate MQTT feedback ({"state_left":"ON","linkquality":52,"state_right":"ON"}).
I can't fault anything function wise now, but I have the following message appearing in Z2M:
zigbee2mqtt:debug 2/22/2019, 12:44:15 PM Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'FB56+ZSW1HKJ1.7' (0x00124b0014afe1fb)
zigbee2mqtt:info 2/22/2019, 12:44:15 PM MQTT publish: topic 'zigbee2mqtt/0x00124b0014afe1fb', payload '{"state_left":"ON","linkquality":52,"state_right":"ON"}'
zigbee2mqtt:debug 2/22/2019, 12:44:15 PM Received zigbee message of type 'devChange' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'FB56+ZSW1HKJ1.7' (0x00124b0014afe1fb)
zigbee2mqtt:warn 2/22/2019, 12:44:15 PM No converter available for 'HGZB-042' with cid 'genOnOff', type 'devChange' and data '{"cid":"genOnOff","data":{"onOff":1}}'
Is it normal that the model 'HGZB-042' would appear rather than zigbee model 'FB56+ZSW1HKJ1.7'?
Yes, that's the model you mapped it to:
Can you try with (should get rid of no converter available message)
devices.js
{
zigbeeModel: ['FB56+ZSW1HKJ1.7'],
model: 'HGZB-042',
vendor: 'Nue',
description: 'Smart light switch - 2 gang',
supports: 'on/off',
fromZigbee: [fz.generic_state_multi_ep, fz.ignore_onoff_change],
toZigbee: [tz.on_off],
ep: (device) => {
return {'left': 16, 'right': 17};
},
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep16 = shepherd.find(ieeeAddr, 16);
execute(ep16, [(cb) => ep16.bind('genOnOff', coordinator, cb)], () => {
const ep17 = shepherd.find(ieeeAddr, 17);
execute(ep17, [(cb) => ep17.bind('genOnOff', coordinator, cb)], callback);
});
},
},
fromZigbee.js
generic_state_multi_ep: {
cid: 'genOnOff',
type: 'attReport',
convert: (model, msg, publish, options) => {
const ep = msg.endpoints[0];
const key = `state_${getKey(model.ep(ep.device), ep.epId)}`;
const payload = {};
payload[key] = msg.data.data['onOff'] === 1 ? 'ON' : 'OFF';
return payload;
},
},
If everything works, please make a PR.
Great! Well done, the FB56+ZSW1HKJ1.7 is now working! I've created a PR (sorry I made 2, couldnt work out how to merge the 2 files into 1 PR).
Are you happy to help me get the tough looking one (FB56+ZSC05HG1.0 dimmer) supported or have I worn out my welcome? :-) Thanks @Koenkk 馃
Let's continue with the FB56+ZSW1HKJ1.7 indeed, is this a 1 or 2 gang switch?
Can you try with, this should allow you to control on/off and brightness:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
fromZigbee: [tz.on_off, tz.light_brightness],
toZigbee: [fz.state, fz.ignore_onoff_change],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 3, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.bind('genLevelCtrl', coordinator, cb),
(cb) => device.report('genLevelCtrl', 'currentLevel', 0, 3, 0, cb),
];
execute(device, actions, callback);
},
},
Thanks again mate.
So this switch is a single output switch, the centre button being on/off, and then the top/bottom switches control the dimming (vertically orientated, top is increase).
The above code results in:
zigbee2mqtt:error 2/24/2019, 1:13:58 AM Failed to configure 0x00124b001545a430 (0x00124b001545a430) ('TypeError: Cannot read property 'status' of undefined')
Debug output:
cc-znp:AREQ <-- AF:incomingMsg, { groupid: 0, clusterid: 8, srcaddr: 3112, srcendpoint: 11, dstendpoint: 1, wasbroadcast: 0, linkquality: 81, securityuse: 0, timestamp: 15444799, transseqnumber: 0, len: 5, data: <Buffer 18 01 0b 06 82> } +5ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +21ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +37ms
serialport:unixRead waiting for readable because of code: EAGAIN +21ms
serialport:poller Polling for "readable" +36ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +21ms
zigbee-shepherd-converters:devices Configured '(cb) => device.report('genLevelCtrl', 'currentLevel', 0, 3, 0, cb)' with result 'TypeError: Cannot read property 'status' of undefined' +549ms
zigbee2mqtt:error 2/24/2019, 1:18:33 AM Failed to configure 0x00124b001545a430 (0x00124b001545a430) ('TypeError: Cannot read property 'status' of undefined')
This is a previous sniffing session of this device (device is 0x9430) LINK
Let me know if you need anything else. Thank you.
Do you get any output when switching on/off? Can you switch the device on/off via zigbee2mqtt?
No, no MQTT messages and no feedback when physically pressing the switch
Every wireshark line has a number (No.), can you provide the numbers of the commands when manually turning the switch on/off?
I've just created two new files for you (previous link) that have only the ON/OFF, and an INCREASE (both momentarily pressed and held). Let me know if this is okay
The device isn't reporting anything, can you try with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
fromZigbee: [tz.on_off, tz.light_brightness],
toZigbee: [fz.state, fz.ignore_onoff_change],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 1000, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(device, actions, callback);
},
},
No errors with that code, but no feedback via MQTT or on Z2M (except in shepherd debug). I also deleted the database. However sending "zigbee2mqtt/0x00124b001545a430/set ON" ends up crashing Z2M.
zigbee2mqtt:info 2/25/2019, 1:42:27 AM Device incoming...
zigbee2mqtt:info 2/25/2019, 1:42:27 AM MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"pairing","message":"device incoming"}'
zigbee2mqtt:debug 2/25/2019, 1:42:27 AM Configuring 0x00124b001545a430 (0x00124b001545a430) ...
zigbee2mqtt:debug 2/25/2019, 1:42:27 AM Received zigbee message of type 'devStatus' with data '"online"' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:info 2/25/2019, 1:42:28 AM Succesfully configured 0x00124b001545a430 (0x00124b001545a430)
zigbee2mqtt:debug 2/25/2019, 1:42:54 AM Received MQTT message on 'zigbee2mqtt/0x00124b001545a430/set' with data 'ON'
/opt/zigbee2mqtt/lib/extension/devicePublish.js:140
const converter = converters.find((c) => c.key.includes(key));
^
TypeError: Cannot read property 'key' of undefined
at converters.find (/opt/zigbee2mqtt/lib/extension/devicePublish.js:140:56)
at Array.find (<anonymous>)
at keys.forEach (/opt/zigbee2mqtt/lib/extension/devicePublish.js:140:42)
at Array.forEach (<anonymous>)
at DevicePublish.onMQTTMessage (/opt/zigbee2mqtt/lib/extension/devicePublish.js:139:14)
at results.extensions.filter.map (/opt/zigbee2mqtt/lib/controller.js:134:27)
at Array.map (<anonymous>)
at Controller.onMQTTMessage (/opt/zigbee2mqtt/lib/controller.js:134:14)
at MQTT.onMessage (/opt/zigbee2mqtt/lib/mqtt.js:81:18)
at MqttClient.emit (events.js:189:13)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node index.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2019-02-25T01_42_55_088Z-debug.log
In that linked folder is the debug log 2019-02-25T01_50_26_446Z-debug.log
I've also done a full itemised capture, named DIMMER -JOIN,ON,OFF,UP,DOWN,CRASH.pcapng
PCAP capture:
The logs don't seem to be representative of what I'm seeing in the console with debug activated in configuration.yaml. This is the snippet from a ON press:
zigbee2mqtt:info 2/25/2019, 2:24:49 AM MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"pairing","message":"device incoming"}'
zigbee2mqtt:debug 2/25/2019, 2:24:49 AM Received zigbee message of type 'devStatus' with data '"online"' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee-shepherd Device: 0x00124b001545a430 already in network +31s
serialport:poller received "readable" +1m
serialport:bindings read +1m
serialport:unixRead Starting read +1m
serialport:unixRead Finished read 8 bytes +1ms
serialport:main binding.read finished +1m
cc-znp { sof: 254,
cc-znp len: 3,
cc-znp type: 'AREQ',
cc-znp subsys: 'ZDO',
cc-znp cmd: 'srcRtgInd',
cc-znp payload: { dstaddr: 18909, relaycount: 0, relaylist: <Buffer > },
cc-znp fcs: 22,
cc-znp csum: 22 } +1m
serialport:main _read reading +12ms
serialport:bindings read +15ms
serialport:unixRead Starting read +14ms
cc-znp:AREQ <-- ZDO:srcRtgInd, { dstaddr: 18909, relaycount: 0, relaylist: <Buffer > } +7ms
zigbee-shepherd:msgHdlr IND <-- ZDO:srcRtgInd +1m
serialport:unixRead Finished read 33 bytes +4ms
serialport:main binding.read finished +6ms
cc-znp { sof: 254,
cc-znp len: 28,
cc-znp type: 'AREQ',
cc-znp subsys: 'AF',
cc-znp cmd: 'incomingMsg',
cc-znp payload:
cc-znp { groupid: 0,
cc-znp clusterid: 6,
cc-znp srcaddr: 18909,
cc-znp srcendpoint: 11,
cc-znp dstendpoint: 1,
cc-znp wasbroadcast: 0,
cc-znp linkquality: 84,
cc-znp securityuse: 0,
cc-znp timestamp: 15186867,
cc-znp transseqnumber: 0,
cc-znp len: 8,
cc-znp data: <Buffer 18 f0 01 00 00 00 20 01> },
cc-znp fcs: 160,
cc-znp csum: 160 } +13ms
serialport:main _read reading +15ms
serialport:bindings read +21ms
serialport:unixRead Starting read +16ms
cc-znp:AREQ <-- AF:incomingMsg, { groupid: 0, clusterid: 6, srcaddr: 18909, srcendpoint: 11, dstendpoint: 1, wasbroadcast: 0, linkquality: 84, securityuse: 0, timestamp: 15186867, transseqnumber: 0, len: 8, data: <Buffer 18 f0 01 00 00 00 20 01> } +7ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +1m
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +29ms
serialport:unixRead waiting for readable because of code: EAGAIN +14ms
serialport:poller Polling for "readable" +51ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +12ms
Just a reminder (and I'm not sure if relevant?), this switch has a different encryption key than the other models.... it's listed in the folder.
I hate this switch. Thanks Koen.
Can you try this:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
fromZigbee: [tz.on_off, tz.light_brightness],
toZigbee: [fz.generic_state, fz.ignore_onoff_change],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 1000, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(device, actions, callback);
},
},
Same as above - no errors, no feedback except for in the DEBUG=* output. MQTT still crashes on sending ON to that devices (doesn't crash if a fake ID is used).
Debug output (OFF):
```
zigbee2mqtt:info 2/26/2019, 4:51:54 AM Succesfully configured 0x00124b001545a430 (0x00124b001545a430)
serialport:poller received "readable" +5s
serialport:bindings read +5s
serialport:unixRead Starting read +5s
serialport:unixRead Finished read 33 bytes +1ms
serialport:main binding.read finished +5s
cc-znp { sof: 254,
cc-znp len: 28,
cc-znp type: 'AREQ',
cc-znp subsys: 'AF',
cc-znp cmd: 'incomingMsg',
cc-znp payload:
cc-znp { groupid: 0,
cc-znp clusterid: 6,
cc-znp srcaddr: 48528,
cc-znp srcendpoint: 11,
cc-znp dstendpoint: 1,
cc-znp wasbroadcast: 0,
cc-znp linkquality: 70,
cc-znp securityuse: 0,
cc-znp timestamp: 11850307,
cc-znp transseqnumber: 0,
cc-znp len: 8,
cc-znp data:
cc-znp fcs: 123,
cc-znp csum: 123 } +5s
serialport:main _read reading +14ms
serialport:bindings read +16ms
serialport:unixRead Starting read +16ms
cc-znp:AREQ <-- AF:incomingMsg, { groupid: 0, clusterid: 6, srcaddr: 48528, srcendpoint: 11, dstendpoint: 1, wasbroadcast: 0, linkquality: 70, securityuse: 0, timestamp: 11850307, transseqnumber: 0, len: 8, data:
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +5s
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +5s
serialport:unixRead waiting for readable because of code: EAGAIN +25ms
serialport:poller Polling for "readable" +43ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +23ms
**Debug output (ON):**
serialport:poller received "readable" +60s
serialport:bindings read +60s
serialport:unixRead Starting read +60s
serialport:unixRead Finished read 8 bytes +2ms
serialport:main binding.read finished +60s
cc-znp { sof: 254,
cc-znp len: 3,
cc-znp type: 'AREQ',
cc-znp subsys: 'ZDO',
cc-znp cmd: 'srcRtgInd',
cc-znp payload: { dstaddr: 48528, relaycount: 0, relaylist:
cc-znp csum: 175 } +60s
serialport:main _read reading +15ms
serialport:bindings read +19ms
serialport:unixRead Starting read +17ms
cc-znp:AREQ <-- ZDO:srcRtgInd, { dstaddr: 48528, relaycount: 0, relaylist:
serialport:unixRead Finished read 33 bytes +3ms
serialport:main binding.read finished +6ms
cc-znp { sof: 254,
cc-znp len: 28,
cc-znp type: 'AREQ',
cc-znp subsys: 'AF',
cc-znp cmd: 'incomingMsg',
cc-znp payload:
cc-znp { groupid: 0,
cc-znp clusterid: 6,
cc-znp srcaddr: 48528,
cc-znp srcendpoint: 11,
cc-znp dstendpoint: 1,
cc-znp wasbroadcast: 0,
cc-znp linkquality: 60,
cc-znp securityuse: 0,
cc-znp timestamp: 12036998,
cc-znp transseqnumber: 0,
cc-znp len: 8,
cc-znp data:
cc-znp fcs: 190,
cc-znp csum: 190 } +12ms
serialport:main _read reading +14ms
serialport:bindings read +20ms
serialport:unixRead Starting read +16ms
cc-znp:AREQ <-- AF:incomingMsg, { groupid: 0, clusterid: 6, srcaddr: 48528, srcendpoint: 11, dstendpoint: 1, wasbroadcast: 0, linkquality: 60, securityuse: 0, timestamp: 12036998, transseqnumber: 0, len: 8, data:
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +60s
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +32ms
serialport:unixRead waiting for readable because of code: EAGAIN +17ms
serialport:poller Polling for "readable" +58ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +16ms
```
Before continuing with anything else, let's first fix the crash when sending the on command, can you updated to the latest dev and check with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
fromZigbee: [tz.on_off, tz.light_brightness],
toZigbee: [fz.state, fz.ignore_onoff_change],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 1000, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(device, actions, callback);
},
},
I've updated both my Hassio pi (edge build) and also pulled the latest dev on my Hassbian pi - unfortunately both still crash on sending an ON to only that device, and there is no feedback either way. The device does join etc without errors. Sending on to other devices even if offline doesn't crash the program.
Please let me know if/what logs etc you need to help. Thanks!
When it crashes I also don't expect any feedback. Can you provide the zigbee2mqtt log when this crash happens?
zigbee2mqtt:info 2/27/2019, 6:46:04 AM MQTT publish: topic 'zigbee2mqtt/bridge/state', payload 'online'
zigbee2mqtt:info 2/27/2019, 6:46:04 AM MQTT publish: topic 'zigbee2mqtt/bridge/config', payload '{"log_level":"info","permit_join":true}'
zigbee2mqtt:info 2/27/2019, 6:46:05 AM Succesfully configured 0x00124b001545a430 (0x00124b001545a430)
zigbee2mqtt:error 2/27/2019, 6:46:07 AM Failed to find device with ieeAddr: '0x00124b000ae5fa3e'
zigbee2mqtt:info 2/27/2019, 6:46:07 AM MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"entity_not_found","message":"0x00124b000ae5fa3e"}'
zigbee2mqtt:warn 2/27/2019, 6:46:07 AM Cannot handle MQTT message on 'zigbee2mqtt/0x00124b000ae5fa3e/set' with data 'ON'
zigbee2mqtt:error 2/27/2019, 6:46:14 AM Failed to find device with ieeAddr: '0x00124b000ae5fa3e'
zigbee2mqtt:info 2/27/2019, 6:46:14 AM MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"entity_not_found","message":"0x00124b000ae5fa3e"}'
zigbee2mqtt:warn 2/27/2019, 6:46:14 AM Cannot handle MQTT message on 'zigbee2mqtt/0x00124b000ae5fa3e/set' with data 'ON'
zigbee2mqtt:error 2/27/2019, 6:46:15 AM Failed to find device with ieeAddr: '0x00124b000ae5fa3e'
zigbee2mqtt:info 2/27/2019, 6:46:15 AM MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"entity_not_found","message":"0x00124b000ae5fa3e"}'
zigbee2mqtt:warn 2/27/2019, 6:46:15 AM Cannot handle MQTT message on 'zigbee2mqtt/0x00124b000ae5fa3e/set' with data 'ON'
zigbee2mqtt:info 2/27/2019, 6:43:07 AM New device 'FB56+ZSC05HG1.0' with address 0x00124b001545a430 connected!
zigbee2mqtt:info 2/27/2019, 6:43:07 AM MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"device_connected","message":"0x00124b001545a430","meta":{"modelID":"FB56+ZSC05HG1.0"}}'
zigbee2mqtt:info 2/27/2019, 6:43:08 AM Succesfully configured 0x00124b001545a430 (0x00124b001545a430)
/opt/zigbee2mqtt/lib/extension/devicePublish.js:206
const converter = converters.find((c) => c.key.includes(key));
^
TypeError: Cannot read property 'includes' of undefined
at converters.find (/opt/zigbee2mqtt/lib/extension/devicePublish.js:206:60)
at Array.find (<anonymous>)
at keys.forEach (/opt/zigbee2mqtt/lib/extension/devicePublish.js:206:42)
at Array.forEach (<anonymous>)
at DevicePublish.onMQTTMessage (/opt/zigbee2mqtt/lib/extension/devicePublish.js:205:14)
at results.extensions.filter.map (/opt/zigbee2mqtt/lib/controller.js:149:27)
at Array.map (<anonymous>)
at Controller.onMQTTMessage (/opt/zigbee2mqtt/lib/controller.js:149:14)
at MQTT.onMessage (/opt/zigbee2mqtt/lib/mqtt.js:81:18)
at MqttClient.emit (events.js:189:13)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node index.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2019-02-27T06_43_36_293Z-debug.log
The above message shows a previously paired device (offline) message (a3e), vs the dimmer device (430)
Omg, what a stupid mistake of me, I swapped the from and to zigbee converters, please try with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
toZigbee: [tz.on_off, tz.light_brightness],
fromZigbee: [fz.state, fz.ignore_onoff_change],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 1000, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(device, actions, callback);
},
},
Good pick up!! I went through it a few times looking in case I had entered something wrong and didn't see it ... and the even better news is that set ON works! I get zigbee2mqtt/Dimmer {"state":"ON"} as a response to zigbee2mqtt/0x00124b001545a430/set ON.
No feedback other than:
2019-02-27T10:24:49.613Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-02-27T10:24:49.620Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
when physically pressing the switch. No dimming yet either.
Can you control the brightness with {"brightness": 125}?
as in: zigbee2mqtt/0x00124b001545a430/brightness 125?
I've tried this but I don't think so - my issue is I dont have any lights attached and can't tell current level. But if it is switched off, the above command does not turn it on and there is no mqtt reply to that command.
EDIT - actually let me delete db and try again ... started trying some of your first earlier suggestions with the to's and from's swapped and came back to the final one, but aren't getting responses to on/off any more (TL;DR I broke something)
Fixed my issue, but no change - no response to dimmer on your latest suggestion:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
toZigbee: [tz.on_off, tz.light_brightness],
fromZigbee: [fz.state, fz.ignore_onoff_change],
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const device = shepherd.find(ieeeAddr, 11);
const cfg = {direction: 0, attrId: 0, dataType: 16, minRepIntval: 0, maxRepIntval: 1000, repChange: 0};
const actions = [
(cb) => device.bind('genOnOff', coordinator, cb),
(cb) => device.foundation('genOnOff', 'configReport', [cfg], foundationCfg, cb),
];
execute(device, actions, callback);
},
},
Can you post your log when executing this brightness command? correct payload is {"brightness": 125}
That looks to be working, although the switch itself does not light up like it would when switched ON
MQTT feedback:
{"state":"ON","brightness":125}
(switch was OFF, still is OFF physically, but ON in HA now [incorrect])
Still no feedback from physical press
LOG:
zigbee2mqtt:info 2/27/2019, 9:54:30 PM Succesfully configured Dimmer (0x00124b001545a430)
zigbee2mqtt:debug 2/27/2019, 9:54:48 PM Received MQTT message on 'zigbee2mqtt/0x00124b001545a430/set' with data '{"brightness": 125}'
zigbee2mqtt:info 2/27/2019, 9:54:48 PM Zigbee publish to device '0x00124b001545a430', genLevelCtrl - moveToLevelWithOnOff - {"level":125,"transtime":0} - {"manufSpec":0,"disDefaultRsp":0} - null
2019-02-27T11:54:49.013Z zigbee-shepherd:request REQ --> AF:dataRequest, transId: 2
2019-02-27T11:54:49.036Z zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0
2019-02-27T11:54:49.060Z zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object]
2019-02-27T11:54:49.061Z zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 2
2019-02-27T11:54:49.079Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-02-27T11:54:49.086Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-02-27T11:54:49.087Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
2019-02-27T11:54:49.095Z zigbee-shepherd:request REQ --> AF:dataRequest, transId: 3
zigbee2mqtt:info 2/27/2019, 9:54:49 PM MQTT publish: topic 'zigbee2mqtt/Dimmer', payload '{"state":"ON","brightness":125}'
2019-02-27T11:54:49.123Z zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0
2019-02-27T11:54:49.146Z zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object]
2019-02-27T11:54:49.148Z zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 3
2019-02-27T11:54:49.202Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-02-27T11:54:49.207Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-02-27T11:54:49.208Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:info 2/27/2019, 9:54:49 PM Zigbee publish to device '0x00124b001545a430', genLevelCtrl - read - [{"attrId":0}] - {"manufSpec":0,"disDefaultRsp":0} - null
2019-02-27T11:54:49.245Z zigbee-shepherd:request REQ --> AF:dataRequest, transId: 4
2019-02-27T11:54:49.268Z zigbee-shepherd:request RSP <-- AF:dataRequest, status: 0
2019-02-27T11:54:49.295Z zigbee-shepherd:af dispatchIncomingMsg(): type: dataConfirm, msg: [object Object]
2019-02-27T11:54:49.296Z zigbee-shepherd:msgHdlr IND <-- AF:dataConfirm, transId: 4
2019-02-27T11:54:49.307Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-02-27T11:54:49.324Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-02-27T11:54:49.325Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 2/27/2019, 9:54:49 PM Received zigbee message of type 'devChange' with data '{"cid":"genLevelCtrl","data":{"currentLevel":125}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 2/27/2019, 9:54:49 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'devChange' and data '{"cid":"genLevelCtrl","data":{"currentLevel":125}}'
zigbee2mqtt:warn 2/27/2019, 9:54:49 PM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
Sending : {"state":"ON","brightness":125} does not first switch on the switch.
Does brightness changing work when first sending {"state":"ON"} and after that sending {"brightness":180} ?
I can only assume it does - the red switch light comes on for the ON, and then I get feedback for brightness level correctly... I will have to wire them into a light circuit in order to test further as they're currently just bench testing in another room.
FYI - Having the switch OFF, and pressing BRIGHT UP or DOWN (physical) button, turns on the switch. Still no reverse feedback.
Can you do Zigbee sniffing, please capture only the messages that are send directly after your manually turn the switch on.
No problems: Here's the results LINK
Please test with the latest dev branch, should be working now.
EDIT: also, please re-pair the device and try with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
toZigbee: [tz.on_off, tz.light_brightness],
fromZigbee: [fz.state, fz.ignore_onoff_change],
},
That's got it (mostly), thanks Koen - here are the results:
Both ON / OFF function as expected in both directions (physical generates message, mqtt push activates device). Brightness controls not working as expected :
Having the switch off, and physically pressing UP, results in the switch turning on and provides the following feedback: {"state":"ON","brightness":150,"linkquality":94}
zigbee2mqtt:info 3/1/2019, 5:07:49 PM MQTT publish: topic 'zigbee2mqtt/Dimmer', payload '{"state":"ON","brightness":131,"linkquality":94}'
zigbee2mqtt:debug 3/1/2019, 5:07:49 PM Received zigbee message of type 'devChange' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
Having the switch off, and sending {"brightness":160}, results in the switch NOT turning on and provides the following feedback: {"state":"ON","brightness":160,"linkquality":94}
zigbee2mqtt:warn 3/1/2019, 5:03:16 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'devChange' and data '{"cid":"genLevelCtrl","data":{"currentLevel":160}}'
_However the state: ON is incorrect._
Having the switch off, and sending {"state":"ON","brightness":131}, results in the switch NOT turning on and provides the following feedback: {"state":"ON","brightness":131,"linkquality":94}
```
zigbee2mqtt:debug 3/1/2019, 5:05:29 PM Received zigbee message of type 'attReport' with data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/1/2019, 5:05:29 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'attReport' and data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}'
zigbee2mqtt:warn 3/1/2019, 5:05:29 PM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
zigbee2mqtt:debug 3/1/2019, 5:05:29 PM Received zigbee message of type 'devChange' with data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:debug 3/1/2019, 5:05:29 PM Received zigbee message of type 'devChange' with data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/1/2019, 5:05:29 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'devChange' and data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}'
zigbee2mqtt:warn 3/1/2019, 5:05:29 PM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
zigbee2mqtt:warn 3/1/2019, 5:05:29 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'devChange' and data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}'
_The switch again does not actually turn ON._
-------------------------------------------------------------------------------------------------------------------
Pressing the UP or DOWN buttons results in this MQTT message `{"state":"ON","brightness":131,"linkquality":89}` , however each press does not change the brightness value at all, and the whole debug message below is one press (although it is very sensitive and appears to trigger rapidly when held even briefly, so potentially there is probably more than one)
2019-03-01T07:13:52.459Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-03-01T07:13:52.473Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-03-01T07:13:52.478Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 3/1/2019, 5:13:52 PM Received zigbee message of type 'attReport' with data '{"cid":"genLevelCtrl","data":{"currentLevel":119}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'attReport' and data '{"cid":"genLevelCtrl","data":{"currentLevel":119}}'
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
2019-03-01T07:13:52.487Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-03-01T07:13:52.492Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
zigbee2mqtt:debug 3/1/2019, 5:13:52 PM Received zigbee message of type 'devChange' with data '{"cid":"genLevelCtrl","data":{"currentLevel":119}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'devChange' and data '{"cid":"genLevelCtrl","data":{"currentLevel":119}}'
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
2019-03-01T07:13:52.500Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 3/1/2019, 5:13:52 PM Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:info 3/1/2019, 5:13:52 PM MQTT publish: topic 'zigbee2mqtt/Dimmer', payload '{"state":"ON","brightness":131,"linkquality":84}'
2019-03-01T07:13:52.553Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-03-01T07:13:52.564Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
2019-03-01T07:13:52.573Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 3/1/2019, 5:13:52 PM Received zigbee message of type 'attReport' with data '{"cid":"genLevelCtrl","data":{"currentLevel":116}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'attReport' and data '{"cid":"genLevelCtrl","data":{"currentLevel":116}}'
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
2019-03-01T07:13:52.580Z zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object]
2019-03-01T07:13:52.586Z zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0
zigbee2mqtt:debug 3/1/2019, 5:13:52 PM Received zigbee message of type 'devChange' with data '{"cid":"genLevelCtrl","data":{"currentLevel":116}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'devChange' and data '{"cid":"genLevelCtrl","data":{"currentLevel":116}}'
zigbee2mqtt:warn 3/1/2019, 5:13:52 PM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
2019-03-01T07:13:52.593Z zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object]
zigbee2mqtt:debug 3/1/2019, 5:13:52 PM Received zigbee message of type 'attReport' with data '{"cid":"genOnOff","data":{"onOff":1}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:info 3/1/2019, 5:13:52 PM MQTT publish: topic 'zigbee2mqtt/Dimmer', payload '{"state":"ON","brightness":131,"linkquality":94}'
```
Please update to the latest dev branch (don't forget to do a rm -rf node_modules && npm install afterwards, and try with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
toZigbee: [tz.on_off, tz.light_brightness],
fromZigbee: [fz.state, fz.ignore_onoff_change],
},
Hi,
I am on hass.io using the stable addon. I have the Nue Smart Dimmer (HGZB-02A) dimmer which is not supported. Its brother (HGZB-01A) is already supported.
https://www.amazon.co.uk/gp/product/B07GSK1HVP/ref=ppx_yo_dt_b_asin_title_o02_s00?ie=UTF8&psc=1
Can you add support please? The database log is below.
Thanks
{"id":8,"type":"Router","ieeeAddr":"0x00158d00025c04e5","nwkAddr":10637,"manufId":4478,"manufName":"FeiBit","powerSource":"Mains (single phase)","modelId":"FNB56-ZSC01LX1.2","epList":[1],"status":"online","joinTime":1551604468,"endpoints":{"1":{"profId":49246,"epId":1,"devId":256,"inClusterList":[0,3,4,5,6,8,4096],"outClusterList":[25],"clusters":{"genBasic":{"dir":{"value":1},"attrs":{}},"genIdentify":{"dir":{"value":1},"attrs":{}},"genGroups":{"dir":{"value":1},"attrs":{}},"genScenes":{"dir":{"value":1},"attrs":{}},"genOnOff":{"dir":{"value":1},"attrs":{}},"genLevelCtrl":{"dir":{"value":1},"attrs":{}},"genOta":{"dir":{"value":2},"attrs":{}},"lightLink":{"dir":{"value":1},"attrs":{}}}}},"_id":"RtCmymnDqy3UpM7r"}
Ok, I've done as you've suggested, here are the results. Thanks Koen.... it's been 8 months of trying today!!
ON/OFF work fine.
Pressing DOWN results in this: {"state":"ON","linkquality":99,"brightness":180}
Pressing UP results in the same (no brightness change)
Sending {"brightness":180} whilst ON appears to work correctly: {"state":"ON","linkquality":99,"brightness":180}
Sending {"brightness":170} while OFF results in this: {"state":"OFF","linkquality":97,"brightness":170} (device remains OFF, brightness level changes).
Error from debug:
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +9ms
zigbee2mqtt:debug 3/3/2019, 12:59:38 PM Received zigbee message of type 'attReport' with data '{"cid":"genLevelCtrl","data":{"currentLevel":230}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/3/2019, 12:59:38 PM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'attReport' and data '{"cid":"genLevelCtrl","data":{"currentLevel":230}}'
Is anything not working now?
Yes, sorry I didn't write that well... Physically pressing UP and DOWN doesn't send any changes to MQTT. I'll try to get a better example in the morning when I wake up
It's logical that we don't receive brightness updates has we haven't added a converter for it, please try with:
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH',
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
toZigbee: [tz.on_off, tz.light_brightness],
fromZigbee: [fz.state, fz.ignore_onoff_change, fz.brightness_report],
},
Great - this seems to be working now, the physical buttons are outputting brightness updates between 1-254.
There is still this error in debug, but perhaps you were expecting that?
zigbee2mqtt:debug 3/4/2019, 1:12:40 AM Received zigbee message of type 'devChange' with data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}' of device 'FB56+ZSC05HG1.0' (0x00124b001545a430)
zigbee2mqtt:warn 3/4/2019, 1:12:40 AM No converter available for 'TESTING-DIMMER SWITCH' with cid 'genLevelCtrl', type 'devChange' and data '{"cid":"genLevelCtrl","data":{"currentLevel":131}}'
I imagine this will work for @Eeeeeediot and his 'FNB56-ZSC01LX1.2' switch, which should have the same functionality as mine minus the physical buttons. Perhaps when this one is included we can add that model number in if he's not capable of testing prior?
Good! The last missing piece to get rid of this message is:
devices.js
{
zigbeeModel: ['FB56+ZSC05HG1.0'],
model: 'TESTING-DIMMER SWITCH', // Please change this to the one listed on the device.
vendor: 'Nue',
description: 'ZigBee smart dimmer switch',
supports: 'on/off, brightness',
toZigbee: [tz.on_off, tz.light_brightness],
fromZigbee: [fz.state, fz.ignore_onoff_change, fz.brightness_report, fz.ignore_light_brightness_change],
},
fromZigbee.js
ignore_light_brightness_change: {
cid: 'genLevelCtrl',
type: 'devChange',
convert: (model, msg, publish, options) => null,
},
Please make a PR if everything works!
We already have a separate issue for the FNB56-ZSC01LX1.2
Works great, thank you.
This might be out of the control of Z2M, but as far as the dimming steps go, it currently takes the button to be held for 8 seconds to go from maximum brightness to minimum brightness... this seems like a longer time than I remember.
The other thing is that the minimum brightness is 20 (max 254). Not sure that this will be an issue but just found it strange.
I will work on a PR now if you're happy with the results. Thank you Koen.... I have a switch that acts a bit different for you next! 馃憤
FB56+ZSN08KJ2.3 PRODUCT LINK _(Ignore it pictured horizontal - we always mount vertically)_
This switch is a 4 key non-relay wall switch, it is just used to pair with other switches/devices and used to select scenes or as a no-wire 2-way switch. Pressing the button activates the LED for approximately 1 second and then it goes out.
I'd like to integrate this switch by not only eventually binding to a switch or group of switches, but if possible, if the button is held to trigger another action. This would be in addition to just having HA respond to a momentary button press if wanted. What are your thoughts?
I believe it is physically set out like this, so hopefully you can use the 'top-left' etc:
TOP
0x01 0x03
0x02 0x04
BOTTOM
This is the sniffing result for button 4 (Bottom Right). The Cluster is: Scenes (0x0005)
Frame 2: 51 bytes on wire (408 bits), 49 bytes captured (392 bits) on interface 0
IEEE 802.15.4 Data, Dst: 0x0000, Src: 0x6752
ZigBee Network Layer Data, Dst: 0x0000, Src: 0x6752
ZigBee Application Support Layer Data, Dst Endpt: 11, Src Endpt: 4
ZigBee Cluster Library Frame
Frame Control Field: Cluster-specific (0x01)
Sequence Number: 7
Command: Recall Scene (0x05)
Payload
Group ID: 0xf0f0
Scene ID: 0x04
I have sniffed each button press and device pairing here: LINK TO ALL SNIFFING RESULTS
I also have a 1 switch version of this, and I believe there is also a 2 switch version. Let me know if there's anything else you need - I don't even know where to begin on this one.... thanks again!!!
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045 - TESTING',
vendor: 'Nue / 3A',
description: 'Zigbee 4 key scene wall switch',
supports: 'on/off',
toZigbee: [],
fromZigbee: [],
},
zigbee2mqtt:debug 3/5/2019, 1:50:12 AM Received zigbee message of type 'attReport' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516)
zigbee2mqtt:warn 3/5/2019, 1:50:12 AM No converter available for 'HGZB-045 - TESTING' with cid 'genPowerCfg', type 'attReport' and data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}'
zigbee2mqtt:warn 3/5/2019, 1:50:12 AM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
zigbee2mqtt:debug 3/5/2019, 1:50:12 AM Received zigbee message of type 'devChange' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516)
zigbee2mqtt:warn 3/5/2019, 1:50:12 AM No converter available for 'HGZB-045 - TESTING' with cid 'genPowerCfg', type 'devChange' and data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}'
Do you already see no converter available messages when pressing the buttons? If not, please provide the log of ONLY the moment when you press the button when running with DEBUG=* npm start.
I'm not sure why but I didn't get the above error on this occassion. This is the debug output for a single button press using the above device handler:
serialport/bindings/poller received "readable" +10s
serialport/binding-abstract read +10s
serialport/bindings/unixRead Starting read +10s
serialport/bindings/unixRead Finished read 8 bytes +1ms
serialport/stream binding.read finished +10s
cc-znp { sof: 254,
cc-znp len: 3,
cc-znp type: 'AREQ',
cc-znp subsys: 'ZDO',
cc-znp cmd: 'srcRtgInd',
cc-znp payload: { dstaddr: 32249, relaycount: 0, relaylist: <Buffer > },
cc-znp fcs: 6,
cc-znp csum: 6 } +10s
serialport/stream _read reading +13ms
serialport/binding-abstract read +17ms
serialport/bindings/unixRead Starting read +16ms
cc-znp:AREQ <-- ZDO:srcRtgInd, { dstaddr: 32249, relaycount: 0, relaylist: <Buffer > } +10s
zigbee-shepherd:msgHdlr IND <-- ZDO:srcRtgInd +10s
serialport/bindings/unixRead Finished read 31 bytes +5ms
serialport/stream binding.read finished +7ms
cc-znp { sof: 254,
cc-znp len: 26,
cc-znp type: 'AREQ',
cc-znp subsys: 'AF',
cc-znp cmd: 'incomingMsg',
cc-znp payload:
cc-znp { groupid: 0,
cc-znp clusterid: 5,
cc-znp srcaddr: 32249,
cc-znp srcendpoint: 4,
cc-znp dstendpoint: 1,
cc-znp wasbroadcast: 0,
cc-znp linkquality: 123,
cc-znp securityuse: 0,
cc-znp timestamp: 13390087,
cc-znp transseqnumber: 0,
cc-znp len: 6,
cc-znp data: <Buffer 01 02 05 f0 f0 04> },
cc-znp fcs: 39,
cc-znp csum: 39 } +22ms
serialport/stream _read reading +17ms
serialport/binding-abstract read +24ms
serialport/bindings/unixRead Starting read +19ms
cc-znp:AREQ <-- AF:incomingMsg, { groupid: 0, clusterid: 5, srcaddr: 32249, srcendpoint: 4, dstendpoint: 1, wasbroadcast: 0, linkquality: 123, securityuse: 0, timestamp: 13390087, transseqnumber: 0, len: 6, data: <Buffer 01 02 05 f0 f0 04> } +24ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +0ms
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +121ms
serialport/bindings/unixRead waiting for readable because of code: EAGAIN +106ms
serialport/bindings/poller Polling for "readable" +150ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +99ms
Submitted a PR for your checking for the FB56+ZSW1IKJ1.7 (3 gang switch) today too.
@koenkk any thoughts on the debug output 2 posts up?
Can you add to https://github.com/Koenkk/zigbee-shepherd/blob/fix/lib/components/af.js#L702
console.log('hello world!', msg.zclMsg.cmdId)
and post the log of one button press here?
Sorry I'm not sure I'm doing this correctly - have tried to fork it but my lines don't seem to be the same numbering/context as the link to yours?
Is it okay if I was to try to find this file in the Z2M install and modify it directly?
I did it anyway .... :-)
Here's the debug log, I think I pressed button 3 (0x03) :
zigbee2mqtt:debug 3/9/2019, 7:36:31 AM Received zigbee message of type 'attReport' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516)
zigbee2mqtt:warn 3/9/2019, 7:36:31 AM No converter available for 'HGZB-045 - TESTING' with cid 'genPowerCfg', type 'attReport' and data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}'
zigbee2mqtt:warn 3/9/2019, 7:36:31 AM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
hello world! report
zigbee2mqtt:debug 3/9/2019, 7:36:31 AM Received zigbee message of type 'devChange' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516)
zigbee2mqtt:warn 3/9/2019, 7:36:31 AM No converter available for 'HGZB-045 - TESTING' with cid 'genPowerCfg', type 'devChange' and data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}'
zigbee2mqtt:warn 3/9/2019, 7:36:31 AM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
serialport/bindings/poller received "readable" +33s
serialport/binding-abstract read +33s
serialport/bindings/unixRead Starting read +33s
serialport/bindings/unixRead Finished read 8 bytes +1ms
serialport/stream binding.read finished +33s
cc-znp { sof: 254,
cc-znp len: 3,
cc-znp type: 'AREQ',
cc-znp subsys: 'ZDO',
cc-znp cmd: 'srcRtgInd',
cc-znp payload: { dstaddr: 58144, relaycount: 0, relaylist: <Buffer > },
cc-znp fcs: 65,
cc-znp csum: 65 } +33s
serialport/stream _read reading +11ms
serialport/binding-abstract read +13ms
serialport/bindings/unixRead Starting read +13ms
cc-znp:AREQ <-- ZDO:srcRtgInd, { dstaddr: 58144, relaycount: 0, relaylist: <Buffer > } +33s
zigbee-shepherd:msgHdlr IND <-- ZDO:srcRtgInd +33s
serialport/bindings/unixRead Finished read 31 bytes +2ms
serialport/stream binding.read finished +4ms
cc-znp { sof: 254,
cc-znp len: 26,
cc-znp type: 'AREQ',
cc-znp subsys: 'AF',
cc-znp cmd: 'incomingMsg',
cc-znp payload:
cc-znp { groupid: 0,
cc-znp clusterid: 5,
cc-znp srcaddr: 58144,
cc-znp srcendpoint: 3,
cc-znp dstendpoint: 1,
cc-znp wasbroadcast: 0,
cc-znp linkquality: 131,
cc-znp securityuse: 0,
cc-znp timestamp: 11899806,
cc-znp transseqnumber: 0,
cc-znp len: 6,
cc-znp data: <Buffer 01 01 05 f0 f0 03> },
cc-znp fcs: 254,
cc-znp csum: 254 } +15ms
serialport/stream _read reading +12ms
serialport/binding-abstract read +17ms
serialport/bindings/unixRead Starting read +15ms
cc-znp:AREQ <-- AF:incomingMsg, { groupid: 0, clusterid: 5, srcaddr: 58144, srcendpoint: 3, dstendpoint: 1, wasbroadcast: 0, linkquality: 131, securityuse: 0, timestamp: 11899806, transseqnumber: 0, len: 6, data: <Buffer 01 01 05 f0 f0 03> } +16ms
zigbee-shepherd:af dispatchIncomingMsg(): type: incomingMsg, msg: [object Object] +33s
zigbee-shepherd:msgHdlr IND <-- AF:incomingMsg, transId: 0 +39ms
serialport/bindings/unixRead waiting for readable because of code: EAGAIN +26ms
serialport/bindings/poller Polling for "readable" +58ms
zigbee-shepherd:af dispatchIncomingMsg(): type: zclIncomingMsg, msg: [object Object] +25ms
hello world! recall
Can you check if any no converter available messages appear after updating to the latest dev branch?
@Koenkk Need recall cmdID for the AV2010/34 Bitron Device #348 . Nice thanks as i now doesnt need to provide a new PR for this.
This is a fresh install of the dev branch, no 'Hello world' changes, and your 'recall' commit above is in the af.js file:
PAIRING, no button press:
zigbee2mqtt:debug 3/10/2019, 6:12:02 AM Received zigbee message of type 'attReport' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516)
zigbee2mqtt:warn 3/10/2019, 6:12:02 AM No converter available for 'HGZB-045 - TESTING' with cid 'genPowerCfg', type 'attReport' and data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}'
zigbee2mqtt:warn 3/10/2019, 6:12:02 AM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
zigbee2mqtt:debug 3/10/2019, 6:12:02 AM Received zigbee message of type 'devChange' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516)
zigbee2mqtt:warn 3/10/2019, 6:12:02 AM No converter available for 'HGZB-045 - TESTING' with cid 'genPowerCfg', type 'devChange' and data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}'
Single press:
zigbee2mqtt:debug 3/10/2019, 6:13:43 AM Received zigbee message of type 'cmdRecall' with data '{"cid":"genScenes","data":{"groupid":61680,"sceneid":3}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516)
zigbee2mqtt:warn 3/10/2019, 6:13:43 AM No converter available for 'HGZB-045 - TESTING' with cid 'genScenes', type 'cmdRecall' and data '{"cid":"genScenes","data":{"groupid":61680,"sceneid":3}}'
zigbee2mqtt:warn 3/10/2019, 6:13:43 AM Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
Handler:
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045 - TESTING',
vendor: 'Nue / 3A',
description: 'Zigbee 4 key scene wall switch',
supports: 'on/off',
toZigbee: [],
fromZigbee: [],
},
Thanks @tb-killa , looks like your switch does the same thing as mine. What handler are you using?
Can you post the logging for all 4 buttons?
@highground88 nice to read. Show my pr to the other device. Please push all 4 buttons and show the results via debug log.
All four buttons from boot:
Yes I see it's the same like my device only different cid 'genScenes', type 'cmdRecall' per button one id.
Not really sure where to go next with this. I also have a 1 and 2 scene switch version to do, plus another 1 switch that I think uses Zigbee Pro, but hopefully they will be much the same.
@highground88 use
HGZB_045_click: {
cid: 'genScenes',
type: 'cmdRecall',
convert: (model, msg, publish, options) => {
return {click: msg.data.data.sceneid};
},
},
My apologies, but use this where? As a handler in devices.js? Thanks
No problem,
devices.js
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045 - TESTING',
vendor: 'Nue / 3A',
description: 'Zigbee 4 key scene wall switch',
supports: 'on/off',
toZigbee: [],
fromZigbee: [fz.HGZB_045_click],
},
fromZigbee.js
HGZB_045_click: {
cid: 'genScenes',
type: 'cmdRecall',
convert: (model, msg, publish, options) => {
return {click: msg.data.data.sceneid};
},
},
Looking good! {"click":4,"linkquality":105} Thanks gentlemen. What would the MQTT string be in this instance to activate? /click/3 ...? {"click":2} ?
So I take it I could potentially bind a switch to another device now?
@Koenkk we could use the converter for my device of bitron and make them general.
I agree - I'm likely to find other model numbers with the same click interface on at least 2 more of my switches. I can then bring them all in under the one command then... maybe "scene_click"?
EDIT: Would it be worthwhile to add a 'click' for the tz. command in toZigbee.js? As it doesn't exactly turn on/off - it just momentarily turns on.
One new device (FNB56-ZSW03LX2.0 - Nue 3 gang smart switch v2.0) submitted for a PR; the two below I've tested and are almost ready too once you decide on what to name the fz. converter and let me know whether your happy with how these work now 馃憤 I'll submit PR's then.
Getting this error below:
zigbee2mqtt:debug 3/10/2019, 3:47:25 PM Received zigbee message of type 'attReport' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FTB56+ZSN15HG1.0' (0x00124b001bd3bcce)
zigbee2mqtt:debug 3/10/2019, 3:47:25 PM Received zigbee message of type 'devChange' with data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}' of device 'FTB56+ZSN15HG1.0' (0x00124b001bd3bcce)
zigbee2mqtt:warn 3/10/2019, 3:47:25 PM No converter available for 'HGZB-1S - TESTING' with cid 'genPowerCfg', type 'devChange' and data '{"cid":"genPowerCfg","data":{"batteryAlarmMask":0}}'
I tried the Bitron "fz.ignore_power_report" and "fz.ignore_power_change" and that seemed to fix it... unless it's needed somehow?
{
zigbeeModel: ['FTB56+ZSN15HG1.0'],
model: 'HGZB-1S',
vendor: 'Nue / 3A',
description: 'Smart 1 key scene wall switch',
supports: 'on/off', 'scenes'
toZigbee: [tz.on_off],
fromZigbee: [fz.HGZB_045_click, fz.ignore_power_report, fz.ignore_power_change],
},
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045',
vendor: 'Nue / 3A',
description: 'Smart 4 key scene wall switch',
supports: 'on/off', 'scenes'
toZigbee: [tz.on_off],
fromZigbee: [fz.HGZB_045_click, fz.ignore_power_report, fz.ignore_power_change],
},
The one thing with these (aside from binding) that would be great to have is LED feedback - not sure if this will happen with the binding command already, but my current scene switches once bound (e.g. like a 2 way switch) will light up the led red when the slave switch is on, then back to blue when off. Is this sort of LED control possible do you think with these @Koenkk ?
HGZB_045_click to nue_scene_click and create a PR?Thanks Koen. I've renamed the fz. changes and submitted a PR, also added the 1 and 4 key scene switches to devices.js.
As far as the binding, I'm not having much luck. I think I've followed your guide correctly:
zigbee2mqtt/bridge/bind/0x00124b001bd3bcce(Payload is 0x00124b0014bdea20)
I don't see any binding message on debug. The 0x00124b0014bdea20 target device is a 3 gang switch, the friendly is the 1 key scene switch 2 posts up ['FTB56+ZSN15HG1.0']. Am I missing some functions in the handler to support this perhaps?
Previously I've used the app / Nue hub to bind devices.
Can you provide the zigbee2mqtt when doing the bind?
I dont get anything other than the MQTT message I sent through. No reply, acknowledgement or error - I'll update this post when I get a chance to try it again
Sorry @Koenkk, I had some interuptions from a Mosquitto upgrade...
I'm up and running with latest dev build, and have been playing around with the 4 scene switch _(friendly: 4scene)_ and 2 gang _(2gang..)_ switch, and have had partial success, but with 2 problems to solve:
If I send zigbee2mqtt/bridge/bind/4scene(payload) 2gang, I get
zigbee2mqtt/bridge/log
{"type":"device_bind","message":{"from":"0x00124b00180ff516","to":"0x00124b0014afe1fb","cluster":5}}
zigbee2mqtt/bridge/log
{"type":"device_bind","message":{"from":"0x00124b00180ff516","to":"0x00124b0014afe1fb","cluster":6}}
This results in the top_left scene key controls the top gang of the physical 2 gang switch ('2gang').
Problem 1: I have no control over which scene key controls what gang, and the bottom switch on the 2gang is not controlled by the above command. Is this just me sending incorrect messages?
Problem 2: Pressing the scene key flips the switch and the top_leftled stays lit on the 4scene switch. Pressing again, un-lit, whci is correct. However, turning off the 2gang top switch directly does not change the state of the 4scene (remains on, led lit), so communication is only 1 way?
Maybe @tb-killa has tried with his switches?
Cheers
Problem 1: need to make some zigbee2mqtt changes
Problem 2: could you also bind the other way around?
Problem 1 should be solved now, documentation: https://github.com/Koenkk/zigbee2mqtt.io/blob/dev/information/binding.md#binding-specific-endpoint
Thanks for your help but it appears to not be working. I pulled the latest dev, and the commands kill Z2M.
zigbee2mqtt/bridge/bind/4scene /top_left 2gang/bottom
zigbee2mqtt:debug 3/16/2019, 1:04:24 AM Received MQTT message on 'zigbee2mqtt/bridge/bind/4scene/top_left' with data '2gang/bottom'
/opt/zigbee2mqtt/lib/extension/deviceBind.js:64
const epID = mappedDevice.ep(device)[postfix];
^
TypeError: mappedDevice.ep is not a function
at DeviceBind.getEp (/opt/zigbee2mqtt/lib/extension/deviceBind.js:64:39)
at DeviceBind.onMQTTMessage (/opt/zigbee2mqtt/lib/extension/deviceBind.js:82:29)
at results.extensions.filter.map (/opt/zigbee2mqtt/lib/controller.js:149:27)
at Array.map (<anonymous>)
at Controller.onMQTTMessage (/opt/zigbee2mqtt/lib/controller.js:149:14)
at MQTT.onMessage (/opt/zigbee2mqtt/lib/mqtt.js:81:18)
at MqttClient.emit (events.js:189:13)
at MqttClient._handlePublish (/opt/zigbee2mqtt/node_modules/mqtt/lib/client.js:987:12)
at MqttClient._handlePacket (/opt/zigbee2mqtt/node_modules/mqtt/lib/client.js:336:12)
at work (/opt/zigbee2mqtt/node_modules/mqtt/lib/client.js:292:12)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node index.js`
Reversing the source/target order results in the same:
zigbee2mqtt:debug 3/16/2019, 1:02:49 AM Received MQTT message on 'zigbee2mqtt/bridge/bind/2gang/top' with data '4scene/bottom_left'
/opt/zigbee2mqtt/lib/extension/deviceBind.js:64
const epID = mappedDevice.ep(device)[postfix];
^
TypeError: mappedDevice.ep is not a function
at DeviceBind.getEp (/opt/zigbee2mqtt/lib/extension/deviceBind.js:64:39)
at DeviceBind.onMQTTMessage (/opt/zigbee2mqtt/lib/extension/deviceBind.js:94:27)
at results.extensions.filter.map (/opt/zigbee2mqtt/lib/controller.js:149:27)
at Array.map (<anonymous>)
at Controller.onMQTTMessage (/opt/zigbee2mqtt/lib/controller.js:149:14)
at MQTT.onMessage (/opt/zigbee2mqtt/lib/mqtt.js:81:18)
at MqttClient.emit (events.js:189:13)
at MqttClient._handlePublish (/opt/zigbee2mqtt/node_modules/mqtt/lib/client.js:987:12)
at MqttClient._handlePacket (/opt/zigbee2mqtt/node_modules/mqtt/lib/client.js:336:12)
at work (/opt/zigbee2mqtt/node_modules/mqtt/lib/client.js:292:12)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node index.js`
Re Problem 2 above, I can't seem to bind in the reverse direction:
zigbee2mqtt:debug 3/16/2019, 1:22:01 AM Received MQTT message on 'zigbee2mqtt/bridge/bind/2gang' with data '4scene' No other response.
Even unbinding and trying again doesn't work, just don't get a response in that direction.
Can you try again with latest dev?
zigbee2mqtt/bridge/bind/0x00124b0014afe1fb/bottom[FB56+ZSW1HKJ1.7] payload 0x00124b00180ff516/bottom_left [FB56+ZSN08KJ2.3]
results:
zigbee2mqtt:debug 3/17/2019, 1:18:02 AM Received MQTT message on 'zigbee2mqtt/bridge/bind/0x00124b0014afe1fb/bottom' with data '0x00124b00180ff516/bottom_left'
zigbee2mqtt:error 3/17/2019, 1:18:02 AM Device HGZB-045 doesn't define eps
HGZB-045 is FB56+ZSN08KJ2.3.
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045',
vendor: 'Nue / 3A',
description: 'Smart 4 key scene wall switch',
supports: 'on/off, click',
toZigbee: [tz.on_off],
fromZigbee: [fz.nue_click, fz.ignore_power_report, fz.ignore_power_change],
},
Reversing the source/target results in similar issue with that device:
zigbee2mqtt:debug 3/17/2019, 1:20:22 AM Received MQTT message on 'zigbee2mqtt/bridge/bind/0x00124b00180ff516/bottom_left' with data '0x00124b0014afe1fb/bottom'
zigbee2mqtt:error 3/17/2019, 1:20:22 AM Device HGZB-045 doesn't define eps
I also tried using friendly names as I did before but I get: _Failed to find device with entity ID '2gang'_
I can see this is listed in the configuration file as a friendly name for this device.
You should define an ep list, e.g. https://github.com/Koenkk/zigbee-shepherd-converters/blob/master/devices.js#L1851
Sorry @Koenkk , I had a play with this before I went away for work but didn't have any success in working out what I'm supposed to add in relation to the link. Could you be kind enough to provide an example for one of my devices, and I'll try to use this as a template for the others?
Can you share the database.db entry of the 'FB56+ZSN08KJ2.3'?
Thanks Koen. Here it is:
{"id":3,"type":"Router","ieeeAddr":"0x00124b00180ff516","nwkAddr":22003,"manufId":4478,"epList":[1,2,3,4],"status":"online","joinTime":1553737098,"endpoints":{"1":{"profId":260,"epId":1,"devId":4,"inClusterList":[0,3],"outClusterList":[1,3,4,5,6],"clusters":{}},"2":{"profId":260,"epId":2,"devId":$
{"id":3,"type":"Router","ieeeAddr":"0x00124b00180ff516","nwkAddr":22003,"manufId":4478,"manufName":"Feibit CO.,LTD ","powerSource":"Mains (single phase)","modelId":"FB56+ZSN08KJ2.3","epList":[1,2,3,4],"status":"online","joinTime":1553737098,"endpoints":{"1":{"profId":260,"epId":1,"devId":4,"inCl$
{"id":3,"type":"Router","ieeeAddr":"0x00124b00180ff516","nwkAddr":22003,"manufId":4478,"manufName":"Feibit CO.,LTD ","powerSource":"Mains (single phase)","modelId":"FB56+ZSN08KJ2.3","epList":[1,2,3,4],"status":"online","joinTime":1553737098,"endpoints":{"1":{"profId":260,"epId":1,"devId":4,"inCl$
Can you try with:
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045',
vendor: 'Nue / 3A',
description: 'Smart 4 key scene wall switch',
supports: 'on/off, click',
toZigbee: [tz.on_off],
fromZigbee: [fz.nue_click, fz.ignore_power_report, fz.ignore_power_change],
ep: (device) => {
return {'top_left': 1, 'top_right': 2, 'bottom_left': 3, 'bottom_right': 4};
},
},
Thanks again for all your hard work and assistance - that does indeed work.
The scene switch controls the 2-gang sucessfully - the only thing lacking is feedback (Re 'Problem 2') that if the 2 gang switch is turned off whilst the scene switch has previsouly toggled it on, this isn't represented back at the scene switch (remains on). I have tried pairing in both directions at once, hoping that this may work but the 2 gang switch doesn't change anything back on the scene switch, and as a result of doing this, a new problem emerged - the scene key no longer sends a Zigbee message on Z2M and subsequently to MQTT.
The scene key still switches the 2-gang switch it is bound to, and the 2-gang switch if pressed individuallystill sends a Z2M message. I've tried 'unbind' but this hasn't worked so will delete the database and start again.
I also noticed that if sending a bind message on MQTT, my system doesn't handle the friendly name being in the start of the message - the payload is fine though. Not sure if this is by design?
e.g.
zigbee2mqtt/bridge/bind/2gang/bottom -> 4scene/top_left _zigbee2mqtt:error Failed to find device with entity ID '2gang'_
zigbee2mqtt/bridge/bind/0x00124b0014afe1fb/bottom -> 4scene/top_left _WORKS.... (both 2gang and 4scene are recognised entities)_
Bind by friendly name should be fixed now, thanks for reporting.
No problem, thanks for fixing it - any ideas on how to fix the 2 way feedback?
(I've tried the 'report' feature but don't see any difference in the Z2M logs)
Also, using the latest dev build (30/3/19), I'm experiencing more binding issues.
I can bind the '4scene' to the '2gang' switches, but not the other way around (irrespective of using friendly names etc).
If I do bind the '4scene' to the '2gang' , the source switch actuates as expected, but no Z2M message is produced whenever a bound source key is pressed. Pressing the target key does initiate a message. These 'click' buttons produce messages okay before they're bound, and when 'un-binded'. operate again as expected.
Happy to move this into another issue/binding issue if you'd prefer? Cheers
To start with, we first make sure that this mapping is OK: return {'top_left': 1, 'top_right': 2, 'bottom_left': 3, 'bottom_right': 4};
Do the correct switches turn on off when sending to zigbee2mqtt/4scene/top_left/set with payload ON (also try for the other 3 eps, e.g. top_left -> top_right).
You might be on to something... thank you for your daily message :-)
I have noticed that all switches are always set ON. The 'click' message when physically pressing the button shows this, e.g.
zigbee2mqtt:debug 3/31/2019, 10:58:43 AM Received zigbee message of type 'cmdRecall' with data '{"cid":"genScenes","data":{"groupid":61680,"sceneid":3}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516) of endpoint 3
zigbee2mqtt:info 3/31/2019, 10:58:43 AM MQTT publish: topic 'zigbee2mqtt/4scene', payload '{"state_left":"ON","state_top_right":"ON","state_bottom_right":"ON","linkquality":102,"state":"OFF","state_top_left":"ON","click":3}'
Each botton (top-left etc) sends its own 'click' endpoint as intended, however the entire message before this does not change independant on whether switches are on or off, it always shows ON for each switch state.
This switch only momentarily lights up for about 1 sec when pressed, therefore isn't 'ON' constantly I imagine (however outside Z2M on its own network & hub, the light stays active if the paired device remains on).
zigbee2mqtt/4scene/top_left/set ON result
The message above results in the following MQTT message:
{"state_left":"ON","state_top_right":"ON","state_bottom_right":"ON","linkquality":86,"state":"OFF","state_top_left":"ON"}
It seems as though there might be a problem with the handler?
EDIT: I'm now using the below handler which I pasted together from other devices... not sure if correct, but the switches now light up and remain lit. Switch 4 isn't on there yet...
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045',
vendor: 'Nue / 3A',
description: 'Smart 4 key scene wall switch',
supports: 'on/off, click',
toZigbee: [tz.on_off],
fromZigbee: [fz.nue_click, fz.ignore_power_report, fz.ignore_power_change],
ep: (device) => {
return {'top_left': 1, 'top_right': 2, 'bottom_left': 3, 'bottom_right': 4};
},
configure: (ieeeAddr, shepherd, coordinator, callback) => {
const ep1 = shepherd.find(ieeeAddr, 1);
execute(ep1, [(cb) => ep1.bind('genOnOff', coordinator, cb)], () => {
const ep2 = shepherd.find(ieeeAddr, 2);
execute(ep2, [(cb) => ep2.bind('genOnOff', coordinator, cb)], () => {
const ep3 = shepherd.find(ieeeAddr, 3);
execute(ep3, [(cb) => ep3.bind('genOnOff', coordinator, cb)], callback);
});
});
},
},
This results in:
zigbee2mqtt:debug 3/31/2019, 11:16:17 AM Received zigbee message of type 'cmdOn' with data '{"cid":"genOnOff","data":{}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516) of endpoint 3
zigbee2mqtt:warn 3/31/2019, 11:16:17 AM No converter available for 'HGZB-045' with cid 'genOnOff', type 'cmdOn' and data '{"cid":"genOnOff","data":{}}'
I then added: fz.genOnOff_cmdOn, fz.genOnOff_cmdOff to 'fromZigbee' which made the no converter message go away, but has messed up the endpoint message. All switches still report as ON as below in the MQTT message.
zigbee2mqtt:info 3/31/2019, 11:26:50 AM MQTT publish: topic 'zigbee2mqtt/4scene', payload '{"state_left":"ON","state_top_right":"ON","state_bottom_right":"ON","linkquality":84,"state":"OFF","state_top_left":"ON","click":"off"}' <---- The 'click' message now cycles on or off instead of the endpoint #'s after my last amateur edit.....
I might leave it to an expert to advise what I need to do and what I've done wrong perhaps :-)
Can you use the following 2 fromZigbee converters:
HGZB_045_cmdOn: {
cid: 'genOnOff',
type: 'cmdOn',
convert: (model, msg, publish, options) => {
const ep = msg.endpoints[0];
const button = getKey(model.ep(ep.device), ep.epId);
const payload = {};
payload[`state_${button}`] = 'ON';
return payload
},
},
HGZB_045_cmdOff: {
cid: 'genOnOff',
type: 'cmdOff',
convert: (model, msg, publish, options) => {
const ep = msg.endpoints[0];
const button = getKey(model.ep(ep.device), ep.epId);
const payload = {};
payload[`state_${button}`] = 'OFF';
return payload
},
},
Utilising this handler:
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045',
vendor: 'Nue / 3A',
description: 'Smart 4 key scene wall switch',
supports: 'on/off, click',
toZigbee: [tz.on_off],
fromZigbee: [fz.nue_click, fz.ignore_power_report, fz.ignore_power_change],
ep: (device) => {
return {'top_left': 1, 'top_right': 2, 'bottom_left': 3, 'bottom_right': 4};
},
},
on a fresh install with the FromZigbee changes made, I am getting this response from zigbee2mqtt/4scene/top_left/set ON :
{"state_left":"ON","state_top_right":"ON","state_bottom_right":"ON","linkquality":97,"state_top_left":"ON","click":4}
"state_left" should probably be "state_bottom_left" perhaps?
I am also not getting any changes to the states of any switches; all remain ON. Only the 'click' value changes dependant on switch, otherwise these are the same messages.
These values are probably cached, please remove data/state.json and try again. Note that you should also add the 2 converters from https://github.com/Koenkk/zigbee2mqtt/issues/176#issuecomment-478985557
Sorry was away for work again. Thanks for the reply, here is where I am at:
Using this handler still: #176 (comment)
Sending: zigbee2mqtt/4scene/top_left/set ON
Results: zigbee2mqtt/4scene {"linkquality":105,"state_top_left":"ON"}
The 4gang switch does not stay on or activate at all.
Pressing this top_left switch results:
Message: zigbee2mqtt/4scene {"linkquality":99,"state_top_left":"ON","click":1}
Pressing the button again shows the same message, no change to state.
The log shows:
zigbee2mqtt:debug 4/10/2019, 6:42:40 AM Received zigbee message of type 'cmdRecall' with data '{"cid":"genScenes","data":{"groupid":61680,"sceneid":1}}' of device 'FB56+ZSN08KJ2.3' (0x00124b00180ff516) of endpoint 1
Can you confirm the device handler I'm using is currently accurate?
Thank you!!
I expect that this device is stateless, I just provides one message if the one of the button is pressed. If my reasoning is correct, the converter should be changed to produce {"click": "state_top_left"}
Thanks Koen. It might well be. On its standard hub I've done some testing using a binded pair of devices to try to determine the natural behaviour (below).
It would be great to be able to utilise the state light as I was hoping to setup a 4 gang scene switch next to the bed and have a 'night time' alarm button which would show the state of the HA alarm dependant on switch LED colour for the wife. This would therefore be outside of the switches ecosystem.
1.
(all off state)
Press SCENE = SWITCH ON, SWITCH LED RED, SCENE LED RED
(all remain on state)
Press SWITCH = SWITCH OFF, SWITCH LED BLUE, SCENE LED RED (still remains 'on')
2.
(all off state)
Press SWITCH = SWITCH ON, SWITCH LED RED, SCENE LED BLUE ('off' state)
then
Press SCENE = SCENE LED BLUE (remains same), SWITCH OFF
Press SCENE again = SWITCH ON, SWITCH LED RED, SCENE LED RED
If this is the case as you expected and no state is forwarded,, is there a need to add the fz.genOnOff_cmdOn, fz.genOnOff_cmdOff to 'fromZigbee' ? (e.g. as per [comment #176] )(https://github.com/Koenkk/zigbee2mqtt/issues/176#issuecomment-478331979)
I'm still not sure how best to format the converter I'm sorry to produce {"click": "state_top_left"}. Everything I tried just seemed to break it.
Much appreciation as always for your help.
Can you try these handlers:
HGZB_045_cmdOn: {
cid: 'genOnOff',
type: 'cmdOn',
convert: (model, msg, publish, options) => {
const ep = msg.endpoints[0];
const button = getKey(model.ep(ep.device), ep.epId);
return {click: `${button}_on`};
},
},
HGZB_045_cmdOff: {
cid: 'genOnOff',
type: 'cmdOff',
convert: (model, msg, publish, options) => {
const ep = msg.endpoints[0];
const button = getKey(model.ep(ep.device), ep.epId);
return {click: `${button}_off`};
},
},
Hi @Koenkk , still not having much luck with this device unfortunately...
I'm using this device config (is this still correct?):
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045',
vendor: 'Nue / 3A',
description: 'Smart 4 key scene wall switch',
supports: 'on/off, click',
toZigbee: [tz.on_off],
fromZigbee: [fz.nue_click, fz.ignore_power_report, fz.ignore_power_change],
ep: (device) => {
return {'top_left': 1, 'top_right': 2, 'bottom_left': 3, 'bottom_right': 4};
},
},
... with the handlers you last posted above, on a fresh build. I have MQTT connection, but am not receiving MQTT messages, and appear to be getting these errors :
cc-znp Error: Unrecognized command
cc-znp at new ZpiObject (/opt/zigbee2mqtt/node_modules/cc-znp/lib/zpiObject.js:33:15)
cc-znp at CcZnp._parseMtIncomingData (/opt/zigbee2mqtt/node_modules/cc-znp/lib/ccznp.js:331:18)
cc-znp at Unpi.parseMtIncomingData (/opt/zigbee2mqtt/node_modules/cc-znp/lib/ccznp.js:91:18)
cc-znp at Unpi.emit (events.js:189:13)
cc-znp at Dissolve.<anonymous> (/opt/zigbee2mqtt/node_modules/cc-znp/node_modules/unpi/index.js:107:14)
cc-znp at Dissolve.emit (events.js:189:13)
cc-znp at Dissolve.<anonymous> (/opt/zigbee2mqtt/node_modules/cc-znp/node_modules/dissolve-chunks/index.js:73:29)
cc-znp at Dissolve.emit (events.js:189:13)
cc-znp at emitReadable_ (/opt/zigbee2mqtt/node_modules/cc-znp/node_modules/dissolve/node_modules/readable-stream/lib/_stream_readable.js:456:10)
cc-znp at emitReadable (/opt/zigbee2mqtt/node_modules/cc-znp/node_modules/dissolve/node_modules/readable-stream/lib/_stream_readable.js:450:7) +6ms
This is current verion info: {"version":"1.3.1","commit":"39d6a8e","coordinator_firmware":20190315,"log_level":"debug","permit_join":true}
Thanks for any help you might be able to give me again.
Can you provide the complete debug log?
DEBUG LOG -- Error at bottom highlighted.
Thanks Koen. I have a fresh 1.4.0 dev version now, and I changed over to my second CC2531, and are receiving MQTT messages again (e.g.
zigbee2mqtt/0x00124b00180ff516 {"linkquality":52,"click":2} ).
This error though seems to still appear on it's own eventually without any button presses. I'm not sure of the nature or effect it has.
@highground88 can you add to https://github.com/Koenkk/cc-znp/blob/master/lib/zpiObject.js#L19
console.log(subsys, cmd, args)
@Koenkk , thanks for your help. I've made the changes to the zipObject.js file - I imagine the above line is just for logging? In any case, the error isn't returning - I dont think anything else has change and can't reproduce this again... sorry if that's unhelpful.
As I'm only getting to spend a little bit of time on this project now compared to previously, I'm probably not understanding where I am up to with regard to finishing off the scene switch support (finally).
I still want to support the state change via led on the scene switches - this appears possible as per my experiences in comments above - but I don't have the knowledge to understand what parts of the device config I changed which make this work, and which parts break the 'click' and state changes on MQTT.
With the current settings, binding from scene->switch works. The source scene switch stays illuminated correctly whilst the target switch remains on, but this breaks when the target is turned off directly, causing the source scene switch to remain in an 'on' state. So the target seems to not update the source.
Trying to directly switch a scene switch via mqtt message rather than a target results in feedback showing this is occurring (eg. zigbee2mqtt/0x00124b00180ff516/bottom_right/set ON = {"linkquality":52,"state_top_left":"ON","state_top_right":"ON","state_bottom_right":"ON"}). However no LED change occurs, and as there's no relay on these, it's not really useful in any way.
Based on my tests and trials above - is there anything you can suggest I try?
Thanks mate - I know you have a lot of other people asking for help and other projects going on.
@Koenkk
Once both target (switch) and source (scene switch) are bound in both directions, I do not get MQTT messages or Z2M logs when the source is switched - however, if switched seperately, or if I press any of the unbound scene switches, MQTT messages and logs are produced.
Further, I still have the same issue - state is only one direction (bound in both directions). Switching the target switch to off leaves the source in the on state - though there is Z2M activity when the target is switched, unlike in reverse.
If the source/scene switch is showing on, and I send "zigbee2mqtt/0x00124b00180ff516/top_left, payload OFF" directly, there is no change and this does not show in the Z2M log, though does go to MQTT (with no response to the message).
Let me know if this doesn't make sense or further tests you need me to do. Could the device config below be the issue?:
{
zigbeeModel: ['FB56+ZSN08KJ2.3'],
model: 'HGZB-045',
vendor: 'Nue / 3A',
description: 'Smart 4 key scene wall switch',
supports: 'on/off, click',
toZigbee: [tz.on_off],
fromZigbee: [fz.nue_click, fz.ignore_power_report, fz.ignore_power_change],
ep: (device) => {
return {'top_left': 1, 'top_right': 2, 'bottom_left': 3, 'bottom_right': 4};
},
},
The device config looks good, I'm wondering if the scene LED can be turned off remotely at all.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Hi,
I would like some help with some of my Feibit Zigbee switches. I have setup Home Assistant 0.117.6 on Raspberry Pi 4b 4gb and have installed zigbee2mqtt 1.16.1 and mosqito broker 5.1. I am using Phoscon Raspbee II as my zigbee receiver with the latest firmware 26660700. I have got the following Feibit devices and they all install correctly but the device is not refreshing the state automatically. i,e if I physically switch on the switch the state in zigbee2mwtt and HA will still show as off.
FB56+ZSC05HG1.0 - Dimmer Switch
FB56+ZSW1GKJ2.5 - 1 Gang Switch
FB56+ZSW1HKJ2.5 - 2 Gang Switch
FB56+ZSW1IKJ2.5 - 3 Gang Switch
FB56-ZCW11HG1.2 - Downlight
FB56-ZCW08KU1.1 - Bulb
FB56-ZCW11HG1.2 - Bulb
can someone please help me to get this working properly. I have aslo got some 3A Neu dswitched and they seem to work properly. Also the dimmer switch above will crash when trying to change the brightness.