Skip to content

Commit

Permalink
feat: Add valve opening and closing configuration for Sonoff TRVZB (#…
Browse files Browse the repository at this point in the history
…7130)

* Added valveOpeningDegree and valveClosingDegree to TRVZB

* cancel readAtt

* fix rule errors

* Change the description of TRVZB valve opening degree and closing degree

---------

Co-authored-by: lcheng33775823 <1055446591@qq.com>
  • Loading branch information
lcheng33775823 and lcheng33775823 authored Apr 18, 2024
1 parent 8f4e11a commit 87601c2
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions src/devices/sonoff.ts
Original file line number Diff line number Diff line change
Expand Up @@ -869,6 +869,34 @@ const definitions: Definition[] = [
unit: 'mV',
access: 'STATE_GET',
}),
numeric({
name: 'valve_opening_degree',
cluster: 0xFC11,
attribute: {ID: 0x600B, type: 0x20},
description: 'Valve open position (percentage) control. ' +
'If the opening degree is set to 100%, the valve is fully open when it is opened. ' +
'If the opening degree is set to 0%, the valve is fully closed when it is opened, ' +
'and the default value is 100%. ' +
'Note: only version v1.1.4 or higher is supported.',
valueMin: 0.0,
valueMax: 100.0,
valueStep: 1.0,
unit: '%',
}),
numeric({
name: 'valve_closing_degree',
cluster: 0xFC11,
attribute: {ID: 0x600C, type: 0x20},
description: 'Valve closed position (percentage) control. ' +
'If the closing degree is set to 100%, the valve is fully closed when it is closed. ' +
'If the closing degree is set to 0%, the valve is fully opened when it is closed, ' +
'and the default value is 100%. ' +
'Note: Only version v1.1.4 or higher is supported.',
valueMin: 0.0,
valueMax: 100.0,
valueStep: 1.0,
unit: '%',
}),
sonoffExtend.weeklySchedule(),
customTimeResponse('1970_UTC'),
ota(),
Expand Down

0 comments on commit 87601c2

Please sign in to comment.