Skip to content

Commit

Permalink
Extend support for PSM-29ZBSR power plug (Koenkk#1222)
Browse files Browse the repository at this point in the history
Adds power measurement and state reporting.
  • Loading branch information
ilarrain authored May 11, 2020
1 parent 07bfa50 commit 20a3da9
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions devices.js
Original file line number Diff line number Diff line change
Expand Up @@ -5734,9 +5734,18 @@ const devices = [
model: 'PSM-29ZBSR',
vendor: 'Climax',
description: 'Power plug',
supports: 'on/off',
fromZigbee: [fz.on_off],
toZigbee: [tz.on_off],
supports: 'on/off, power measurement',
fromZigbee: [fz.on_off, fz.metering_power, fz.ignore_basic_report],
toZigbee: [tz.on_off, tz.ignore_transition],
meta: {configureKey: 4},
configure: async (device, coordinatorEndpoint) => {
const endpoint = device.getEndpoint(1);
await bind(endpoint, coordinatorEndpoint, ['genOnOff', 'seMetering']);
await configureReporting.onOff(endpoint);
await readMeteringPowerConverterAttributes(endpoint);
await configureReporting.instantaneousDemand(endpoint,
{'minimumReportInterval': 10, 'reportableChange': 2});
},
},

// HEIMAN
Expand Down

0 comments on commit 20a3da9

Please sign in to comment.