Homeassistant Homematic IP devices not updating in UI

Hi,

I’m using homeassistant with homematic for a while without any problems. Untin now I only had “old” homematic thermostats but as of yesterday I added new homematic ip thermostats.
Initially everything seemd finde and I got the same functionality from them as from my only devices but after some time and changes to the temperature I noticed that they would not update the displayed set temperature etc.
Looking into homematic everything looks fine and works as expected but in homeassistant it is not updating the ip devices.
I looked into this issue and there seems to be an old issue that the update is not working anymore once the connection between is dropped. This should be fixed in the newer versions of homematic and i tried all described workarouds to at least get it initialy to sync up again but no luck.
I can change some setting of the IP devices in homeassistant be the status in the homeassistant interfaces are still not updated.

Here is some information about my setup:

Homeassistant (in a docker container):

version: core-2021.11.5
installation_type: Home Assistant Container
dev: false
hassio: false
docker: true
user: root
virtualenv: false
python_version: 3.9.7
os_name: Linux
os_version: 5.4.0-84-generic
arch: x86_64
timezone: Europe/Berlin
dashboards: 1
resources: 5
views: 7
mode: yaml

Homematic (on a rpi3):

Version: 3.61.5.20211113

Homematic intigration

homematic:
  local_port: 8124
  interfaces:
    rf:
      host: 192.168.1.100
      callback_ip: 192.168.1.5
      callback_port: 8124
      username: !secret homematic_username
      password: !secret homematic_password
    ip:
      host: 192.168.1.100
      port: 2010
      username: !secret homematic_username
      password: !secret homematic_password
    groups:
      host: 192.168.1.100
      port : 9292
      callback_ip: 192.168.1.5
      callback_port: 8124
      username: !secret homematic_username
      password: !secret homematic_password
      path: /groups
  hosts:
    ccu3:
      host: 192.168.1.100
      port: 2001
      username: !secret homematic_username
      password: !secret homematic_password

I’ve enabled homematic logging via:

logger:
  #default: warning
  logs:
    homeassistant.components.homematic: debug
    pyhap: debug

Here is the logfile:

I hope someone can point me in the right direction!
Thanks,
FMK

Just to make this clear: if the connection has dropped, it ALWAYS has to be reconnected (manually or via automation). This is never happening automatically with the current integration.

In general if you are able to control devices but they don’t update their state in Home Assistant, then this (missing) connection usually is the reason for the problem. It seems odd though, that you only appear to have that problem with IP devices. If the connection was dropped and you are on a recent version (both CCU and Home Assistant), the reconnect should fix this both for old and new devices.

In any case, does restarting Home Assistant solve the problem?

Regarding your posted log: that’s way to noisy and filled with a lot of unrelated log messages. It would take days to read through it. You should set the global log level to something like warning to reduce the amount of logged messages, and only increase to debug for pyhomematic and the homematic integration.

Hi,

if i restart homeassistant I get the current values for all devices but after that the ip devices are not updated. I’m able to change the non ip devices all the time, I’m just not getting the updated values from the ccu in homeassistant for the ip devices.

If I change the settings in homeassistant for the ip devices the value get updated in the ccu in on the thermostat itself but homeassistant does not get a notification that the change was sucessful and get in a broken state where the temp setting is still in red (for not confirmed) and if more time passes it set the value in homeassistant to 0 regardless of what the actual value in the ccu is.

I’ve update the log level for homeassistant and cleared the log and restarted homeassistant.
After the restart the current values from the homematic are fetched but only once on the initial connection.
After that I’ve changed the values for the ip devices multiple time but the state is not updated.

Spoiler: from a first look the log does not contain anything interesting regarding this problem:

2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.climate: Handling NEQ1008259: None: [1]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.climate: Handling PEQ1189073: None: [1]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.climate: Handling PEQ1315107: None: [1]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.climate: Handling PEQ1629691: None: [1]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.climate: Handling QEQ1461938: None: [1]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.battery: Handling NEQ1008259: LOWBAT: [0]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.battery: Handling PEQ1189073: LOWBAT: [0]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.battery: Handling PEQ1315107: LOWBAT: [0]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.battery: Handling PEQ1629691: LOWBAT: [0]
2021-12-11 13:07:27 DEBUG (Thread-3) [homeassistant.components.homematic] homematic.battery: Handling QEQ1461938: LOWBAT: [0]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.climate: Handling 00201D89A8CCB9: None: [1]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.climate: Handling 00201D89A8CCBD: None: [1]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.climate: Handling 00201D89A8CC54: None: [1]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.climate: Handling 00201D89A8CCB2: None: [1]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.battery: Handling 00201D89A8CCB9: LOW_BAT: [0]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.battery: Handling 00201D89A8CCBD: LOW_BAT: [0]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.battery: Handling 00201D89A8CC54: LOW_BAT: [0]
2021-12-11 13:07:27 DEBUG (SyncWorker_4) [homeassistant.components.homematic] homematic.battery: Handling 00201D89A8CCB2: LOW_BAT: [0]
2021-12-11 13:07:27 WARNING (MainThread) [homeassistant.components.octoprint] The 'octoprint' option near /config/configuration.yaml:0 is deprecated, please remove it from your configuration
2021-12-11 13:07:31 WARNING (MainThread) [aioesphomeapi.reconnect_logic] Can't connect to ESPHome API for 192.168.1.157 @ 192.168.1.157: Error connecting to ('192.168.1.157', 6053): [Errno 113] Connect call failed ('192.168.1.157', 6053)
2021-12-11 13:07:37 WARNING (MainThread) [homeassistant.setup] Setup of homematic is taking over 10 seconds.
homeassistant/home-assistant.log (END)

The four devices that are logged in the lines with (SyncWorker_4) are the four ip devices I added yesterday. The other devices are the non ip devices!

If I can provide you with any other information just tell me!

Thanks,
FMK

Having another look at your configuration I see, that you didn’t set the callback_ip and callback_port in the section for HmIP. If that’s needed for the other protocols, then it’s also needed for HmIP. In case you have fixed that already: did you ever restart your CCU? The Server for HmIP is a different one and can crash. Hence a restart of your CCU might help as well.

Hi,

it seems likt the missing callback_ip and callback_port where the reason that it didn’t update.

Thanks for pointing this out!
FMK

Hi,
i use HomeMatic CCU AddOn Current version: 11.3.0

I have also lose connection, but i can’t find description from ‘callback_ip’ and ‘collback_port’ at doc? What are they doing exactly?

How do I get the connection to the CCU re-established automatically? Sorry, but I’m only on the road with HA for a short time. And this forum is a bit strange to use, probably I’m too old. Somehow I don’t see the tree structure of the individual subcategories

Hi there,
I have a similar issue, but not sure if it’s really the same.
Up to now I had only wireless devices connected to HomeMatic and they all were perfectly working with HA. A few days ago I added a new IP window sensor, which is working fine in HomeMatic and it shows as well in HA.
I have as well a second HA running (as I’m migrating to a new hardware). All wireless devices are updating there as well, just the IP window sensor is only updating in one HA instance.
With the homematic.reconnect service I can reconnect the HA which is not updating, but then the other one will stop updating the IP devices.
Any idea what that can be? Or would it be better to post this also on the HomeMatic forum?
Thanks, N

@linuxdep

The callback_ip and callback_port are manual overrides in case the automatic mode does not work. It defines the IP+Port combination to which the CCU will establish the reverse connection where the states are pushed to.

The HomeMatic documentation for Home Assistant has a section which covers automations to use to automatically reconnect.

@NoWebH

The integration can’t be used on two Home Assistant machines in the same network that well. Think of it like Home Assistant telling your CCU “I’m Home Assistant with RF, talk to me”. If you add another instance, it will tell the CCU the same thing, which causes the CCU to then send the updates to the other machine.

You can however improve this by not using exactly the same configuration. In the interfaces where users typically set keys like rf, ip or wired, you can specify a different key. I’m not entirely sure, but I believe in this case the CCU would be able to tell the different Home Assistant instances apart.

Thanks @danielperna84, this solved the issue and now both HA machines get data from both interfaces (rf and IP). As suggested, I just named the interfaces differently in both HA machines.

Hello, there seem to be problems with HA and CCU/Raspberrymatic.
It looks like HA is sending too many requests to the CCU, which means that the CCU can no longer be reached via the webui and the backups on the CCU are also blocked.

1 Like

Please switch to the new custom integration if you’re having problems with the internal one: https://github.com/danielperna84/custom_homematic

The internal integration is not being worked on anymore.

Hi,
I can’t add that integration unfortunately after adding the repo. Anyone else experiencing this?

The same behaviour with Homematic Ip Cloud Service. Seems this has to do with so changes in 2022.7!
I was updating yesterday and got the well know info from HM-Cloud: “APi Calles blocked → to many calls”. After going back to 2022.6.5 ecverything is fine again!

Take a look at facebook or there are already posts but it doesn’t necessarily have anything to do with HA but with Homematic IP in general