Homematic states not updating if controlled outside of HA

I have homematic running on a raspberrymatic pi3.
All my devices (mostly hmip-broll) are detected fine and can be controlled from inside HA.
However if I manually raise or lower a shutter using the hmip-broll button mounted on the wall, HA doesn’t get sent a changed state.
So lowering the shutters at night via HA and then raising them in the morning by button press lets HA think that the shutters are closed all day. Also it then won’t let me lower the shutters, as it thinks they are lowered already.
The only thing that works is setting a height manually in HA with the slider, after that HA once again knows.
Long story short, is there anything I specifically need to setup to have hmip report the states to HA?
Tagging @danielperna84 as he seems to know his way around hmip :wink:

EDIT:
Did some testing. I can raise the shutter from HA however it still has the state as closed. So scratch the part about reading the values.
It aparently doesnt read ANY values :frowning:

Nevermind. Just did the last incremental HA update and it seems to have solved the issue. Looks like the breaking changes in HA 108 broke a bit more than expected :wink:

My guess: all you needed to do was a restart of Home Assistant. An important issue with the HomeMatic integration is, that once the connection between Home Assistant and the CCU get interrupted, events won’t be transmitted from the CCU to Home Assistant. That’s why the reconnect-service exists. However, the server-component for HmIP is buggy. As a result the reconnect service only works for the old wired and wireless devices. So for now the only solution is to restart Home Assistant when the connection has dropped. You should have a look at this of the documentation. You could use this to get notified that a restart is required. :+1:

1 Like

Thanks! That was of course what was happening. The CCU had errors with the network and I kept losing the connection.
HOWEVER trying to call homematic.reconnect from ha services does nothing… does it take a while for homeassistant to sync again? nothing shows up in any logs as far as I can see.
Restarting ha gets the sync back straight away.

For HmIP it doesn’t work at all. The Server-Code on the CCU from eq3 is broken and doesn’t allow reconnections. So restarting is the only choice. There’s a thread around here somewhere regarding the problem. Sadly so far there’s no other solution besides restarting Home Assistant.

1 Like

oh wow. that explains.
Even with raspberrymatic this is broken and not fixable?

Yup. It’s a binary that comes straight from eq3. RaspberryMatic doesn’t modify this. The source code isn’t available as well. So Nobody but eq3 can fix this issue. And for them it isn’t really an issue because within the CCU it’s not a problem. And for tools like ioBroker it’s no problem because the HomeMatic component can be restarted without restarting ioBroker. But as long as Home Assistant doesn’t have a modern integration, a restart is required to reset HomeMatic.

thanks for all the insight!
I hope someone with the skill comes along and writes a new homematic integration, but I guess it’s pretty much focused on the german market as far as I can tell so not much international interest in the integration…
What does the homematic.reconnect then even do? What does it work with if the code is broken? Shouldn’t the readme be updated if it isn’t working?

It’s already been worked on by one of the core developers (who also helped be building the integration we already have back then). But since he’s a core-dev, his time to spend on the integration is limited. And since in general the existing integration is pretty stable, it doesn’t have the highest priority.

It works perfectly fine for the old wired and wireless devices. It’s just for HomeMaticIP where it doesn’t work. On the CCU this is a different daemon-process that handles the communication. And that IP-specific program seems to have a bug that is causing our issues.

1 Like

Hi @danielperna84 can we somewhere track the status of the rewrite?

Nothing that I’m aware of.