Skip to content

Commit

Permalink
feat(add): TS0003_switch_3_gang_with_backlight (#5953)
Browse files Browse the repository at this point in the history
* add support for Lonsonho X703A

* Update tuya.ts

---------

Co-authored-by: Dmytro Hladunets <Dmytro.Hladunets@LibertyMutual.com>
Co-authored-by: Koen Kanters <koenkanters94@gmail.com>
  • Loading branch information
3 people authored Jul 6, 2023
1 parent 06d2ac8 commit ee9a7ab
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions src/devices/tuya.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1942,6 +1942,28 @@ const definitions: Definition[] = [
tuya.whitelabel('Lonsonho', 'X702A', '2 gang switch with backlight', ['_TZ3000_54hjn4vs']),
],
},
{
fingerprint: [
{modelID: 'TS0003', manufacturerName: '_TZ3000_rhkfbfcv'},
],
model: 'TS0003_switch_3_gang_with_backlight',
vendor: 'TuYa',
description: '3-Gang switch with backlight',
extend: tuya.extend.switch({powerOnBehavior2: true, indicatorMode: true, endpoints: ['l1', 'l2', 'l3']}),
endpoint: (device) => {
return {'l1': 1, 'l2': 2, 'l3': 3};
},
meta: {multiEndpoint: true},
configure: async (device, coordinatorEndpoint, logger) => {
await tuya.configureMagicPacket(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']);
},
whiteLabel: [
tuya.whitelabel('Lonsonho', 'X703A', '3 Gang switch with backlight', ['_TZ3000_rhkfbfcv']),
],
},
{
zigbeeModel: ['TS0002'],
model: 'TS0002',
Expand Down

0 comments on commit ee9a7ab

Please sign in to comment.