itavero / homebridge-z2m

Expose your Zigbee devices to HomeKit with ease, by integrating 🐝 Zigbee2MQTT with 🏠 Homebridge.
https://z2m.dev
Apache License 2.0
325 stars 49 forks source link

[Bug] Adding "excluded_keys": Device_Temperature - donot remove it from Homebridge #487

Closed rionshin closed 2 years ago

rionshin commented 2 years ago

Please use the template and fill in all the data requested below!

Describe the bug This is set in my configuration but i still can see Device_Temperature in the Homebridge and HomeKit as Temperature Sensor. I clear cached devices - still visible. "defaults": { "excluded_keys": [ "device_temperature" ] },

Same is happening if I setup - temperature is not removed : "devices": [                 {                     "id": "0x00158d0007e238ef",                     "exclude": true,                      "excluded_keys": [                         "device_temperature"                     ], Related devices All devices.

To Reproduce Setting exclude keys do not affect the behaviour of Devices, Temperature is still visible. I also excluded the Temp from the Zigbee2MQQT but Z2M is still showing it. devices: '0x00158d0007e238ef': friendly_name: MovementSensor filtered_attributes:

Jul 23 15:12:56 stefanhome npm[8048]: Zigbee2MQTT:info 2022-07-23 15:12:56: MQTT publish: topic 'zigbee2mqtt/MovementSensor', payload '{"battery":100,"illuminance":0,"illuminance_lux":0,"linkquality":44,"occupancy":false,"power_outage_count":7,"voltage":3185}'

Expected behavior When excluding temperature it should not appear in Homebridge and HomeKit.

MQTT messages If possible (and applicable), please provide the following: [{"definition":null,"endpoints":{"1":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"10":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"11":{"bindings":[],"clusters":{"input":["ssIasAce","genTime"],"output":["ssIasZone","ssIasWd"]},"configured_reportings":[],"scenes":[]},"110":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"12":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"13":{"bindings":[],"clusters":{"input":["genOta"],"output":[]},"configured_reportings":[],"scenes":[]},"2":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"242":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"3":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"4":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"47":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"5":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"6":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]},"8":{"bindings":[],"clusters":{"input":[],"output":[]},"configured_reportings":[],"scenes":[]}},"friendly_name":"Coordinator","ieee_address":"0x00124b001cce03b1","interview_completed":true,"interviewing":false,"network_address":0,"supported":false,"type":"Coordinator"},{"date_code":"20200312","definition":{"description":"MiJia light intensity sensor","exposes":[{"access":1,"description":"Remaining battery in %","name":"battery","property":"battery","type":"numeric","unit":"%","value_max":100,"value_min":0},{"access":1,"description":"Voltage of the battery in millivolts","name":"voltage","property":"voltage","type":"numeric","unit":"mV"},{"access":1,"description":"Raw measured illuminance","name":"illuminance","property":"illuminance","type":"numeric"},{"access":1,"description":"Measured illuminance in lux","name":"illuminance_lux","property":"illuminance_lux","type":"numeric","unit":"lx"},{"access":1,"description":"Number of power outages","name":"power_outage_count","property":"power_outage_count","type":"numeric"},{"access":1,"description":"Link quality (signal strength)","name":"linkquality","property":"linkquality","type":"numeric","unit":"lqi","value_max":255,"value_min":0}],"model":"GZCGQ01LM","options":[{"access":2,"description":"Number of digits after decimal point for illuminance, takes into effect on next report of device.","name":"illuminance_precision","property":"illuminance_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the illuminance value (percentual offset), takes into effect on next report of device.","name":"illuminance_calibration","property":"illuminance_calibration","type":"numeric"},{"access":2,"description":"Number of digits after decimal point for illuminance_lux, takes into effect on next report of device.","name":"illuminance_lux_precision","property":"illuminance_lux_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the illuminance_lux value (percentual offset), takes into effect on next report of device.","name":"illuminance_lux_calibration","property":"illuminance_lux_calibration","type":"numeric"}],"supports_ota":false,"vendor":"Xiaomi"},"endpoints":{"1":{"bindings":[{"cluster":"msIlluminanceMeasurement","target":{"endpoint":1,"ieee_address":"0x00124b001cce03b1","type":"endpoint"}}],"clusters":{"input":["genBasic","msIlluminanceMeasurement","genIdentify","genPowerCfg"],"output":["genIdentify"]},"configured_reportings":[{"attribute":"measuredValue","cluster":"msIlluminanceMeasurement","maximum_report_interval":3600,"minimum_report_interval":15,"reportable_change":500}],"scenes":[]}},"friendly_name":"IlluminationSensor","ieee_address":"0x54ef4410001fffed","interview_completed":true,"interviewing":false,"manufacturer":"XIAOMI","model_id":"lumi.sen_ill.mgl01","network_address":5147,"power_source":"Battery","software_build_id":"2019\u0000www.","supported":true,"type":"EndDevice"},{"date_code":"20170627","definition":{"description":"Aqara human body movement and illuminance sensor","exposes":[{"access":1,"description":"Remaining battery in %","name":"battery","property":"battery","type":"numeric","unit":"%","value_max":100,"value_min":0},{"access":1,"description":"Indicates whether the device detected occupancy","name":"occupancy","property":"occupancy","type":"binary","value_off":false,"value_on":true},{"access":1,"description":"Temperature of the device","name":"device_temperature","property":"device_temperature","type":"numeric","unit":"°C"},{"access":1,"description":"Voltage of the battery in millivolts","name":"voltage","property":"voltage","type":"numeric","unit":"mV"},{"access":1,"description":"Measured illuminance in lux","name":"illuminance_lux","property":"illuminance","type":"numeric","unit":"lx"},{"access":1,"description":"Measured illuminance in lux","name":"illuminance","property":"illuminance","type":"numeric","unit":"lx"},{"access":1,"description":"Number of power outages","name":"power_outage_count","property":"power_outage_count","type":"numeric"},{"access":1,"description":"Link quality (signal strength)","name":"linkquality","property":"linkquality","type":"numeric","unit":"lqi","value_max":255,"value_min":0}],"model":"RTCGQ11LM","options":[{"access":2,"description":"Number of digits after decimal point for device_temperature, takes into effect on next report of device.","name":"device_temperature_precision","property":"device_temperature_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the device_temperature value (absolute offset), takes into effect on next report of device.","name":"device_temperature_calibration","property":"device_temperature_calibration","type":"numeric"},{"access":2,"description":"Number of digits after decimal point for illuminance, takes into effect on next report of device.","name":"illuminance_precision","property":"illuminance_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the illuminance value (percentual offset), takes into effect on next report of device.","name":"illuminance_calibration","property":"illuminance_calibration","type":"numeric"},{"access":2,"description":"Number of digits after decimal point for illuminance_lux, takes into effect on next report of device.","name":"illuminance_lux_precision","property":"illuminance_lux_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the illuminance_lux value (percentual offset), takes into effect on next report of device.","name":"illuminance_lux_calibration","property":"illuminance_lux_calibration","type":"numeric"},{"access":2,"description":"Time in seconds after which occupancy is cleared after detecting it (default 90 seconds).","name":"occupancy_timeout","property":"occupancy_timeout","type":"numeric","value_min":0},{"access":2,"description":"Sends a message the last time occupancy (occupancy: true) was detected. When setting this for example to [10, 60] a {\"no_occupancy_since\": 10} will be send after 10 seconds and a {\"no_occupancy_since\": 60} after 60 seconds.","item_type":"number","name":"no_occupancy_since","property":"no_occupancy_since","type":"list"}],"supports_ota":false,"vendor":"Xiaomi"},"endpoints":{"1":{"bindings":[],"clusters":{"input":["genBasic","65535","msOccupancySensing","msIlluminanceMeasurement","ssIasZone","genPowerCfg","genIdentify"],"output":["genBasic","genOta"]},"configured_reportings":[],"scenes":[]}},"friendly_name":"MovementSensor","ieee_address":"0x00158d0007e238ef","interview_completed":true,"interviewing":false,"manufacturer":"LUMI","model_id":"lumi.sensor_motion.aq2","network_address":57059,"power_source":"Battery","software_build_id":"3000-0001","supported":true,"type":"EndDevice"},{"date_code":"20191205","definition":{"description":"Aqara temperature, humidity and pressure sensor","exposes":[{"access":1,"description":"Remaining battery in %","name":"battery","property":"battery","type":"numeric","unit":"%","value_max":100,"value_min":0},{"access":1,"description":"Measured temperature value","name":"temperature","property":"temperature","type":"numeric","unit":"°C"},{"access":1,"description":"Measured relative humidity","name":"humidity","property":"humidity","type":"numeric","unit":"%"},{"access":1,"description":"The measured atmospheric pressure","name":"pressure","property":"pressure","type":"numeric","unit":"hPa"},{"access":1,"description":"Voltage of the battery in millivolts","name":"voltage","property":"voltage","type":"numeric","unit":"mV"},{"access":1,"description":"Link quality (signal strength)","name":"linkquality","property":"linkquality","type":"numeric","unit":"lqi","value_max":255,"value_min":0}],"model":"WSDCGQ11LM","options":[{"access":2,"description":"Number of digits after decimal point for temperature, takes into effect on next report of device.","name":"temperature_precision","property":"temperature_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the temperature value (absolute offset), takes into effect on next report of device.","name":"temperature_calibration","property":"temperature_calibration","type":"numeric"},{"access":2,"description":"Number of digits after decimal point for humidity, takes into effect on next report of device.","name":"humidity_precision","property":"humidity_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the humidity value (absolute offset), takes into effect on next report of device.","name":"humidity_calibration","property":"humidity_calibration","type":"numeric"},{"access":2,"description":"Number of digits after decimal point for pressure, takes into effect on next report of device.","name":"pressure_precision","property":"pressure_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the pressure value (absolute offset), takes into effect on next report of device.","name":"pressure_calibration","property":"pressure_calibration","type":"numeric"}],"supports_ota":false,"vendor":"Xiaomi"},"endpoints":{"1":{"bindings":[],"clusters":{"input":["genBasic","genIdentify","65535","msTemperatureMeasurement","msPressureMeasurement","msRelativeHumidity"],"output":["genBasic","genGroups","65535"]},"configured_reportings":[],"scenes":[]}},"friendly_name":"TemperatureSensor","ieee_address":"0x00158d0007ed5c77","interview_completed":true,"interviewing":false,"manufacturer":"LUMI","model_id":"lumi.weather","network_address":13770,"power_source":"Battery","software_build_id":"3000-0001","supported":true,"type":"EndDevice"},{"date_code":"20201026","definition":{"description":"Temperature and humidity sensor","exposes":[{"access":1,"description":"Remaining battery in %","name":"battery","property":"battery","type":"numeric","unit":"%","value_max":100,"value_min":0},{"access":1,"description":"Measured temperature value","name":"temperature","property":"temperature","type":"numeric","unit":"°C"},{"access":1,"description":"Measured relative humidity","name":"humidity","property":"humidity","type":"numeric","unit":"%"},{"access":1,"description":"Voltage of the battery in millivolts","name":"voltage","property":"voltage","type":"numeric","unit":"mV"},{"access":1,"description":"Link quality (signal strength)","name":"linkquality","property":"linkquality","type":"numeric","unit":"lqi","value_max":255,"value_min":0}],"model":"SNZB-02","options":[{"access":2,"description":"Number of digits after decimal point for temperature, takes into effect on next report of device.","name":"temperature_precision","property":"temperature_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the temperature value (absolute offset), takes into effect on next report of device.","name":"temperature_calibration","property":"temperature_calibration","type":"numeric"},{"access":2,"description":"Number of digits after decimal point for humidity, takes into effect on next report of device.","name":"humidity_precision","property":"humidity_precision","type":"numeric","value_max":3,"value_min":0},{"access":2,"description":"Calibrates the humidity value (absolute offset), takes into effect on next report of device.","name":"humidity_calibration","property":"humidity_calibration","type":"numeric"}],"supports_ota":false,"vendor":"SONOFF"},"endpoints":{"1":{"bindings":[{"cluster":"msTemperatureMeasurement","target":{"endpoint":1,"ieee_address":"0x00124b001cce03b1","type":"endpoint"}},{"cluster":"msRelativeHumidity","target":{"endpoint":1,"ieee_address":"0x00124b001cce03b1","type":"endpoint"}},{"cluster":"genPowerCfg","target":{"endpoint":1,"ieee_address":"0x00124b001cce03b1","type":"endpoint"}}],"clusters":{"input":["genBasic","genIdentify","msTemperatureMeasurement","msRelativeHumidity","genPowerCfg"],"output":["genIdentify"]},"configured_reportings":[{"attribute":"measuredValue","cluster":"msTemperatureMeasurement","maximum_report_interval":1800,"minimum_report_interval":5,"reportable_change":20},{"attribute":"measuredValue","cluster":"msRelativeHumidity","maximum_report_interval":3600,"minimum_report_interval":10,"reportable_change":100},{"attribute":"batteryVoltage","cluster":"genPowerCfg","maximum_report_interval":62000,"minimum_report_interval":3600,"reportable_change":0},{"attribute":"batteryPercentageRemaining","cluster":"genPowerCfg","maximum_report_interval":62000,"minimum_report_interval":3600,"reportable_change":0}],"scenes":[]}},"friendly_name":"Temperatura2","ieee_address":"0x00124b0024ccf3d2","interview_completed":true,"interviewing":false,"manufacturer":"eWeLink","model_id":"TH01","network_address":1487,"power_source":"Battery","supported":true,"type":"EndDevice"}]

Versions used Please provide the version of the following pieces of software:

Screenshot 2022-07-23 at 15 07 03
rionshin commented 2 years ago

It is not real bug, as it update the Homebridge after movement was detected. it is good to update the documentation that change will not be applied until MQQT message/payload is posted.

rionshin commented 2 years ago

Not real bug more documentation issue.