Created
September 12, 2025 12:42
-
-
Save ccfiel/0323dd6dd6564c0887b9abf69946f288 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
| import * as exposes from "zigbee-herdsman-converters/lib/exposes"; | |
| import * as tuya from "zigbee-herdsman-converters/lib/tuya"; | |
| const e = exposes.presets; | |
| const ea = exposes.access; | |
| /** @type {import('zigbee-herdsman-converters').Definition} */ | |
| export default { | |
| fingerprint: [ | |
| { | |
| modelID: "TS0601", | |
| manufacturerName: "_TZE200_bbn1nkqj", | |
| }, | |
| ], | |
| model: "TS0601_energy_meter", | |
| vendor: "Tuya", | |
| description: "Din rail switch with power monitoring and threshold settings", | |
| fromZigbee: [tuya.fz.datapoints], | |
| toZigbee: [tuya.tz.datapoints], | |
| configure: tuya.configureMagicPacket, | |
| exposes: [ | |
| e.switch().setAccess("state", ea.STATE_SET), | |
| e.power(), | |
| e.current(), | |
| e.voltage(), | |
| e.energy(), | |
| ], | |
| meta: { | |
| tuyaDatapoints: [ | |
| [16, "state", tuya.valueConverter.onOff], | |
| [1, "energy", tuya.valueConverter.divideBy100], // Total forward energy | |
| [6, null, tuya.valueConverter.phaseVariant2], // Phase A voltage and current | |
| ], | |
| }, | |
| }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment