Closed upais closed 2 years ago
@IvanUpa
Will test some configuration with my BRT-100-TRV, i thought the BRT aren't the best chose i have only drouble with them, even if they look great, if its possible i would buy some SPZB0001 or SEA801-Zigbee/SEA802-Zigbee.
But thats not the answer, right ;)
So first (i frogot to write it in the redme) the BRT haven't a system mode, so it can't switch off, my workaround for that is to set the target temp to 0 but for that in Zigbee2Mqtt the min temp must set to 0 aswell.
I also have a bug in the startup process, its possible that the entitys are not ready when the intigration is loaded, it will be changed in the next relase, if it fix it it would be greate, otherwise leave this issue open. or close it if its fixed by the next version.
@KartoffelToby
Yes, BRT-100-TRV is "wonderful" device :) I take it the problems are due to incorrect support in z2m? Some external converter won't fix it working in z2m?
Put min temp = 0, the errors remain :(
@IvanUpa I'll publish 0.7.0 today with the better startup routine, but i didn't think it fixes this issues, because it looks like the not working BRT has a different firmware.
Can you check that agains that BRT's thats working?
@KartoffelToby
It seems to be the same firmware. The problematic one: Read result of 'genBasic': {"zclVersion":3, "appVersion":64, "stackVersion":0, "hwVersion":1} Worker: Read result of 'genBasic': {"zclVersion":3, "appVersion":64, "stackVersion":0, "hwVersion":1}
I'll check on 0.7.0 as soon as it's published.
@KartoffelToby
Now it is :)
Logger: homeassistant Source: core.py:1092 First occurred: 18:15:14 (1 occurrences) Last logged: 18:15:14 Error doing job: Task exception was never retrieved Traceback (most recent call last): File "/config/custom_components/ai_thermostat/climate.py", line 406, in _async_sensor_changed return self.startUp() File "/config/custom_components/ai_thermostat/climate.py", line 269, in startUp if self.hass.states.get(self.window_sensors_entity_ids) is not None: File "/usr/src/homeassistant/homeassistant/core.py", line 1092, in get return self._states.get(entity_id.lower()) AttributeError: 'NoneType' object has no attribute 'lower'
Should be fixed with 0.7.1
But make sure your window sensor is a real sensor, or remove the line complete from your config if you haven't a window sensor.
@KartoffelToby
Problem solved, no error. But now the problem is with the ones that worked originally: climate.ai_bedroom - state=unavailable
There are no errors in the log.
Config:
Version 0.7.2
Reinstalled, renamed, waited 20+ minutes after loading HA. New issue or is it related?
@IvanUpa Yes to make it clear for the user, i set a active state for the TRV, so only when all entities in the config are updatet and active the TRV itself will switch to an active state otherwise it stay in unavailable
I think one of your sensors are not ready or didn't push any update to your HA. Can you check it? Sometimes it takes a while but even 5min are too long.
@KartoffelToby
Checked, "last_seen" of all devices is up to date. Two TRVs are using the same external sensor, only one TRV is "unavailable", and the other is working normally.
Removed TRV, paired it again - "unavailable". And it is controlled correctly by entities from z2m.
state=unavailable
I don't understand what the magic is again.
@IvanUpa
Do you use a PI or something like that? I found a super weird bug on PI HA Instaces thats result in exaclty this problem.
You can checkout 0.7.3.
@KartoffelToby
Now all four state=unavailable. What is PI? If Raspberry, then no, I have a VM with HassOS.
Rolled back to 0.7.1. At least two work.
Can you check the info log with 0.7.3? The intigration is waiting for the entities so it might be a miss configuration.
@KartoffelToby
Reinstalled the integration, refilled the config. Now the situation is similar to versions 0.7.1 and 0.7.2, i.e. state=unavailable on TRVs that worked on 0.7.0. (https://github.com/KartoffelToby/ai_thermostat/issues/43#issuecomment-981065865) And the other two that had problems in 0.6.0 work fine (https://github.com/KartoffelToby/ai_thermostat/issues/43#issue-1064181378)
Looked at the logs, there is nothing but: WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration ai_thermostat which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
@IvanUpa you need to enable the info log i think, and try to use 0.7.3 or 0.7.4 if its out:
logger:
default: warning
logs:
custom_components.ai_thermostat: info
@KartoffelToby
All four TRV state=unavailable. Through the z2m entity they are controlled. In the log:
2021-11-30 00:21:01 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_bedroom with version: 0.7.4 waiting for entity to be ready...
2021-11-30 00:21:01 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_hall with version: 0.7.4 waiting for entity to be ready...
2021-11-30 00:21:01 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_children with version: 0.7.4 waiting for entity to be ready...
2021-11-30 00:21:01 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_cabinet with version: 0.7.4 waiting for entity to be ready...
2021-11-30 00:21:01 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:21:01 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:21:16 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:21:16 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:21:31 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:21:31 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:21:46 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:21:46 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:22:02 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
..........
2021-11-30 00:24:32 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:24:32 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:24:47 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:24:47 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:25:02 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 00:25:02 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
@IvanUpa Looks like the entity for temperature_sensor and thermostat in your configuration is incorrect it didn't found a usable entity.
Can you run it again with:
logger:
default: warning
logs:
custom_components.ai_thermostat: debug
Also make sure you didn't run in the same issue as #57
And your thermostat entity is a real climate trv entity and your temperature_sensor is a target who reported a temperature as a state
@KartoffelToby
2021-11-30 12:20:11 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 12:20:11 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 12:20:11 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 12:20:11 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
Changed to another sensor, now all four TVRs use different sensors for target temperature. And again all state = unavailable.
In the config a long time ago: mqtt: base_topic: zigbee2mqtt include_device_information: true
@IvanUpa
is this the only log output?
Can you try to click in HA under Settings > Servercontrol > Reload YAML and than AI_THERMOSTAT And look at your logs again?
@KartoffelToby
On 0.7.5 I do not see the error. But also does not work correctly. After starting HA I wait 10+min, all four TRV state=unavailable. I do Reload YAML for AI_THERMOSTAT and two TRVs start, and ai_children and ai_hall have the same external temperature sensor.
2021-11-30 23:42:53 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:42:53 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:42:53 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:42:53 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:42:56 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_bedroom with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:42:56 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_hall with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:42:56 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_children with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:42:56 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_cabinet with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:43:01 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 23:43:01 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 23:43:16 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 23:43:16 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
........... Reload YAML for AI_THERMOSTAT ...........
2021-11-30 23:55:34 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_bedroom with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:55:34 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:55:34 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_hall with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:55:34 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:55:34 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_children with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:55:34 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:55:34 INFO (MainThread) [custom_components.ai_thermostat.climate] Starting ai_thermostat for ai_cabinet with version: 0.7.5 waiting for entity to be ready...
2021-11-30 23:55:34 DEBUG (MainThread) [custom_components.ai_thermostat.climate] Undefined target temperature, falling back to 5.0
2021-11-30 23:55:39 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 23:55:39 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 23:55:39 INFO (MainThread) [custom_components.ai_thermostat.climate] Register ai_thermostat with name: ai_children
2021-11-30 23:55:39 INFO (MainThread) [custom_components.ai_thermostat.climate] Register ai_thermostat with name: ai_cabinet
2021-11-30 23:55:46 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
2021-11-30 23:55:46 INFO (MainThread) [custom_components.ai_thermostat.climate] retry in 15s...
Should be fix finally in 0.7.6
Continuing the problem: https://github.com/KartoffelToby/ai_thermostat/issues/1 p.s. I wrote in a closed issue because I thought that it would be more correct to lead one problem in one issue. I'm sorry.
My config is:
Description
Bought two more BRT-100-TRV, connected to z2m and on HA reboot errors (HA startup time: 30-45 seconds):
Logger: custom_components.ai_thermostat.models.models Source: /config/custom_components/ai_thermostat/models/models.py:17 Integration: ai_thermostat (documentation, issues) First occurred: 10:14:09 (1 occurrences) Last logged: 10:14:09 ai_thermostat: can't read the device model of TVR, Enable include_device_information in z2m or checkout issue #1 NoneType: None
Logger: custom_components.ai_thermostat.models.models Source: /config/custom_components/ai_thermostat/models/models.py:42 Integration: ai_thermostat (documentation, issues) First occurred: 10:14:10 (1 occurrences) Last logged: 10:14:10 ai_thermostat: can't read the device model of TVR, Enable include_device_information in z2m or checkout issue #1 NoneType: None
Tried:
1) Reinstall the integration. 2) Reconnected BRT-100-TRV to z2m 3) include_device_information = false -> Reboot HA -> true 4) Rename TRV 5) Connect one at a time
p.s. I have two more thermostats just like that, no problem with them. I don't see any difference between them. (config issues #25)
Versions
TRV Model: BRT-100-TRV Z2M Version: 1.22.0-3 HA Version: 2021.11.5 ai_thermostat version: 0.6.0