marq24 / ha-waterkotte-the-fork

HACS integration for Waterkotte Heatpumps [build since 2018] - # This version is deprecated - and no further updates will be provided! Please migrate to the new version of the Integration that have been published - TIA - see the 'Migration Guide' for details
MIT License
7 stars 1 forks source link

Feature Request: Integration of entities for ventilation system #13

Closed Frank-H-H closed 7 months ago

Frank-H-H commented 9 months ago

First: Thanks for this great integration. It really helps in running the heat pump preferrably, when we have excess PV power.

One request though: If you have BasicVent / EcoVent system, you can integrate this ventilation system into your heat pump. The the GUI shows values for that as well: grafik It would be really nice to have some of these sensor values - and specifically the option to change the running mode - too.

marq24 commented 9 months ago

Hi,

just check/provide the corresponding TAG names for the different values/fields - please see https://github.com/marq24/ha-waterkotte/issues/12 for details.

Something additional that could help, if you would let me know, the URL of the page displaying this... I just found the '[IP-HERE]/easycon/pgvent.html'

marq24 commented 8 months ago

Good Morning @Frank-H-H - would you still be interested? I am not 100% sure if you picked up, that I have actually asked for additional information from you... If you need more guidance (what to do) please let me know - Identify the TAG names (which can be captured in most of the cased directly from the web frontend) is the key to be able to provide additional Sensors in the HA Integration.

verdao1914 commented 8 months ago

I've done some experiments with the additional configuration stored in the files included here below (i'm sorry i haven't learned how to do this professionally on github yet. surely one day i will, but to speed up the implementation, here goes).

The point is that the variables generated by the heatpump software itself have the same format (int*10). The ventilation system variables read via the heat pump come in a different format, i.e. pure float. They cannot be divided by 10 and would need to be treated differently.

ecotouch.py: BV_OPERATING_MODE = TagData(["I4582"], "" , writeable=True) BV_BYPASS_ACTIV = TagData(["D1432"], "") BV_OPERATING_HOURS_FILTER = TagData(["A4498"], "h") BV_DAYS_TO_CHANGE_FILTER = TagData(["A4504"], "") BV_RPM_ONGOING_AIR_DRIVE = TagData(["A4547"], "rpm") BV_RPM_INCOMMING_AIR_DRIVE = TagData(["A4551"], "rpm") BV_DRIVE_ONGOING_AIR = TagData(["A4984"], "%") BV_DRIVE_INCOMMING_AIR = TagData(["A4986"], "%") BV_T_ONGOING_AIR = TagData(["A4994"], "°C") BV_T_INCOMMING_AIR = TagData(["A4996"], "°C") BV_T_EXAUSTING_AIR = TagData(["A4998"], "°C") BV_T_EXTERNAL_AIR = TagData(["A5000"], "°C") TEMPERATURE_WATER_OFFSETDAYTIME = TagData(["A157"], "K")

sensor.py "BV_OPERATING_HOURS_FILTER": [ "Operating hours filter", EcotouchTag.BV_OPERATING_HOURS_FILTER, SensorDeviceClass.DURATION, None, "mdi:counter", True, None, None, ], "BV_DAYS_TO_CHANGE_FILTER": [ "Days to change filter", EcotouchTag.BV_DAYS_TO_CHANGE_FILTER, SensorDeviceClass.DURATION, None, "mdi:counter", True, None, None, ], "BV_RPM_ONGOING_AIR_DRIVE": [ "Rotation Ongoing air drive", EcotouchTag.BV_RPM_ONGOING_AIR_DRIVE, None, None, "mdi:counter", True, None, None, ], "BV_RPM_INCOMMING_AIR_DRIVE": [ "Rotation Incomming air drive", EcotouchTag.BV_RPM_INCOMMING_AIR_DRIVE, None, None, "mdi:counter", True, None, None, ], "BV_DRIVE_ONGOING_AIR": [ "Rotation Ongoing air drive percent", EcotouchTag.BV_DRIVE_ONGOING_AIR, None, PERCENTAGE, "mdi:gauge", True, None, None, ], "BV_DRIVE_INCOMMING_AIR": [ "Rotation Incomming air drive percent", EcotouchTag.BV_DRIVE_INCOMMING_AIR, None, PERCENTAGE, "mdi:gauge", True, None, None, ], "BV_T_ONGOING_AIR": [ "Temperature Ongoing air", EcotouchTag.BV_T_ONGOING_AIR, SensorDeviceClass.TEMPERATURE, UnitOfTemperature.CELSIUS, "mdi:thermometer", True, None, None, ], "BV_T_INCOMMING_AIR": [ "Temperature Incomming air", EcotouchTag.BV_T_INCOMMING_AIR, SensorDeviceClass.TEMPERATURE, UnitOfTemperature.CELSIUS, "mdi:thermometer", True, None, None, ], "BV_T_EXAUSTING_AIR": [ "Temperature exausting air", EcotouchTag.BV_T_EXAUSTING_AIR, SensorDeviceClass.TEMPERATURE, UnitOfTemperature.CELSIUS, "mdi:thermometer", True, None, None, ], "BV_T_EXTERNAL_AIR": [ "Temperature external air", EcotouchTag.BV_T_EXTERNAL_AIR, SensorDeviceClass.TEMPERATURE, UnitOfTemperature.CELSIUS, "mdi:thermometer", True, None, None, ], "BV_BYPASS_ACTIV": [ "Temperature external air", EcotouchTag.BV_BYPASS_ACTIV, True, None, "mdi:switch", False, None, None, ], "DATE_DAY": [ "Date day", EcotouchTag.DATE_DAY, True, None, "mdi:calendar-clock-outline", False, None, None, ], "DATE_MONTH": [ "Date month", EcotouchTag.DATE_MONTH, True, None, "mdi:calendar-clock-outline", False, None, None, ], "DATE_YEAR": [ "Date year", EcotouchTag.DATE_YEAR, True, None, "mdi:calendar-clock-outline", False, None, None, ], "TIME_HOUR": [ "Time hour", EcotouchTag.TIME_HOUR, True, None, "mdi:clock-time-five-outline", False, None, None, ], "TIME_MINUTE": [ "Time minute", EcotouchTag.TIME_MINUTE, True, None, "mdi:clock-time-five-outline", False, None, None, ],

number.py "BV_OPERATING_MODE": [ "Basic Vent Operating mode", EcotouchTag.BV_OPERATING_MODE, None, "mdi:clock", False, 0, 5, DEFAULT_STEP, NumberMode.BOX, ], And the correspondent translations. I hope, it helps.

marq24 commented 8 months ago

BV means 'basic vent' ?!

and when operating modes goes from 0 to 5, what is the meaning of the modes? [I mean what is mode=0 mode=1, ... mode=5 - there must/should be a translation?] - then this IMHO should be a selection (and not a number)...

EDIT - never mind - found it already... -> 'Tag','Nacht','Zeitprogramm','Party','Urlaub','Bypass'

verdao1914 commented 8 months ago

Yes, BV = BasicVent, but the variables are the same for EcoVent and BasicVent. Feel free to use a common naming convention.

And yes, you have found the correct match for the operating mode. 0 = "Tag" 1 = "Nacht" 2 = "Zeit" 3 = "Party" 4 = "Urlaub" 5 = "Bypass"

Thank you very much for your valuable work.

marq24 commented 8 months ago

I am trying to understand what you mean with "outgoing" in your variable names...

I have here in my sources Lüfter1 and Lüfter2... and some TAGs for each - Lüfter1 seams to be the incoming/inbound one - but Lüfter2 - is that outgoing/outbound and you call this ongoing ?!

and then I would like to know (best see in a screenshot) the T_EXTERNAL_AIR and T_EXAUSTING_AIR - what actually these values are... what is the different to the INCOMING and ON(OUT)GOING T values ?

verdao1914 commented 8 months ago

I hope the pictures can better explain than my imprecise words.

BasicVent_Schematic Registers

A4994 = T4 = T_Fortluft = T-Outgoing_air A4996 = T3 = T_Zuluft = T_Incomming_air A4998 = T2 = T_Abluft = T_Exausting_air A5000 = T1 = T_Außenluft = T_External_air

marq24 commented 8 months ago

Extremely cool! - thank you very much for sharing! - I am very curious - what is the source of this document (part) - and is there more? If yes I would be very happy to get access to that (eMail would just be fine)...

marq24 commented 8 months ago

@verdao1914 hast Du auch informationen für mich in welchenEinheiten die Werte:

# A4387: uom: '', 'Energieersparnis gesamt'
# A4389: uom: '', 'Energieersparnis aktuell'
# A4391: uom: '', 'Wärmerückgewinnungsgrad'

anzuzeigen sind?

marq24 commented 8 months ago

In the meantime you can try/test this BETA version... https://github.com/marq24/ha-waterkotte/releases/tag/2024.2.3

please note - This version of the integration will not be continued - after I have completed the refactoring process I have decided to create an independent repository - since the refactored build does not have anything in common with the origin sources.

How to migrate - the update path

  1. make a backup
  2. go to hacs menu of your home assistant installation
  3. remove the custom hacs repository 'https://github.com/marq24/ha-waterkotte'
  4. this step will/should remove the Waterkotte Integration from the HACS Integration entries
  5. add the new repository 'https://github.com/marq24/ha-waterkotte' to hacs
  6. install the waterkotte integration to hacs
  7. restart your system

YES - this procedure sounds totally silly - but hacs stores a custom-id for each repository - I have decided to rename the repository which base on the work from pattisonmichael to 'https://github.com/marq24/ha-waterkotte-the-fork' and created an independent repository.

verdao1914 commented 8 months ago

gesamt kWh aktuell W Gewinnung % Gruẞ,Fernando

marq24 commented 8 months ago

I am really curious - if somebody with an external vent unit have/could successfully test this?!

verdao1914 commented 8 months ago

I will Test It, bit Just at the Weekend. Sorry

marq24 commented 8 months ago

no worries - I am hoping there is more then one user ;-)

verdao1914 commented 8 months ago

Thank you very much for the implementation. Please take a look at the display of the air equipment: image

and now let us compare with the variables: image

The good news: values are comming. Improvement needed: All variables were divided by 10. This is not necessary. The heat pump provides integers for its own variable (to get the correct physical value you need to divide by 10, which the application does successfully). The ventilation system variables supplied via the heat pump already come in strings or floats (no need to divide by 10). Just keep the values as they come.

The selection of the operating mode works very well. Thank you very much.

marq24 commented 8 months ago

thanks for your feedback - please update to 2024.2.7

verdao1914 commented 8 months ago

Thank you very much for the quick change. We are going in the right direction, but there is still a difference. If I interpreted correctly, the values of the the previous version were multiplied by 10. That's not the same thing.

Note that the decimal values are lost.

image

image

verdao1914 commented 8 months ago

PLease take a look in the answers of the heat pump:

A4994 S_OK

192 11.656000

A4996 S_OK

192 21.108000

A4998 S_OK

192 21.056000

A5000 S_OK

192 8.294000

A4986 S_OK

192 52.799999

A4984 S_OK

192 52.799999

A4551 S_OK

192 2010.000000

A4547 S_OK

192 2040.000000

A4504 S_OK

192 20

I4582 S_OK

192 2

D1432 S_OK

192 0

A4498 S_OK

192 180.000000

marq24 commented 8 months ago

well - the default "A" values will all be provided without decimals - so for all the "other" (none vent) value the code is dividing the read string by 10... And the adjustments in the "new" build has been, that the value was divided by '1' - so IMHO this is not the root cause of the "precision loss"

can you please be so kind and check if the display change, when you alter the config.py file:

search for

    ExtSensorEntityDescription(
        key="BASICVENT_INCOMMING_FAN_A4986",
        name="basicvent_incomming_fan_a4986",
        tag=EcotouchTag.BASICVENT_INCOMMING_FAN_A4986,
        device_class=None,
        native_unit_of_measurement=PERCENTAGE,
        icon="mdi:wind-power",
        entity_registry_enabled_default=False,
        feature=FEATURE_VENT
    ),

and replace with

    ExtSensorEntityDescription(
        key="BASICVENT_INCOMMING_FAN_A4986",
        name="basicvent_incomming_fan_a4986",
        tag=EcotouchTag.BASICVENT_INCOMMING_FAN_A4986,
        device_class=None,
        native_unit_of_measurement=PERCENTAGE,
        icon="mdi:wind-power",
        entity_registry_enabled_default=False,
        suggested_display_precision=2,
        feature=FEATURE_VENT
    ),

so basically adding the suggested_display_precision=2, to the EntityDescription

verdao1914 commented 8 months ago

adding suggested_display_precision=2 changes just the display from 21.0 to to 21.00. I will reinstall the integration tomorow and start the test from beginning again.

marq24 commented 8 months ago

once more thanks for your fast reply - the issue is very deep in the parsing of the response... this will take me a while...

verdao1914 commented 8 months ago

Take your time. Thank you for sharing this amazing integration.

marq24 commented 8 months ago

ok - another day - another try... https://github.com/marq24/ha-waterkotte/releases/tag/2024.2.8

verdao1914 commented 8 months ago

Voila! Congratulations it works.

image

image

I still don't understand the filter change values. But I'll comment separately. The chapter Basicvent /10 or *10 is now closed.

verdao1914 commented 8 months ago

Also now the filter values:

image

image

#A4504 S_OK
192 19

#A4498 S_OK
192 180.000000

image

The unit is day(s).

marq24 commented 8 months ago

For the Luftfilter-Wechsel values... one is DAYS the other one is HOURS (based on the documentation)...

It would be great, if you can adjust the corresponding EntityDescriptions in the const.py (starting from Line 1668) locally and check/try what alternative values for device_class and native_unit_of_measurement would be more appropriate...

        device_class=SensorDeviceClass.DURATION,
        native_unit_of_measurement=UnitOfTime.HOURS,

Might be that using DURATION is already not a smart move...

verdao1914 commented 8 months ago

Sorry. It is everything ok. It was not necessary to edit const.py. just formatting correctly in the variables dialog box.

image

image

About the discusion days vs. hours, documentation vs. display, well I will keep what I am seeing in the equipment's display. But for the integration doesn't matter. It works perfectly. Thank you very much.

marq24 commented 8 months ago

cool - so we are done concerning the initial VENT impl - @Frank-H-H would be cool, if you can confirm & then close this issue here - TIA

marq24 commented 8 months ago

@verdao1914 I have one question - in the webinterface it's possible to TURN ON the manual mode of a FAN - and then you can adjust the rpm speed from 0-100%...

When you do this via the GUI, can you please be so kind and let me know, what WRITE requests the Webfrontend will sent to the Waterkotte? [Turn ON FAN1/2 will be the D1603/D1605 attributes that will be set from 0 to 1] - but what are the manual RPM registers, that will be written?! Can you please check this via the BrowserTools/Network Tab?!

verdao1914 commented 8 months ago

I would gladly do it if it were possible. The operation of the ventilation system by the heating pump's WEbUi is very rudimentary. Only the operating mode can be changed. Nothing else. And there is no WEbUI for the veltilization system. By typing in its IP address, you receive the same panel as on the equipment and operate it using the up and down arrows and enter key, just like on the equipment. Sorry.

marq24 commented 8 months ago

what's with the URL -> http://[IP-HERE]/easycon/pgvent.html ?! inspect the page - there might be "hidden" panel's [you can make them visible by altering the class name of the div]

verdao1914 commented 8 months ago

Nothing, Error 404. but I can imagine that this would lead to the operating panel of the equipment page. This one:

image

marq24 commented 8 months ago

No - I would expect something like this: [but me FE is v 2.4.1 - yours is 2.2.6]

image

verdao1914 commented 8 months ago

my version of the heating pump definitely doesn't have this page. But nice, very nice.

Frank-H-H commented 8 months ago

First of all: Thanks to all of you for having a shot at this. I updated to a more recent version last week and I am very happy with the ability to change the mode. Being able to see the fan speeds etc. is a nice on-top-feature.

Sorry for not staying in touch on this request. From my perspective, the issue could be resolved.

Frank-H-H commented 8 months ago

One more hint regarding fan speeds. According to the maintenance guy from waterkotte, these RPMs are usually fine tuned for your local installation (amount of rooms, air outlets, air inlets, etc.). I am currently not planning to mess around with those values. However, I had a look at the web gui, which is quite buggy for me. Most of the times it does not show any reasonable values at all. Just when I decided to stop trying, the GUI did start to show reasonable values: I set the manual RPMs in the GUI and those two requests were fired: http://ip/cgi/writeTags?returnValue=true&n=1&t1=3:HREG400443&v1=50&_=&rnd=1709483442071 http://ip/cgi/writeTags?returnValue=true&n=1&t1=3:HREG400445&v1=50&_=&rnd=1709483641291

marq24 commented 8 months ago

I assume you manually set them to 50% - correct?

Frank-H-H commented 8 months ago

correct

Frank-H-H commented 8 months ago

turning them on manually however did not work in the GUI (the buttons don't work)

marq24 commented 8 months ago

I further assume you must first set mode to "manual" and then you can adjust the rpm speed in the default web-gui... [which is anyhow Katastrophe! as Michael used to say]

marq24 commented 8 months ago

@Frank-H-H - new Version (beta) online - would be cool, if you can confirm, that manual vent speed settings are working... ;-)

Frank-H-H commented 7 months ago

Well, I can't even change the rpm speed from within the Waterkotte Heatpump web page GUI. Well, I actually can change the values, but I can't turn on the manual mode in any way. I checked for several modes (day, bypass, schedule), but not all of them. I definitely do not have a "manual" mode. grafik In Home Assistant, I did not get any input for the RPM. I only got two buttons for the manual mode for each fan (but they don't work change the settings in the EcoVent / Heatpump either). grafik

Again: I am very happy with the current functionality to be able to change the mode (thanks again for that).

marq24 commented 7 months ago

Danke Frank... I just want/need to confirm 1) you are on the latest BETA version of the integration right?

2) have you activated the additional Sensor entities for the vent speeds? -> search for the entities 'basicvent_incoming_fan_manual_speed_percent' and 'basicvent_outging_fan_manual_speed_percent'

3) for the none working switches - can you please be so kind and enable the debug log [https://github.com/marq24/ha-senec-v3/blob/master/docs/HA_DEBUG.md] - restart HA - then toggle on of the switched - and wait few seconds and then repeat this toggle step few (<5) times? And then send me the log (by mail) ?!

marq24 commented 7 months ago

... I just released another beta - for the ON/OFF modes there are alternative tags (that I have now implemented) you need to activate the new switches (same as the other new entities)...

Frank-H-H commented 7 months ago

Hi, I didnt know how to activate a beta before - so that's why I didn't see your rpm settings. Indeed with the 2024.3.2 changing the rpm percent is changing the values in the waterkotte GUI and it now even works to turn on the manual mode. I do have a power sensor in place for the ventilation system, so this directly shows the changes: grafik This is one of the button-ids to turn on manual mode: grafik

Do you still need the log for other buttons?

marq24 commented 7 months ago

When the buttons work as expected I do not need the logs - since looks like everything works as "designed"...

looks like this issue is finally done ;-)

Frank-H-H commented 7 months ago

Then thank you again :)