nitaybz / homebridge-sensibo-ac

Homebridge plugin for Sensibo - Smart AC Control
GNU General Public License v3.0
70 stars 15 forks source link

Changes not reliably passed through to Sensibo for Homekit #150

Open nashw83 opened 3 months ago

nashw83 commented 3 months ago

Sensibo Sky unit - both scene and manual set mode and temp via HomeKit does not reliably set in Sensibo.

Example: Set temp to 20 on heat will set to 18 which was most recent setting. Heater on, set to target 18. Change temp to 20 in Home app. AC beeps, Sensibo logs as API call kept state on, temp does not change in Sensibo and current target snaps back to 18* in Home app.

Another example when mode is set to dry, turn AC off then set scene with heat parameters the unit will turn back on to last state of dry.

Sensibo for Homebridge v2.5.1 Homebridge v1.8.4 Node.js v20.15.1

nashw83 commented 3 months ago

Logs for first example:

Click to expand Logs: ``` [30/07/2024, 19:55:27] [homebridge-sensibo-ac] Refreshing state... [30/07/2024, 19:55:27] [homebridge-sensibo-ac] Creating GET request to Sensibo API -> [30/07/2024, 19:55:27] [homebridge-sensibo-ac] https://home.sensibo.com/api/v2/users/me/pods?fields=id,acState,measurements,location,occupancy,smartMode,motionSensors,filtersCleaning,serial,pureBoostConfig,homekitSupported,remoteCapabilities,room,temperatureUnit,productModel [30/07/2024, 19:55:27] [homebridge-sensibo-ac] Kitchen AC (SET) - Target Heating Temperature: 20ºC [30/07/2024, 19:55:27] [homebridge-sensibo-ac] StateHandler SET Property: targetTemperature [30/07/2024, 19:55:27] [homebridge-sensibo-ac] StateHandler SET New Value: 20 [30/07/2024, 19:55:27] [homebridge-sensibo-ac] Kitchen AC - updating setProcessing to true, Prop: targetTemperature [30/07/2024, 19:55:27] [homebridge-sensibo-ac] Kitchen AC (SET) - HeaterCooler State: HEAT [30/07/2024, 19:55:27] [homebridge-sensibo-ac] StateHandler SET Property: active [30/07/2024, 19:55:27] [homebridge-sensibo-ac] StateHandler SET New Value: true [30/07/2024, 19:55:27] [homebridge-sensibo-ac] Kitchen AC - active already set to true, returning without updating [30/07/2024, 19:55:27] [homebridge-sensibo-ac] StateHandler SET Property: mode [30/07/2024, 19:55:27] [homebridge-sensibo-ac] StateHandler SET New Value: "HEAT" [30/07/2024, 19:55:27] [homebridge-sensibo-ac] Kitchen AC - mode already set to "HEAT", returning without updating [30/07/2024, 19:55:28] [homebridge-sensibo-ac] Kitchen AC -> sensiboFormattedACState start [30/07/2024, 19:55:28] [homebridge-sensibo-ac] Kitchen AC - before calling API to set new state [30/07/2024, 19:55:28] [homebridge-sensibo-ac] Creating POST request to Sensibo API -> [30/07/2024, 19:55:28] [homebridge-sensibo-ac] https://home.sensibo.com/api/v2/pods/iYMwMZJM/acStates [30/07/2024, 19:55:28] [homebridge-sensibo-ac] data: { "acState": { "on": true, "mode": "heat", "temperatureUnit": "C", "targetTemperature": 20, "swing": "rangeFull", "horizontalSwing": "stopped", "fanLevel": "high" } } [30/07/2024, 19:55:29] [homebridge-sensibo-ac] Successful GET response: [30/07/2024, 19:55:29] [homebridge-sensibo-ac] [ { "id": "iYMwMZJM", "temperatureUnit": "C", "room": { "uid": "WrgWzTQH", "name": "Kitchen", "icon": "Kitchen", "pureBoostConfig": null }, "acState": { "timestamp": { "time": "2024-07-30T09:55:29.016184Z", "secondsAgo": -1 }, "on": true, "mode": "heat", "targetTemperature": 18, "temperatureUnit": "C", "fanLevel": "high", "swing": "rangeFull", "horizontalSwing": "stopped" }, "location": { "occupancy": "someone", "name": "1122", "id": "Frp4umhbD4" }, "productModel": "skyplus", "serial": "C392102916", "motionSensors": [ { "id": "ms_hLqtFsPZ", "qrId": "KTFASSVBAQ", "firmwareVersion": "V17", "firmwareType": "nrf52", "macAddress": "fb:c4:86:6c:e2:a4", "productModel": "motion_sensor", "configGroup": "stable", "serial": "R392102916", "parentDeviceUid": "iYMwMZJM", "measurements": { "time": { "time": "2024-07-30T09:54:15.303195Z", "secondsAgo": 72 }, "rssi": -63, "temperature": 16.7, "humidity": 58, "motion": false, "batteryVoltage": 3000 }, "connectionStatus": { "isAlive": true, "lastSeen": { "time": "2024-07-30T09:54:15.303195Z", "secondsAgo": 72 } }, "isMainSensor": true } ], "filtersCleaning": { "acOnSecondsSinceLastFiltersClean": 5248575, "filtersCleanSecondsThreshold": 1080000, "lastFiltersCleanTime": null, "shouldCleanFilters": true }, "pureBoostConfig": null, "homekitSupported": true, "remoteCapabilities": { "modes": { "cool": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "heat": { "temperatures": { "F": { "isNative": false, "values": [ 50, 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 10, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "dry": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "auto": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "fan": { "temperatures": {}, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] } } }, "smartMode": { "enabled": true, "type": "temperature", "deviceUid": "iYMwMZJM", "lowTemperatureThreshold": null, "highTemperatureThreshold": 26, "lowTemperatureState": null, "highTemperatureState": { "on": true, "targetTemperature": 24, "temperatureUnit": "C", "mode": "cool", "fanLevel": "auto", "swing": "rangeFull", "horizontalSwing": "fixedCenter" }, "lowTemperatureWebhook": null, "highTemperatureWebhook": null, "sync_with_ac_power": false }, "measurements": { "time": { "time": "2024-07-30T09:54:15.303195Z", "secondsAgo": 73 }, "temperature": 19.4, "humidity": 54.1, "feelsLike": 19.4, "rssi": -30, "motion": false, "roomIsOccupied": true } }, { "id": "9z4HxdVi", "temperatureUnit": "C", "room": { "uid": "AkAFZVKo", "name": "Bedroom", "icon": "Bedroom", "pureBoostConfig": null }, "acState": { "timestamp": { "time": "2024-07-30T09:55:29.026784Z", "secondsAgo": -1 }, "on": true, "mode": "heat", "targetTemperature": 20, "temperatureUnit": "C", "fanLevel": "auto", "swing": "rangeFull", "horizontalSwing": "stopped" }, "location": { "occupancy": "someone", "name": "1122", "id": "Frp4umhbD4" }, "productModel": "skyplus", "serial": "C392102915", "motionSensors": [], "filtersCleaning": { "acOnSecondsSinceLastFiltersClean": 6342325, "filtersCleanSecondsThreshold": 1080000, "lastFiltersCleanTime": null, "shouldCleanFilters": true }, "pureBoostConfig": null, "homekitSupported": true, "remoteCapabilities": { "modes": { "cool": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ] } }, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "heat": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ] } }, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "fan": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ] } }, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "dry": { "temperatures": {}, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "auto": { "temperatures": {}, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] } } }, "smartMode": { "enabled": false, "type": "temperature", "deviceUid": "9z4HxdVi", "lowTemperatureThreshold": null, "highTemperatureThreshold": 26, "lowTemperatureState": null, "highTemperatureState": { "on": true, "targetTemperature": 25, "temperatureUnit": "C", "mode": "cool", "fanLevel": "auto", "swing": "rangeFull", "horizontalSwing": "stopped" }, "lowTemperatureWebhook": null, "highTemperatureWebhook": null, "sync_with_ac_power": false }, "measurements": { "time": { "time": "2024-07-30T09:54:07.487104Z", "secondsAgo": 81 }, "temperature": 17.5, "humidity": 55.7, "feelsLike": 17.5, "rssi": -35, "motion": false, "roomIsOccupied": null } } ] [30/07/2024, 19:55:29] [homebridge-sensibo-ac] Refreshing state completed. [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Successful POST response: [30/07/2024, 19:55:32] [homebridge-sensibo-ac] { "status": "success", "result": { "id": "Fhp5Ffa3Jt", "time": { "time": "2024-07-30T09:55:30Z", "secondsAgo": 0 }, "status": "Success", "acState": { "timestamp": { "time": "2024-07-30T09:55:31.905586Z", "secondsAgo": -1 }, "on": true, "mode": "heat", "targetTemperature": 18, "temperatureUnit": "C", "nativeTargetTemperature": 20, "nativeTemperatureUnit": "C", "fanLevel": "high", "swing": "rangeFull", "horizontalSwing": "stopped" }, "changedProperties": [], "reason": "UserAPI", "failureReason": null } } [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - Setting '19.4' for characteristic CurrentTemperature on service HeaterCoolerService, value was '19.400000000000006' [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '54.1' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service HeaterCoolerService... rounding to 54 [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '54' equals '54' for characteristic CurrentRelativeHumidity on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '54.1' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service DryService... rounding to 54 [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '54' equals '54' for characteristic CurrentRelativeHumidity on service DryService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '1' equals '1' for characteristic Active on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '20' equals '20' for characteristic HeatingThresholdTemperature on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - Setting '20' for characteristic CoolingThresholdTemperature on service HeaterCoolerService, value was '18' [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '83' equals '83' for characteristic RotationSpeed on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '1' equals '1' for characteristic FilterChangeIndication on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic FilterLifeLevel on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '1' equals '1' for characteristic TargetHeaterCoolerState on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '2' equals '2' for characteristic CurrentHeaterCoolerState on service HeaterCoolerService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic Active on service DryService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic CurrentHumidifierDehumidifierState on service DryService... skipping update [30/07/2024, 19:55:32] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic Active on service FanService... skipping update [30/07/2024, 19:55:37] [homebridge-sensibo-ac] Refreshing state... [30/07/2024, 19:55:37] [homebridge-sensibo-ac] Creating GET request to Sensibo API -> [30/07/2024, 19:55:37] [homebridge-sensibo-ac] https://home.sensibo.com/api/v2/users/me/pods?fields=id,acState,measurements,location,occupancy,smartMode,motionSensors,filtersCleaning,serial,pureBoostConfig,homekitSupported,remoteCapabilities,room,temperatureUnit,productModel [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Successful GET response: [30/07/2024, 19:55:39] [homebridge-sensibo-ac] [ { "id": "iYMwMZJM", "temperatureUnit": "C", "room": { "uid": "WrgWzTQH", "name": "Kitchen", "icon": "Kitchen", "pureBoostConfig": null }, "acState": { "timestamp": { "time": "2024-07-30T09:55:39.158129Z", "secondsAgo": 0 }, "on": true, "mode": "heat", "targetTemperature": 18, "temperatureUnit": "C", "fanLevel": "high", "swing": "rangeFull", "horizontalSwing": "stopped" }, "location": { "occupancy": "someone", "name": "1122", "id": "Frp4umhbD4" }, "productModel": "skyplus", "serial": "C392102916", "motionSensors": [ { "id": "ms_hLqtFsPZ", "qrId": "KTFASSVBAQ", "firmwareVersion": "V17", "firmwareType": "nrf52", "macAddress": "fb:c4:86:6c:e2:a4", "productModel": "motion_sensor", "configGroup": "stable", "serial": "R392102916", "parentDeviceUid": "iYMwMZJM", "measurements": { "time": { "time": "2024-07-30T09:54:15.303195Z", "secondsAgo": 83 }, "rssi": -63, "temperature": 16.7, "humidity": 58, "motion": false, "batteryVoltage": 3000 }, "connectionStatus": { "isAlive": true, "lastSeen": { "time": "2024-07-30T09:54:15.303195Z", "secondsAgo": 83 } }, "isMainSensor": true } ], "filtersCleaning": { "acOnSecondsSinceLastFiltersClean": 5249323, "filtersCleanSecondsThreshold": 1080000, "lastFiltersCleanTime": null, "shouldCleanFilters": true }, "pureBoostConfig": null, "homekitSupported": true, "remoteCapabilities": { "modes": { "cool": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "heat": { "temperatures": { "F": { "isNative": false, "values": [ 50, 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 10, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "dry": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "auto": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86, 88 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31 ] } }, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] }, "fan": { "temperatures": {}, "fanLevels": [ "quiet", "low", "medium", "medium_high", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterLeft", "fixedCenterRight", "fixedLeft", "fixedRight", "stopped", "rangeFull" ] } } }, "smartMode": { "enabled": true, "type": "temperature", "deviceUid": "iYMwMZJM", "lowTemperatureThreshold": null, "highTemperatureThreshold": 26, "lowTemperatureState": null, "highTemperatureState": { "on": true, "targetTemperature": 24, "temperatureUnit": "C", "mode": "cool", "fanLevel": "auto", "swing": "rangeFull", "horizontalSwing": "fixedCenter" }, "lowTemperatureWebhook": null, "highTemperatureWebhook": null, "sync_with_ac_power": false }, "measurements": { "time": { "time": "2024-07-30T09:54:15.303195Z", "secondsAgo": 83 }, "temperature": 19.4, "humidity": 54.1, "feelsLike": 19.4, "rssi": -30, "motion": false, "roomIsOccupied": true } }, { "id": "9z4HxdVi", "temperatureUnit": "C", "room": { "uid": "AkAFZVKo", "name": "Bedroom", "icon": "Bedroom", "pureBoostConfig": null }, "acState": { "timestamp": { "time": "2024-07-30T09:55:39.172720Z", "secondsAgo": 0 }, "on": true, "mode": "heat", "targetTemperature": 20, "temperatureUnit": "C", "fanLevel": "auto", "swing": "rangeFull", "horizontalSwing": "stopped" }, "location": { "occupancy": "someone", "name": "1122", "id": "Frp4umhbD4" }, "productModel": "skyplus", "serial": "C392102915", "motionSensors": [], "filtersCleaning": { "acOnSecondsSinceLastFiltersClean": 6342325, "filtersCleanSecondsThreshold": 1080000, "lastFiltersCleanTime": null, "shouldCleanFilters": true }, "pureBoostConfig": null, "homekitSupported": true, "remoteCapabilities": { "modes": { "cool": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ] } }, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "heat": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ] } }, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "fan": { "temperatures": { "F": { "isNative": false, "values": [ 61, 63, 64, 66, 68, 70, 72, 73, 75, 77, 79, 81, 82, 84, 86 ] }, "C": { "isNative": true, "values": [ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30 ] } }, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "dry": { "temperatures": {}, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] }, "auto": { "temperatures": {}, "fanLevels": [ "low", "medium", "high", "auto", "strong" ], "swing": [ "stopped", "fixedTop", "fixedMiddleTop", "fixedMiddle", "fixedMiddleBottom", "fixedBottom", "rangeFull" ], "horizontalSwing": [ "fixedCenter", "fixedCenterRight", "fixedRight", "fixedCenterLeft", "fixedLeft", "rangeFull", "stopped" ] } } }, "smartMode": { "enabled": false, "type": "temperature", "deviceUid": "9z4HxdVi", "lowTemperatureThreshold": null, "highTemperatureThreshold": 26, "lowTemperatureState": null, "highTemperatureState": { "on": true, "targetTemperature": 25, "temperatureUnit": "C", "mode": "cool", "fanLevel": "auto", "swing": "rangeFull", "horizontalSwing": "stopped" }, "lowTemperatureWebhook": null, "highTemperatureWebhook": null, "sync_with_ac_power": false }, "measurements": { "time": { "time": "2024-07-30T09:55:36.540288Z", "secondsAgo": 2 }, "temperature": 17.5, "humidity": 55.8, "feelsLike": 17.5, "rssi": -35, "motion": false, "roomIsOccupied": null } } ] [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Refreshing state completed. [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Updating AC state in Cache + HomeKit for iYMwMZJM [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - Setting '19.4' for characteristic CurrentTemperature on service HeaterCoolerService, value was '19.400000000000006' [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '54.1' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service HeaterCoolerService... rounding to 54 [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '54' equals '54' for characteristic CurrentRelativeHumidity on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '54.1' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service DryService... rounding to 54 [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '54' equals '54' for characteristic CurrentRelativeHumidity on service DryService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '1' equals '1' for characteristic Active on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - Setting '18' for characteristic HeatingThresholdTemperature on service HeaterCoolerService, value was '20' [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - Setting '18' for characteristic CoolingThresholdTemperature on service HeaterCoolerService, value was '20' [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '83' equals '83' for characteristic RotationSpeed on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '1' equals '1' for characteristic FilterChangeIndication on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic FilterLifeLevel on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '1' equals '1' for characteristic TargetHeaterCoolerState on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '2' equals '2' for characteristic CurrentHeaterCoolerState on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic Active on service DryService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic CurrentHumidifierDehumidifierState on service DryService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen AC - '0' equals '0' for characteristic Active on service FanService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Updating Climate React Switch state in HomeKit for iYMwMZJM [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen ClimateReact - 'true' equals 'true' for characteristic On on service ClimateReactSwitchService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Updating Humidity Sensor state in HomeKit for iYMwMZJM [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Humidity - '54.1' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service HumiditySensorService... rounding to 54 [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Humidity - '54' equals '54' for characteristic CurrentRelativeHumidity on service HumiditySensorService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Updating Room Sensor state in cache + HomeKit for iYMwMZJM [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Sensor - 'false' equals 'false' for characteristic MotionDetected on service MotionSensorService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Sensor - Setting '16.7' for characteristic CurrentTemperature on service TemperatureSensorService, value was '16.700000000000003' [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Sensor - '58' equals '58' for characteristic CurrentRelativeHumidity on service HumiditySensorService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Sensor - '0' equals '0' for characteristic StatusLowBattery on service MotionSensorService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Sensor - '0' equals '0' for characteristic StatusLowBattery on service TemperatureSensorService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Kitchen Sensor - '0' equals '0' for characteristic StatusLowBattery on service HumiditySensorService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Updating AC state in Cache + HomeKit for 9z4HxdVi [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '17.5' equals '17.5' for characteristic CurrentTemperature on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '55.8' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service HeaterCoolerService... rounding to 56 [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '56' equals '56' for characteristic CurrentRelativeHumidity on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '55.8' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service DryService... rounding to 56 [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '56' equals '56' for characteristic CurrentRelativeHumidity on service DryService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '1' equals '1' for characteristic Active on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '20' equals '20' for characteristic HeatingThresholdTemperature on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '20' equals '20' for characteristic CoolingThresholdTemperature on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '0' equals '0' for characteristic RotationSpeed on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '1' equals '1' for characteristic FilterChangeIndication on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '0' equals '0' for characteristic FilterLifeLevel on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '1' equals '1' for characteristic TargetHeaterCoolerState on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '2' equals '2' for characteristic CurrentHeaterCoolerState on service HeaterCoolerService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '0' equals '0' for characteristic Active on service DryService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '0' equals '0' for characteristic CurrentHumidifierDehumidifierState on service DryService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom AC - '0' equals '0' for characteristic Active on service FanService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Updating Climate React Switch state in HomeKit for 9z4HxdVi [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom ClimateReact - 'false' equals 'false' for characteristic On on service ClimateReactSwitchService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Updating Humidity Sensor state in HomeKit for 9z4HxdVi [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom Humidity - '55.8' doesn't meet the rounding requird by minStep: 1 for characteristic CurrentRelativeHumidity on service HumiditySensorService... rounding to 56 [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Bedroom Humidity - '56' equals '56' for characteristic CurrentRelativeHumidity on service HumiditySensorService... skipping update [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Syncing HomeKit Cache [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Device: iYMwMZJM, Model: skyplus, airConditionerIsNew: false [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Device: iYMwMZJM, roomSensorIsNew: false [30/07/2024, 19:55:39] [homebridge-sensibo-ac] Device: 9z4HxdVi, Model: skyplus, airConditionerIsNew: false ```
benwebbbenwebb commented 3 months ago

Thanks for the logs @nashw83

Does the issue happen often or only intermittently/infrequently?

I'll definitely look in to it, but based on the logs provided it seems like maybe a race condition? Possibly even within the Sensibo side, as I can see the API GET request and POST request happening in parallel:

  1. GET request started
  2. POST request started (with 20º in payload)
  3. GET request completes (showing 18º)
  4. POST request completes, weirdly showing both 18º ("targetTemperature") and 20º ("nativeTargetTemperature")... for comparison my response payload (included below) only ever has "targetTemperature"
  5. New GET request starts
  6. New GET request completes (still showing 18º) - this causes the Home app to 'snap back' to 18º

I'm wondering if the GET and POST running in parallel are causing some sort of mismatch!

Your success response

[30/07/2024, 19:55:28] [homebridge-sensibo-ac] data: {
    "acState": {
        "on": true,
        "mode": "heat",
        "temperatureUnit": "C",
        "targetTemperature": 20,
        "swing": "rangeFull",
        "horizontalSwing": "stopped",
        "fanLevel": "high"
    }
}
... GET response ...
[30/07/2024, 19:55:32] [homebridge-sensibo-ac] Successful POST response:
[30/07/2024, 19:55:32] [homebridge-sensibo-ac] {
    "status": "success",
    "result": {
        "id": "ZZZ",
        "time": {
            "time": "2024-07-30T09:55:30Z",
            "secondsAgo": 0
        },
        "status": "Success",
        "acState": {
            "timestamp": {
                "time": "2024-07-30T09:55:31.905586Z",
                "secondsAgo": -1
            },
            "on": true,
            "mode": "heat",
            "targetTemperature": 18,
            "temperatureUnit": "C",
            "nativeTargetTemperature": 20, // this
            "nativeTemperatureUnit": "C",  // and this
            "fanLevel": "high",
            "swing": "rangeFull",
            "horizontalSwing": "stopped"
        },
        "changedProperties": [],  // also missing
        "reason": "UserAPI",
        "failureReason": null
    }
}

My success response

[30/07/2024, 8:42:03 pm] [SensiboAC] data: {
    "acState": {
        "on": true,
        "mode": "heat",
        "temperatureUnit": "C",
        "targetTemperature": 24,
        "swing": "rangeFull",
        "horizontalSwing": "rangeFull",
        "fanLevel": "auto"
    }
}
[30/07/2024, 8:42:05 pm] [SensiboAC] Successful POST response:
[30/07/2024, 8:42:05 pm] [SensiboAC] {
    "status": "success",
    "result": {
        "id": "XXX",
        "time": {
            "time": "2024-07-30T10:42:04Z",
            "secondsAgo": 0
        },
        "status": "Success",
        "acState": {
            "timestamp": {
                "time": "2024-07-30T10:42:05.731336Z",
                "secondsAgo": -1
            },
            "on": true,
            "mode": "heat",
            "targetTemperature": 24,
            "temperatureUnit": "C",
            "fanLevel": "auto",
            "swing": "rangeFull",
            "horizontalSwing": "rangeFull"
        },
        "changedProperties": [
            "targetTemperature"  // this is set
        ],
        "reason": "UserAPI",
        "failureReason": null
    }
}

When you do a temp change, and it works as expected, what does your Successful POST response: output look like?

Also, does your unit in Sensibo use ºC (rather than F)? Has it ever been set to F? Does it have alternate remote codes?

nashw83 commented 3 months ago

Always been Celsius, unless it defaulted to Fahrenheit when it was first configured and immediately changed it to C. While testing this example last night I didn’t see a time when it did work after over half a dozen tries. By alternate remote codes do you mean manually set remote type for the AC?

nashw83 commented 3 months ago

It looks like it’s specific to this Kitchen unit. It’s not accepting a heat temp higher than 18 or a cool temp lower than 20 via HomeKit. But can be set via Sensibo app and read this per setting in Home. Whether or not it’s actually setting the temp is another question, but perhaps it is specific to its remote profile. The second unit has a different profile, even though it’s the same brand and similar generation unit the first remote did not work with it (and it had a universal remote when we bought the house).

I’ll need to do more testing when I’m back home and pull the logs again.

Both units however do have the intermittent issue of returning to dry mode if this was the last mode, despite set of a different mode via a scene.

benwebbbenwebb commented 2 months ago

Always been Celsius, unless it defaulted to Fahrenheit when it was first configured and immediately changed it to C. While testing this example last night I didn’t see a time when it did work after over half a dozen tries. By alternate remote codes do you mean manually set remote type for the AC?

Hi @nashw83

I actually meant changing the Remote Code within the Sensibo App...

With the unit open in Sensibo, click the top right cog to get to Settings, then scroll to 'Change remote type'. From there you can try pairing the remote again, or even click 'Manual setup' to get a list of potential remote codes (they all have silly names like "Radiant Vampire Bat" or "Reassured Partridge").

Maybe worth a shot?

Other than that we'd probably need to get Sensibo support as this is the first time I've seen a successful temperature request, in native C degrees, then get reported back with a different temp!

Also, next time you are testing, wondering if you use HomeKit to set the temp to something really high like 28, does the API response payload still report back 18?

nashw83 commented 2 months ago

Embarrassingly, I've come cross the issue here. There is a premium Sensibo feature for user management which guardrails the temp limits for a user and I had forgot this was set. As I'm using a separate user for the API to ensure good logging practices I had this enabled to ensure the kids etc weren't trying to set the AC to an unachievable number.

image

That said there were some other changes that weren't coming across, such as snapping back to a prior mode such as Dry although the scene requested Cool. This will require more testing and review of logs however.

benwebbbenwebb commented 2 months ago

Thanks for the update @nashw83

Glad to hear you’ve nailed down the temperature inconsistency. It’s also good to know that exists for the future (in case others also experience it).

Please let me know how you go once you’ve had some time to check on the mode “snapping” further (and have logs of that issue).