Skip to content

Commit

Permalink
Add Z3 1st gen IKEA motion sensor signature (E1525) (#2137)
Browse files Browse the repository at this point in the history
* E1525 Zigbee 3 update

### Now IKEA is all Zigbee 3.
As expected it have loosing group binding and reporting wrong battery %.
Delete the device in ZHA and waiting one minute and adding it new and reconfigure it then its OK pared and its start reporting OK and also is doing check ins every 55 minute.

* Fix class name and dock strings.

* Update motionzha.py
  • Loading branch information
MattWestb committed Jan 26, 2023
1 parent 6b8cd2c commit 07f38fc
Showing 1 changed file with 64 additions and 4 deletions.
68 changes: 64 additions & 4 deletions zhaquirks/ikea/motionzha.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,14 @@
from zhaquirks.ikea import (
IKEA,
IKEA_CLUSTER_ID,
WWAH_CLUSTER_ID,
LightLinkCluster,
PowerConfiguration2CRCluster,
)


class IkeaTradfriMotion(CustomDevice):
"""Custom device representing IKEA of Sweden TRADFRI remote control."""
class IkeaTradfriMotionE1745_Var01(CustomDevice):
"""Custom device representing IKEA of Sweden TRADFRI motion sensor E1745 second gen variation 1."""

signature = {
# <SimpleDescriptor endpoint=1 profile=260 device_type=2128
Expand Down Expand Up @@ -88,8 +89,8 @@ class IkeaTradfriMotion(CustomDevice):
}


class IkeaTradfriMotionE1745(CustomDevice):
"""Custom device representing IKEA of Sweden TRADFRI motion sensor E1745."""
class IkeaTradfriMotionE1745_Var02(CustomDevice):
"""Custom device representing IKEA of Sweden TRADFRI motion sensor E1745 second gen variation 2."""

signature = {
# <SimpleDescriptor endpoint=1 profile=260 device_type=2128
Expand Down Expand Up @@ -147,3 +148,62 @@ class IkeaTradfriMotionE1745(CustomDevice):
}
}
}


class IkeaTradfriMotionE1525_Var01(CustomDevice):
"""Custom device representing IKEA of Sweden TRADFRI motion sensor E1525 first gen variation 1."""

signature = {
# <SimpleDescriptor endpoint=1 profile=260 device_type=2128
# device_version=1
# input_clusters=[0, 1, 3, 32, 4096, 64636]
# output_clusters=[3, 4, 6, 25, 4096]>
MODELS_INFO: [(IKEA, "TRADFRI motion sensor")],
ENDPOINTS: {
1: {
PROFILE_ID: zha.PROFILE_ID,
DEVICE_TYPE: zha.DeviceType.ON_OFF_SENSOR,
INPUT_CLUSTERS: [
Basic.cluster_id,
PowerConfiguration.cluster_id,
Identify.cluster_id,
PollControl.cluster_id,
LightLink.cluster_id,
IKEA_CLUSTER_ID,
WWAH_CLUSTER_ID,
],
OUTPUT_CLUSTERS: [
Identify.cluster_id,
Groups.cluster_id,
OnOff.cluster_id,
Ota.cluster_id,
LightLink.cluster_id,
],
}
},
}

replacement = {
ENDPOINTS: {
1: {
PROFILE_ID: zha.PROFILE_ID,
DEVICE_TYPE: zha.DeviceType.ON_OFF_SENSOR,
INPUT_CLUSTERS: [
Basic.cluster_id,
PowerConfiguration2CRCluster,
Identify.cluster_id,
PollControl.cluster_id,
LightLinkCluster,
IKEA_CLUSTER_ID,
WWAH_CLUSTER_ID,
],
OUTPUT_CLUSTERS: [
Identify.cluster_id,
Groups.cluster_id,
OnOff.cluster_id,
Ota.cluster_id,
LightLink.cluster_id,
],
}
}
}

0 comments on commit 07f38fc

Please sign in to comment.