core
core copied to clipboard
Home Assistant does not update entity for ZigBee2MQTT device on change
The problem
Everything done with a freshly paired Danfoss Ally TRV.
The Z2M log in the integration log field.
Steps taken:
- I have paired my TRV with Z2M and named it
trv.uf_office
. - In the Z2M map it shows properly connected with a high LQI.
- In the dashboard I have got an Entities Card with the
climate.trv_uf_office
. - The TRV is set to 23 degrees currently.
- When I change the occupied_heating_setpoint of the TRV in the Lovelace dashboard to e.g. 24 now, then shows 24 for some seconds and then the occupied_heating_setpoint in the dashboard jumps back to 23.
But the TRV is set to 24 degrees and starts to heat after some seconds. When I check the Z2M logs, I clearly see the correct MQTT messages sent. When I go to the Z2M Devices page, open up the view of the TRV -> Exposes it shows all the values N/A or Null.
When I press the load value buttons (circulating arrows) for occupied_heating_setpoint and local_temperature then it sends the get MQTT messages and updates the values in the Z2M expose page and also the Lovelace dashboard.
But I would expect this to happen automatically when I change the temperature in the dashboard, and also when an automation changes them.
To me it sounds like HA should send out the Received MQTT message on 'zigbee2mqtt/trv.uf_office/get' with data '{"occupied_heating_setpoint":""}'
message whenever a change in the dashboard entitiy happens.
A short screencast of the issue: https://youtu.be/f99aG5Xq5PY
What version of Home Assistant Core has the issue?
2022.10.5
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant OS
Integration causing the issue
ZigBee2MQTT / core mqtt
Link to integration documentation on our website
No response
Diagnostics information
cd /mnt/data/supervisor/homeassistant/zigbee2mqtt/log/2022-10-23.11-18-02/ tail -f log.txt | grep trv.uf_office:
debug 2022-10-24 10:41:38: Received MQTT message on **'zigbee2mqtt/trv.uf_office/set/occupied_heating_setpoint' with data '24.0'**
debug 2022-10-24 10:41:38: Publishing 'set' 'occupied_heating_setpoint' to 'trv.uf_office'
debug 2022-10-24 10:41:55: Received MQTT message on 'zigbee2mqtt/trv.uf_office/get' with data '{"occupied_heating_setpoint":""}'
debug 2022-10-24 10:41:55: Publishing get **'get' 'occupied_heating_setpoint'** to 'trv.uf_office'
debug 2022-10-24 10:41:58: Received Zigbee message from 'trv.uf_office', type 'readResponse', cluster 'hvacThermostat', data '**{"occupiedHeatingSetpoint":2400}**' from endpoint 1 with groupID 0
info 2022-10-24 10:41:58: MQTT publish: topic 'zigbee2mqtt/trv.uf_office', payload '{"adaptation_run_control":null,"adaptation_run_settings":null,"adaptation_run_status":null,"algorithm_scale_factor":null,"battery":null,"day_of_week":null,"external_measured_room_sensor":null,"heat_available":null,"heat_required":null,"keypad_lockout":"unlock","linkquality":167,"load_balancing_enable":null,"load_estimate":null,"load_room_mean":null,"local_temperature":24.22,"mounted_mode_active":null,"mounted_mode_control":null,"occupied_heating_setpoint":24,"pi_heating_demand":null,"preheat_status":null,"programming_operation_mode":"setpoint","radiator_covered":null,"regulation_setpoint_offset":null,"running_state":null,"setpoint_change_source":null,"thermostat_vertical_orientation":null,"trigger_time":null,"update":{"state":null},"update_available":null,"viewing_direction":null,"window_open_external":null,"window_open_feature":null,"window_open_internal":null}'
Example YAML snippet
No response
Anything in the logs that might be useful for us?
2022-10-24 10:43:32.574 WARNING (MainThread) [homeassistant.helpers.template] Template variable warning: 'dict object' has no attribute 'system_mode' when rendering '{{ value_json.system_mode }}'
2022-10-24 10:43:32.575 ERROR (MainThread) [homeassistant.components.mqtt.climate] Invalid modes mode:
Additional information
No response
This seems an issue with Zigbee2MQTT. To see what happens the published MQTT configuration is needed, @Koenkk Can you have a look?
Hey there @emontnemery, mind taking a look at this issue as it has been labeled with an integration (mqtt
) you are listed as a code owner for? Thanks!
Code owner commands
Code owners of mqtt
can trigger bot actions by commenting:
-
@home-assistant close
Closes the issue. -
@home-assistant rename Awesome new title
Change the title of the issue. -
@home-assistant unassign mqtt
Removes the current integration label and assignees on the issue, add the integration domain after the command.
(message by CodeOwnersMention)
mqtt documentation mqtt source (message by IssueLinks)
I seem to have this as well, but I'm not sure it's Zigbee2MQTT. The state is changing in the MQTT broker. It only seems to not get from MQTT into HA. Although, it does seem that in some cases Zigbee2MQTT appears to send a null state and this works. A message of "toggle" followed by "" results in HA staying with "toggle". This is with an Ikea tradfri remote. mqttlog.txt
@ascheucher can you provide the debug log when setting this in HA until it is published to MQTT, I see you added this to the OP but I'm not sure if you left out some parts.
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
@Koenkk damn, sorry. Somehow I missed the updates!
This still doesn't seem to work for me. I just created a a bunch of automations (one for each TRV) to pull an update 15 seconds after I have changed the temp in the HA Dashboard. It also runs every minute to pull the setpoint from the TRV, as changes on the TRV had not been taken over.
If somebody wants to take a look, I can create a log of course.
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.