Skip to content

Commit

Permalink
Fix Third Reality devices don't change zoneState (#417)
Browse files Browse the repository at this point in the history
* Third Reality devices don't change zoneState

Like Tuya devices, Third Reality devices (contact sensor and motion sensor which I will add support for soon) appear to not change zoneState after enroll which leads to a failed interview even though the devices work properly

See Koenkk/zigbee2mqtt#4655

* Clean up extra spaces

* Apply Koenkk's suggestion

Co-authored-by: Tediore <tediore.maliwan@gmail.com>
  • Loading branch information
M.J. Wydra and Tediore committed Sep 11, 2021
1 parent a0e9959 commit 0ebf2cd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/controller/model/device.ts
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,9 @@ class Device extends Entity {
const lookup: {[s: string]: {
type?: DeviceType; manufacturerID?: number; manufacturerName?: string; powerSource?: string;
};} = {
'^3R.*?Z': {
type: 'EndDevice', powerSource: 'Battery'
},
'lumi\..*': {
type: 'EndDevice', manufacturerID: 4151, manufacturerName: 'LUMI', powerSource: 'Battery'
},
Expand Down

0 comments on commit 0ebf2cd

Please sign in to comment.