thomasgermain / vaillant-component

Multimatic integration for Home Assistant (also compatible with sensoAPP)
MIT License
137 stars 24 forks source link

Report System errors into HA #15

Closed h4de5 closed 4 years ago

h4de5 commented 4 years ago

your dump.py script (from https://github.com/thomasgermain/pymultiMATIC) reports the following results on a vaillant system error:

hvac.json

{
    "body": {
        "errorMessages": [
            {
                "deviceName": "flexoTHERM",
                "type": "ERROR",
                "title": "Hochdruckschalter",
                "statusCode": "F.731",
                "description": "K\u00e4ltemitteldruck zu hoch. Integrierter Hochdruckschalter hat bei 41,5 bar (g) ausgel\u00f6st. Nicht ausreichende Energieabgabe \u00fcber den jeweiligen Verdampfer.",
                "hint": "Geb\u00e4udekreis entl\u00fcften. Pr\u00fcfen: ausreichend hoher Volumenstrom (vergr\u00f6\u00dfern durch \u00d6ffnen von Einzelraumreglern bei Fu\u00dfbodenheizung), Schmutzsiebe, K\u00e4ltemitteldurchsatz (elektronisches Expansionsventil, Vier-Wege-Ventil, Filter). VWL (K\u00fchlbetrieb): L\u00fcftereinheit (Verschmutzung), Luftkan\u00e4le (Verschmutzung).",
                "timestamp": 1596538856405
            }
        ]
    },
    "meta": {
        "onlineStatus": {
            "status": "ONLINE"
        },
        "firmwareUpdateStatus": {
            "status": "UPDATE_NOT_PENDING"
        },
        "syncState": [
            {
                "state": "SYNCED",
                "timestamp": 1596551098508,
                "link": {
                    "rel": "self",
                    "resourceLink": "/facilities/SERIAL_NUMBER/hvacstate/v1/overview"
                }
            }
        ]
    }
}

it would be great if this information gets somehow transported into home-assistant - maybe as an binary_sensor with the message as attribute.

thomasgermain commented 4 years ago

It should, via VaillantSystemErrorHandler. There should be an entity with id binary_sensor.vaillant.f_731 (or something similar).

Entities are created and removed dynamically

h4de5 commented 4 years ago

indeed: image

but it only showed up after I had restarted HA. I do have that automation in place which should update the hvac once in an hour - and I executed it before I checked for this sensor.

thomasgermain commented 4 years ago

hmm this is strange, there should be a check every 2 minutes (it just checks the local data in memory, there is no api call).

This is actually quite hard to unit test, but I will have a look.

h4de5 commented 4 years ago

thanks. i'll reset it now, remove that sensor and monitor it again - unfortunatelly that error comes up quite often ...

thomasgermain commented 4 years ago

Release 1.3.2 should fix the issue :)

I added some tests, so It seems to be ok, but I don't have much errors coming live.

As you know, entity id wildcard is binary_sensor.vaillant.error_{status code}. Maybe you can create an automation to test if such entities exist (with the given wildcard), or I think there are some card the filter entities, but I think this is only on state.

Please, let me know if it works !

Thomas

h4de5 commented 4 years ago

all fine btw.

thomasgermain commented 4 years ago

great fine :)

btwn do you have something to display those errors ? (a card to display entities if they exist, an automation, or something else). This is in my todo list, but I didn't find a good to do so

h4de5 commented 4 years ago

mmh. no not yet. As I only have that one re-occuring error I am just checking the flexoTHERM entity (attribute error and status).

I am about to write a feature request here to control the circulation pump - my bold guess is, that you could find some hidden parameter in the API that would make it possible to start it using HA how far off is that assumption? 😁

thomasgermain commented 4 years ago

If you are able to do it through the mobile app, then it should be possible to do it through pymultimatic and so through HA 😛

Are you talking about the domestic hot water circulation or is it totally different ?

h4de5 commented 4 years ago

I could only change the time program of the circulation through the app. I think it would be enough to have an easy way to the clear the current time program and change it in a way to start right now.