Skip to content

Commit

Permalink
fix(ignore): Revert "fix: Fix incorrect Yookee D10110 cover position (#…
Browse files Browse the repository at this point in the history
…6211)" (#6289)

This reverts commit 2edb88a.
  • Loading branch information
barlock authored Oct 16, 2023
1 parent 6db7bfa commit 33c36fd
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions src/devices/yookee.ts
Original file line number Diff line number Diff line change
@@ -1,32 +1,18 @@
import {Definition, Tz} from '../lib/types';
import {Definition} from '../lib/types';
import * as exposes from '../lib/exposes';
import * as utils from '../lib/utils';
import fz from '../converters/fromZigbee';
import tz from '../converters/toZigbee';
import * as reporting from '../lib/reporting';
const e = exposes.presets;

const tzLocal = {
D10110_position: {
...tz.cover_position_tilt,
convertSet: async (entity, key, value, meta) => {
utils.assertNumber(value, key);
// Requires coverInverted for fromZigbee but not for toZigbee
// https://github.com/Koenkk/zigbee-herdsman-converters/pull/6211/files#r1344424726
return await tz.cover_position_tilt.convertSet(entity, key, 100 - value, meta);
},
} as Tz.Converter,
};

const definitions: Definition[] = [
{
zigbeeModel: ['D10110'],
model: 'D10110',
vendor: 'Yookee',
description: 'Smart blind controller',
fromZigbee: [fz.cover_position_tilt, fz.battery],
toZigbee: [tz.cover_state, tzLocal.D10110_position],
meta: {coverInverted: true},
toZigbee: [tz.cover_state, tz.cover_position_tilt],
configure: async (device, coordinatorEndpoint, logger) => {
const endpoint = device.getEndpoint(1);
await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg', 'closuresWindowCovering']);
Expand Down

0 comments on commit 33c36fd

Please sign in to comment.