Zehnder ComfoConnect component

Great that this Zehnder ComfoAirQ350 is available in HA! Just a small problem: I have 2 of these devices on my network. How do I proceed?

hi,

have you find a way to use more value sensor ?
I search especially the “exhaust_temp” and the bypass_status

regards

Anyone else getting bunch of errors/warnings from comfoconnect component every time HA starts?
I get this in home-assistant.log every time…
Ideas?

Jaka

2019-04-30 16:17:37 ERROR (MainThread) [homeassistant.setup] Setup failed for customize: Integration not found.
2019-04-30 16:17:44 ERROR (Thread-15) [homeassistant.components.comfoconnect.sensor] Exception in _handle_update when dispatching 'comfoconnect_update_received': (120,)
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/comfoconnect/sensor.py", line 105, in _handle_update
self.schedule_update_ha_state()
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity.py", line 336, in schedule_update_ha_state
self.hass.add_job(self.async_update_ha_state(force_refresh))
AttributeError: 'NoneType' object has no attribute 'add_job'

2019-04-30 16:17:44 ERROR (Thread-17) [homeassistant.components.comfoconnect.sensor] Exception in _handle_update when dispatching 'comfoconnect_update_received': (119,)
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/comfoconnect/sensor.py", line 105, in _handle_update
self.schedule_update_ha_state()
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity.py", line 336, in schedule_update_ha_state
self.hass.add_job(self.async_update_ha_state(force_refresh))
AttributeError: 'NoneType' object has no attribute 'add_job'

2019-04-30 16:17:44 ERROR (Thread-5) [homeassistant.components.comfoconnect.sensor] Exception in _handle_update when dispatching 'comfoconnect_update_received': (292,)
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/comfoconnect/sensor.py", line 105, in _handle_update
self.schedule_update_ha_state()
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity.py", line 336, in schedule_update_ha_state
self.hass.add_job(self.async_update_ha_state(force_refresh))
AttributeError: 'NoneType' object has no attribute 'add_job'

2019-04-30 16:17:44 ERROR (Thread-11) [homeassistant.components.comfoconnect.sensor] Exception in _handle_update when dispatching 'comfoconnect_update_received': (290,)
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/comfoconnect/sensor.py", line 105, in _handle_update
self.schedule_update_ha_state()
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity.py", line 336, in schedule_update_ha_state
self.hass.add_job(self.async_update_ha_state(force_refresh))
AttributeError: 'NoneType' object has no attribute 'add_job'

2019-04-30 16:17:44 ERROR (Thread-13) [homeassistant.components.comfoconnect.sensor] Exception in _handle_update when dispatching 'comfoconnect_update_received': (274,)
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/comfoconnect/sensor.py", line 105, in _handle_update
self.schedule_update_ha_state()
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity.py", line 336, in schedule_update_ha_state
self.hass.add_job(self.async_update_ha_state(force_refresh))
AttributeError: 'NoneType' object has no attribute 'add_job'

2019-04-30 16:17:44 ERROR (Thread-20) [homeassistant.components.comfoconnect.sensor] Exception in _handle_update when dispatching 'comfoconnect_update_received': (276,)
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/comfoconnect/sensor.py", line 105, in _handle_update
self.schedule_update_ha_state()
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity.py", line 336, in schedule_update_ha_state
self.hass.add_job(self.async_update_ha_state(force_refresh))
AttributeError: 'NoneType' object has no attribute 'add_job'

2019-04-30 16:17:44 ERROR (Thread-18) [homeassistant.components.comfoconnect.fan] Exception in _handle_update when dispatching 'comfoconnect_update_received': (65,)
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/comfoconnect/fan.py", line 44, in _handle_update
self.schedule_update_ha_state()
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity.py", line 336, in schedule_update_ha_state
self.hass.add_job(self.async_update_ha_state(force_refresh))
AttributeError: 'NoneType' object has no attribute 'add_job'

Yes I do see the same errors.

How do I add additional sensors for temperature e.g. supply air?

Jan

Updated to newest everything… and now I am getting new errors :slight_smile:
Thing seeks to work, just these appear in the log at startup…

Any ideas about how to make them gone are welcome.

2020-03-08 20:56:04 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 425, in _async_add_entity
    raise HomeAssistantError(msg)
homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.comfoairq_outside_temperature. Platform comfoconnect does not generate unique IDs
2020-03-08 20:56:04 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 425, in _async_add_entity
    raise HomeAssistantError(msg)
homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.comfoairq_supply_airflow. Platform comfoconnect does not generate unique IDs
2020-03-08 20:56:04 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 425, in _async_add_entity
    raise HomeAssistantError(msg)
homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.comfoairq_outside_humidity. Platform comfoconnect does not generate unique IDs
2020-03-08 20:56:04 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 425, in _async_add_entity
    raise HomeAssistantError(msg)
homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.comfoairq_inside_temperature. Platform comfoconnect does not generate unique IDs
2020-03-08 20:56:04 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 425, in _async_add_entity
    raise HomeAssistantError(msg)
homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.comfoairq_inside_humidity. Platform comfoconnect does not generate unique IDs
2020-03-08 20:56:04 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 425, in _async_add_entity
    raise HomeAssistantError(msg)
homeassistant.exceptions.HomeAssistantError: Entity id already exists: sensor.comfoairq_exhaust_airflow. Platform comfoconnect does not generate unique IDs

I’ve made a request to add new commands and sensor to the HA zehnder component as there are avalaible in the pycomfoconnect library
Here is the link : Add all other sensors in comfoconnect

Hello everyone,

I am pretty new to Home Assistant. I got some of the integrations done, but I can’t find more detailed instructions how to inegrate Zehnder Ventilation system including Comfofond and Comfoconnect to HA.

I would appreciate an example or a step by step instruction what to install, which files to edit, etc. Information in Integration section of HA for Zehnder is pretty „thin”. Googling did not really help.

Thanks!

Dominik

Hi Dominick,
The component has been recently updated, to me you can just stick to the explanation on how to add the Zehnder component to your HA config, and forget about the files edit and so on.

There are still some features missing (for instance, being able to toggle the temperature profile from the HA interface), but unfortunately I’m not yet into dev enough to manipulate Python :smile:

EDIT: I just saw that new sensors addition have been requested to the intergation code owner, I think this will cover the remaining functions that are not integrated yet, let’s wait on that :slight_smile:
Thanks to @michaelarnauts and all contributors out there :slight_smile:

Hi,

Thanks for the hint - this is where I started and that did not work, so I thought there’s some “magic” which is not mentioned in the HA integration description.
Doing everything as mention in the description of the integration I get the HA notification:

"The following integrations and platforms could not be set up:

  • comfoconnect
  • comfoconnect.sensor

Please check your config."

and bunch of error messages in the home assistant log:

'2020-06-14 13:25:48 ERROR (MainThread) [homeassistant.setup] Error during setup of component comfoconnect
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 273, in _connect
self.cmd_start_session(takeover, use_queue=False)
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 377, in cmd_start_session
use_queue=use_queue
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 157, in _command
reply = self._get_reply(confirm_type, use_queue=use_queue)
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 199, in _get_reply
raise PyComfoConnectNotAllowed()
pycomfoconnect.error.PyComfoConnectNotAllowed

During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 77, in connect self._connect(takeover=takeover)
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 279, in _connect
self.cmd_register_app(self._local_uuid, self._local_devicename, self._pin, use_queue=False)

File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 411, in cmd_register_app
use_queue=use_queue
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 157, in _command
reply = self._get_reply(confirm_type, use_queue=use_queue)

File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 199, in _get_reply
raise PyComfoConnectNotAllowed()
pycomfoconnect.error.PyComfoConnectNotAllowed

During handling of the above exception, another exception occurred:
Traceback (most recent call last):

File “/usr/src/homeassistant/homeassistant/setup.py”, line 190, in _async_setup_component
result = await asyncio.wait_for(task, SLOW_SETUP_MAX_WAIT)
File “/usr/local/lib/python3.7/asyncio/tasks.py”, line 442, in wait_for
return fut.result()
File “/usr/local/lib/python3.7/concurrent/futures/thread.py”, line 57, in run
result = self.fn(*self.args, **self.kwargs)
File “/usr/src/homeassistant/homeassistant/components/comfoconnect/init.py”, line 74, in setup ccb.connect()
File “/usr/src/homeassistant/homeassistant/components/comfoconnect/init.py”, line 109, in connect
self.comfoconnect.connect(True)
File “/usr/local/lib/python3.7/site-packages/pycomfoconnect/comfoconnect.py”, line 80, in connect
raise Exception(‘Could not connect to the bridge since the PIN seems to be invalid.’)
Exception: Could not connect to the bridge since the PIN seems to be invalid.

2020-06-14 13:25:48 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform comfoconnect.sensor: Unable to set up component.
2020-06-14 13:26:04 WARNING (MainThread) [aiohttp.websocket] websocket connection is closing.’

I added only lines which are mentioned to be required to the configuration.yaml, which are:

comfoconnect:
-host: IP_of_the_ventilation_comfoconnect

and then the whole sensors section.

Is there anything which needs to be done to make it work? is pycomfoconnect installation the only other thing? How HA knows that it should run it? Is an additional Python daemon needed?

It’s bit lenghtly, but I hope with some guidance from people who made it run I will get there as well and then also the HA integration section could be updated accordingly.

Anyway thanks for all the help and efforts to create this integration. When I finally get it to run I was thinking about linking arming alarm system with turning the ventiation system off (saving of energy and filters).

Thanks!

You are probably using a wrong PIN, the default HA is using is 0000. That’s what the pycomfoconnect.error.PyComfoConnectNotAllowed indicated IIRC.

I agree the error could be less cryptic :slight_smile:

Thanks for the hint… I appreciate your time. I tried the PIN of my ventilation system (I assume this is the one to access the installator settings and functions in the app?) and I still get the same notification in HA and same set of errors.

Hi Dominick,
This is how it looks in my configuration.yaml.

# Zehnder configuration
comfoconnect:
  host: 192.168.0.16
  pin: !secret zehnder_pin

This is how it looks in my sensors.yaml

# Zehnder sensors
sensor:
  - platform: comfoconnect
    resources:
      - current_temperature
      - current_humidity
      - outside_temperature
      - outside_humidity
      - air_flow_supply
      - air_flow_exhaust
      - supply_temperature
      - supply_humidity
      - exhaust_temperature
      - exhaust_humidity
      - days_to_replace_filter
      - bypass_state
      - exhaust_fan_duty
      - exhaust_fan_speed
      - power_usage
      - supply_fan_duty
      - supply_fan_speed


Me again . . . this is exactly my config, but still it won’t run.

What I noticed while upgrading pycomfoconnect to the newer version 20.1.1 is that it installs in the different folder than HA is trying to run it from.

All the HA errors are referring to: /usr/local/lib/python3.7/site-packages/

while installation actually lands into: /usr/lib/python3.8/site-packages/

I do not know if it matters or not. Where from HA knows where pycomfoconnect is installed - is this in any of the config files?

I think I am going to give up on that - I am not smart enough to make it run.

Thanks all for help.

@Dominick
I also struggled to get it connected but a factory reset of the ComfoConnect LAN C to get the pin to 0000 did the trick for me.

Press the Factory reset button (4) with a paperclip for a few seconds until the Power LED (5) starts flashing. It’s apparently a tiny button so make sure you point the paperclip straight in the hole and wait for the flashing leds to make sure the factory reset has happened.

I’m using the HassOS 4.10 with HA 0.111.4 on a Raspberry Pi 4 with 4 Gb.

Hope you get it working this way because it is a very nice integration. Thanks @michaelarnauts :slight_smile:

Hi all,

thanks for all the cool stuff here!

I managed to integrate my Zehnder Comfort Control and have access to all the sensor managed here.

However, as a newbie I am wondering how I can control/steer the fan speed, or more precisely the level (1, 2, 3) of the fan.
Unfortunately, I have no clue how to add these commands to home-assistant…

thank you
Sebastian

Manuel,

Thanks for the hint. It finally worked. Looks like PIN was changed and when I did a factory reset HA was able to connect to the Comfoconnect LAN.

I saw some extra sensors were added to the integration recently (like Comfofond ground heat exchanger, etc). Where do I find the list of those, so I can add them to HA?

Thanks for help and really nicely working integration!

HI, sorry to bump this, but having searched the community and Github repo, I really cant find the setup instructions for this CC in HA. Could anyone here please point me to that?
reason I ask is a Zehnder unit will be installed the coming months, and Id like to prepare :wink:

Am I right in supposing we can control the unit without external internet connection? Ive disgarded several other brands because they need their own Cloud server for connection, which is a no-go for me.

A simple Lan connection should suffice.

thanks for any hints on this matter.

You are right. It works locally, but it can also work remote (through their servers). You’ll need to buy an Comfoconnect LAN C also as a bridge between the CAN bus and your network.

thanks for confirming!
if it works locally, and I can reach my HA instance remotely, shouldn’t that suffice? I mean, my local HA instance can control the locally connected Zehnder unit in that case?

I understand for some Zehnder app I would need their server.

btw do they also have some hard ware device (compare a physical thermostat) to be able to push a button? so when all network is down, I can still control the unit. (asking here since the local supplier is not really into IOT…)

Mine came with a RF remote control that can be attached to the wall, I guess that’s standard delivered with the unit.

And you are also right a out the local/remote setup. If Hass can reach the Comfoconnect locally, you can control it trough your Hass remotely also.

1 Like