『瀚思彼岸』» 智能家居技术论坛
标题:
求一个zigbee2mqtt转换器文件
[打印本页]
作者:
hewei061306
时间:
2024-2-7 22:08
标题:
求一个zigbee2mqtt转换器文件
大佬们能发一个涂鸦设备的转换器文件吗? 型号是 [color=rgba(var(--bs-link-color-rgb),var(--bs-link-opacity,1))]
TY0003
三开的零火开关面板。我自己照着网上教程 弄了个 一点反应没有。
不知道是哪里出了问题。求助!
const
fz = require(
'zigbee-herdsman-converters/converters/fromZigbee'
);
const
tz = require(
'zigbee-herdsman-converters/converters/toZigbee'
);
const
exposes = require(
'zigbee-herdsman-converters/lib/exposes'
);
const
reporting = require(
'zigbee-herdsman-converters/lib/reporting'
);
const
extend = require(
'zigbee-herdsman-converters/lib/extend'
);
const
e = exposes.presets;
const
ea = exposes.access;
const
definition = {
zigbeeModel: [
'TY0003'
],
model:
'ZB-SW03'
,
vendor:
'eWeLink'
,
description:
'Smart light switch - 3 gang'
,
extend: preset.switch(),
exposes: [e.switch().withEndpoint(
'left'
), e.switch().withEndpoint(
'center'
), e.switch().withEndpoint(
'right'
)],
endpoint: (device)
=>
{
return
{
'left'
:
1
,
'center'
:
2
,
'right'
:
3
};
},
meta: {configureKey:
1
, multiEndpoint:
true
},
configure:
async
(device, coordinatorEndpoint, logger)
=>
{
await
reporting.bind(device.getEndpoint(
1
), coordinatorEndpoint, [
'genOnOff'
]);
await
reporting.bind(device.getEndpoint(
2
), coordinatorEndpoint, [
'genOnOff'
]);
await
reporting.bind(device.getEndpoint(
3
), coordinatorEndpoint, [
'genOnOff'
]);
},
onEvent:
async
(type, data, device)
=>
{
device.skipDefaultResponse =
true
;
},
};
module.exports = definition;
作者:
cyl1995
时间:
2024-2-8 08:09
TY0003? 只有TS0003的
作者:
hhh.
时间:
2024-2-8 19:14
cyl1995 发表于 2024-2-8 08:09
TY0003? 只有TS0003的
TS0003 是单火的吧,可以试试能使用不
作者:
65698888
时间:
2024-2-18 15:03
这么写肯定不能用。
欢迎光临 『瀚思彼岸』» 智能家居技术论坛 (https://bbs.hassbian.com/)
Powered by Discuz! X3.5