Skip to content

Commit

Permalink
fix: Minor improvements for Bosch BWA-1, BSD-2, BSEN-C2 & BSEN-CV (#7386
Browse files Browse the repository at this point in the history
)

* fix: Minor corrections

* fix: Restore basic functionality for BWA-1

* fix: Format converters

* fix: Lint, be happy

* fix: Lint, remove currently unused code

* fix: Minor changes to exposes & bindings

* fix: Reintroduce `alarm_on_motion`

* fix: Use tzLocal & fzLocal

* fix: Minor typo

Where did that ! come from???

* fix: Improve `configure` for BSD-2 & BWA-1

* fix: Update required bindings & `configure`

* fix: Lint, it's fine

* hotfix: Always bind `ssIasZone` to BWA-1

* hotfix: Remove `manufacturerOptions` from BSD-2

No `manufacturerOptions` used by BSD-2 when interacting with the `ssIasZone` cluster.

* fix: Tweak `configure` step for BWA-1

* hotfix: Use correct `write` payload format

* fix: Use cluster/attribute names instead of IDs

* fix: Simplify bindings & add missing converters
  • Loading branch information
burmistrzak committed Apr 11, 2024
1 parent c400db4 commit e02e867
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions src/devices/bosch.ts
Expand Up @@ -1030,17 +1030,8 @@ const definitions: Definition[] = [
await reporting.bind(endpoint, coordinatorEndpoint, [
'genPowerCfg',
'genPollCtrl',
'ssIasZone',
'manuSpecificBosch11',
]);
await reporting.batteryPercentageRemaining(endpoint);
await endpoint.configureReporting('ssIasZone', [{
attribute: 'zoneStatus',
minimumReportInterval: 0,
maximumReportInterval: constants.repInterval.MAX,
reportableChange: 0,
}]);
await endpoint.read('ssIasZone', ['zoneStatus']);
await endpoint.read('manuSpecificBosch11', ['alarmOnMotion'], manufacturerOptions);
},
exposes: [
Expand Down Expand Up @@ -1069,15 +1060,8 @@ const definitions: Definition[] = [
await reporting.bind(endpoint, coordinatorEndpoint, [
'genPowerCfg',
'genPollCtrl',
'ssIasZone',
]);
await reporting.batteryPercentageRemaining(endpoint);
await endpoint.configureReporting('ssIasZone', [{
attribute: 'zoneStatus',
minimumReportInterval: 0,
maximumReportInterval: constants.repInterval.MAX,
reportableChange: 0,
}]);
await endpoint.read('ssIasZone', ['zoneStatus']);
},
exposes: [
Expand Down Expand Up @@ -1473,6 +1457,7 @@ const definitions: Definition[] = [
vendor: 'Bosch',
description: 'Door/window contact II',
fromZigbee: [
fz.battery,
fzLocal.bosch_contact,
],
toZigbee: [],
Expand All @@ -1497,6 +1482,7 @@ const definitions: Definition[] = [
vendor: 'Bosch',
description: 'Door/window contact II plus',
fromZigbee: [
fz.battery,
fzLocal.bosch_contact,
],
toZigbee: [],
Expand Down

0 comments on commit e02e867

Please sign in to comment.