-
Notifications
You must be signed in to change notification settings - Fork 126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug report - missing_cluster_on_endpoint_on_zcl_node #715
Comments
Hi @riisling, please create a diagnostic report from the app and get back to me with the report id. |
Hi @JohanBendz, the report code is fedc1854-2097-41bc-a406-6243eb694197 |
Got the same message here with version 0.2.23 (test) when I try to add _TZE200_3towulqd Report code: 35608291-5b5c-44b8-8a9a-1b51e4143217 |
This is my report code : 0604a99f-be83-4fc2-a2a7-1b64b3ab2fd2 on Homey 2016. |
Thanks guys, I found a typo and some code to fix! 😅 Next update after some sleep. |
I got my device to recognize events with this code snippet, but seems like _TZE200_3towulqd devices are behaving differently, based on the report that this driver worked for some devices (it did not for me) const { ZigBeeDevice } = require('homey-zigbeedriver');
const TuyaSpecificCluster = require('../../lib/TuyaSpecificCluster');
const { Cluster } = require('zigbee-clusters');
Cluster.addCluster(TuyaSpecificCluster);
const dataPoints = {
pir_state: 1,
battery_percentage: 4,
interval_time: 102,
pir_sensitivity: 9,
pir_time: 10,
illuminance_value: 12
}
const dataTypes = {
value: 2, // [ 4 byte value ]
enum: 4, // [ 0-255 ]
};
const getDataValue = (dpValue) => {
switch (dpValue.datatype) {
case dataTypes.value:
return parseInt(dpValue.data.toString('hex'), 16);
case dataTypes.enum:
return dpValue.data[0];
default:
return dpValue;
}
}
class motion_sensor_2 extends ZigBeeDevice {
async onNodeInit({ zclNode }) {
this.enableDebug();
this.printNode();
zclNode.endpoints[1].clusters[TuyaSpecificCluster.NAME]
.on('response', this.updateData.bind(this))
}
updateData(data) {
const value = getDataValue(data);
this.log(`DP: ${data.dp} - Value: ${value}`)
switch (data.dp) {
case dataPoints.pir_state:
const motion = value === 0
this.log(`Motion status: ${motion}`);
this.setCapabilityValue('alarm_motion', motion).catch(this.error);
break;
case dataPoints.illuminance_value:
this.log(`Illuminance: ${value}`);
this.setCapabilityValue('measure_luminance', value).catch(this.error);
break;
case dataPoints.battery_percentage:
const batteryThreshold = this.getSetting('batteryThreshold') || 20;
const batteryAlarm = value < batteryThreshold
this.log(`Battery: ${value}`);
this.setCapabilityValue('measure_battery', value).catch(this.error);
this.setCapabilityValue('alarm_battery', batteryAlarm).catch(this.error);
break;
case dataPoints.pir_sensitivity:
this.log(`PIR Sensitivity: ${value}`);
break;
case dataPoints.pir_time:
this.log(`PIR Time: ${value}`);
break;
default:
this.log(`Unrecognized DP: ${data.dp}`);
}
}
}
module.exports = motion_sensor_2; driver.compose.json "endpoints": {
"1": {
"clusters": [61184],
"bindings": [61184]
}
I have not implemented the setting of I can create a PR for it if this works for other people, but I have limited knowledge about zigbee and Homey. In the debug console I see these datapoints: 12 (illuminance), 1 (pir state). illuminance_value
pir_state
pir_sensitivity
battery_percentage
pir_time
Here is a link to information about the data points I collected from the device: https://gist.github.com/maccyber/2c764e3a3c0ffc429e433e6530dfcc95 |
Describe the bug
Trying to add the device _TZE200_3towulqd to Homey.
The device is added, but the icon shows a red exclamation mark.
The error code shown is "missing_cluster_on_endpoint_on_zcl_node" and the device doesen't work.
To Reproduce
Steps to reproduce the behavior:
Add new device
Expected behavior
App and Homey version
Screenshots
Additional context
The text was updated successfully, but these errors were encountered: