Last active
March 10, 2025 12:18
-
-
Save 9zigen/d945911b632b432979d46973511d26ba to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const {deviceEndpoints, numeric, onOff, commandsOnOff, binary, quirkAddEndpointCluster} = require('zigbee-herdsman-converters/lib/modernExtend'); | |
| const definition = { | |
| zigbeeModel: ['alab.switch'], | |
| model: 'alab.switch', | |
| vendor: 'Alab', | |
| description: 'Four channel relay board with four inputs', | |
| extend: [ | |
| deviceEndpoints({ | |
| endpoints: {"l1":1,"l2":2,"l3":3,"l4":4,"in1":5,"in2":6,"in3":7,"in4":8}} | |
| ), | |
| onOff({ | |
| powerOnBehavior: false, | |
| configureReporting: false, | |
| endpointNames: ["l1","l2","l3","l4"]} | |
| ), | |
| commandsOnOff({ | |
| endpointNames: ["l1","l2","l3","l4"]} | |
| ), | |
| numeric({ | |
| name: "input_state", | |
| cluster: "genAnalogInput", | |
| attribute: "presentValue", | |
| description: 'Input state', | |
| endpointNames: ["in1","in2","in3","in4"] | |
| }) | |
| ], | |
| meta: {"multiEndpoint":true} | |
| }; | |
| module.exports = definition; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment