Modbus Sensor TCP for Komfovent

That would be really interesting thing to do. Did you have any success? Otherwise you can build all the smart control by humidity/co2 logic to HA as well.

I have solved it by introducing a pwm converter connected to esp32. Esp32 reads data from Netatmo inhouse air quality monitor towers. Values are then converted to voltage by help of mentioned pwm converter and feeds that value into dedicated input on C6 board for CO2. Theres a defined range from 0 to 10V that you can feed into C6 controllers CO2 . Asked also if CO2 values can be sent via modbus. Komfovent technicians said it is not possible

Could you post a bit more detail, please? Could you do the the same for a particulate sensor?

It has 2 connections B8 and B9. Both B8 and B9 are described to be Air quality / Humidity sensors. You can only tell your komfovent what type of sensor is connected inside your settings and then pass it a value of 0-10V. I will show my solution later.

1 Like

How did you calibrate the voltage?

Iā€™ve gotten an updated C6 Modbus document, if it helps anyone. It has a few new entries, like ā€œConstant heat recoveryā€.

3 Likes

I get a lot of modbus errors. Running latest HA.

Logger: homeassistant.components.modbus.base_platform
Source: components/modbus/base_platform.py:178
Integration: Modbus (documentation, issues)
First occurred: 9:49:14 PM (365 occurrences)
Last logged: 10:01:13 PM

Received 4 bytes, unpack error unpack requires a buffer of 2 bytes

Does anybody have the same?

1 Like

I have the same. Any ideas?

Here is a configuration that works. Some data_types were not defined before.

modbus:
  - name: Komfovent
    type: tcp
    host: 192.168.1.247
    port: 502
    switches:
      - name: "Komfovent Auto Mode"
        slave: 1
        address: 3
        command_on: 1
        command_off: 0
      - name: "Komfovent Power"
        slave: 1
        address: 0
        command_on: 1
        command_off: 0
      - name: "Komfovent Eco Mode"
        slave: 1
        address: 2
        command_on: 1
        command_off: 0
    sensors:
      - name: "Komfovent Power"
        address: 0
        scan_interval: 10
      - name: "Komfovent Eco"
        address: 2
        scan_interval: 10
      - name: "Komfovent Mode"
        address: 4
        scan_interval: 10
      - name: "Komfovent Auto"
        address: 3
        scan_interval: 10
      - name: "Komfovent Shedule"
        address: 5
        scan_interval: 10
      - name: "Komfovent Status bit mask"
        address: 899
        scan_interval: 10
      - name: "Komfovent Supply temperature 'C"
        address: 901
        scan_interval: 10
        unit_of_measurement: Ā°C
        scale: 0.1
        precision: 1
        device_class: temperature
      - name: "Komfovent Extract temperature 'C"
        address: 902
        scan_interval: 10
        unit_of_measurement: Ā°C
        scale: 0.1
        precision: 1
        device_class: temperature
      - name: "Komfovent Supply Fan Intensivity '%"
        address: 909
        scan_interval: 10
        unit_of_measurement: '%'
        scale: 0.1
        precision: 1
      - name: "Komfovent Extract Fan Intensivity '%"
        address: 910
        scan_interval: 10
        unit_of_measurement: '%'
        scale: 0.1
        precision: 1
      - name: "Komfovent Outdoor temperature 'C"
        address: 903
        scan_interval: 10
        unit_of_measurement: Ā°C
        scale: 0.1
        precision: 1
        device_class: temperature
      - name: "Komfovent Filter Impurity, %"
        address: 916
        scan_interval: 10
        unit_of_measurement: '%'
      - name: "Komfovent Heat exchanger, %"
        address: 911
        scan_interval: 30
        unit_of_measurement: '%'
        scale: 0.1
        precision: 0
      - name: "Komfovent Heating power, W"
        address: 912
        scan_interval: 10
        unit_of_measurement: W
        device_class: power
      - name: "Komfovent Power consumption, W"
        address: 920
        scan_interval: 10
        unit_of_measurement: W
        device_class: power
      - name: "Komfovent Power consumption Month, kWh"
        address: 928
        scan_interval: 10
        unit_of_measurement: kWh
        data_type: 'int32'
        count: 2
        precision: 0
        scale: 0.001
        state_class: total_increasing
        device_class: energy
      - name: "Komfovent Power consumption Total, kWh"
        address: 930
        scan_interval: 300
        unit_of_measurement: kWh
        data_type: 'int32'
        count: 2
        precision: 0
        scale: 0.001
        state_class: total_increasing
        device_class: energy        
      - name: "Komfovent Heating Recovery Month, kWh"
        address: 940
        scan_interval: 10
        unit_of_measurement: kWh
        data_type: 'int32'
        count: 2
        precision: 0
        scale: 0.001
        device_class: energy
      - name: "Komfovent Heating Recovery Total, kWh"
        address: 942
        scan_interval: 10
        unit_of_measurement: kWh
        data_type: 'int32'
        count: 2
        precision: 0
        scale: 0.001
        state_class: total_increasing
        device_class: energy
      - name: "Komfovent Heat Recovery, W"
        address: 922
        scan_interval: 10
        unit_of_measurement: W
      - name: "Komfovent Heat exchanger efficiency, %"
        address: 923
        scan_interval: 10
        scale: 1
        precision: 0
        unit_of_measurement: '%'
      - name: "Komfovent Energy saving, %"
        address: 924
        scan_interval: 10
      - name: "Komfovent Specific power (SPI)"
        address: 925
        scan_interval: 10
        scale: 0.001
        precision: 2

it works! thanks!

Iā€™ve defined significantly more sensors in my config ha_komfovent_config/komfovent.yaml at b07cb34cdd3265460e9d3d5433c904a919fb91a6 Ā· borpin/ha_komfovent_config Ā· GitHub and they have data_type defined. I also define the device_class, measurement_class and state_class if appropriate.

I do get SlaveBusy errors about once or twice an hour, but that is the nature of Modbus and I am polling it quite hard.

Iā€™ve got an error in one of the automation ATM but you donā€™t have to use those (I use them for increasing and decreasing the fan speed).

1 Like

Impressive work you have fone! Can you please share the locelace card as well?

Nice! One question, which sesnor should I use to Energy dashboard?
Screenshot 2022-11-30 at 15.30.23
Screenshot 2022-11-30 at 15.30.29

I have just published all my cards (they do various things) and some images in the readme of those cards. GitHub - borpin/ha_komfovent_config: Set of files for configuring MODBUS connection to a Komfovent Unit. There was a brief UI YAML file there already.

It depends what you want to show :grin: Iā€™d suggest the ahu_consumption_total as this is the total consumption. It should be configured correctly to work with the Energy dashboard.

I donā€™t think these come from my config.

Note

I have just pushed a major revision of the YAML to what I am currently using. The GitHub version had got rather out of date.

1 Like

Thanks! Looks like yout komfovent.yaml has everything double. Maybe some copy-paste error?

Also where to use cards yaml?

Yes, made a right mess of that.

It just needs to be added to the lovelace dashboard config. It isnā€™t an add-on card, just the config Iā€™m using.

Hi! Iā€™m very new in HA stuff. Thanks for your work in integration of komfovent unit. Please, if you can, make a tutorial how to implement this files, for newbies.

Here is a great tutorial: GitHub - borpin/ha_komfovent_config: Set of files for configuring MODBUS connection to a Komfovent Unit

2 Likes

Hello,

I noticed that in log always appearing this error:

ā€˜Pymodbus: komfovent: Exception Response(131, 3, SlaveBusy)ā€™

Maybe somebody know whats the problem?