Skip to content

Commit

Permalink
Merge branch 'ioBroker:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
asgothian authored Nov 17, 2024
2 parents ac2ec73 + d1f4cac commit 5138ec8
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
20 changes: 17 additions & 3 deletions lib/devices.js
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,9 @@ const generator = {
setattr: 'state',
});
}
if (endpoint.supportsOutputCluster('genMultistateInput')) {
if (endpoint.supportsOutputCluster('genMultistateInput')||
endpoint.clusters.hasOwnProperty('genMultistateInput')
) {
devstates.push({
id: `channel_${epID}.click`,
prop: 'action',
Expand Down Expand Up @@ -343,6 +345,18 @@ const generator = {
isEvent: true,
getter: payload => payload.action === `tripple_${epName}` ? true : undefined,
});
devstates.push({
id: `channel_${epID}.hold`,
prop: 'action',
name: `long click event`,
icon: undefined,
role: 'button',
write: false,
read: true,
type: 'boolean',
isEvent: true,
getter: payload => payload.action === `hold_${epName}` ? true : undefined,
});
}
if (endpoint.supportsOutputCluster('genLevelCtrl')) {
devstates.push({
Expand Down Expand Up @@ -487,7 +501,7 @@ const generator = {
});
return icasa_states;
},
ptvo_switch: (entity) => {
/*ptvo_switch: (entity) => {
const devstates = [];
for (const endpoint of entity.device.endpoints) {
const epID = endpoint.ID;
Expand Down Expand Up @@ -566,7 +580,7 @@ const generator = {
}
}
return devstates;
},
},*/
};

function states_with_epname(entity, states) {
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
"ajv": "^8.17.1",
"uri-js": "^4.4.1",
"typescript": "^5.6.3",
"zigbee-herdsman": "2.1.4",
"zigbee-herdsman-converters": "20.28.0"
"zigbee-herdsman": "2.1.8",
"zigbee-herdsman-converters": "20.47.0"
},
"description": "Zigbee devices",
"devDependencies": {
Expand Down

0 comments on commit 5138ec8

Please sign in to comment.