deconz-community / node-red-contrib-deconz

Node-Red Nodes for deCONZ connectivity.
GNU General Public License v3.0
81 stars 16 forks source link

Homekit payload differs to state payload #179

Closed 1up-exe closed 2 years ago

1up-exe commented 2 years ago

Current Behavior

Hi folks,

I migrated from version 1.3.4 to the latest (2.1.1) one. I noticed the different values in the Homekit and state payload. In Homekit (ConctactSensorState) is always open. The state shows the correct value which represents - of course - the right value from Phoscon.

Screenshot 2021-11-26 at 14 05 26

Expected Behavior

I would have expect the same values :)

Steps To Reproduce

No response

Example flow


[
    {
        "id": "6559994c.30ff88",
        "type": "deconz-input",
        "z": "3187c254.adc20e",
        "name": "",
        "topic": "",
        "config_version": 2,
        "server": "fd082de3.1357e",
        "statustext": "",
        "statustext_type": "auto",
        "search_type": "device",
        "device_list": [
            "sensors/uniqueid/00:15:8d:00:04:02:22:99-01-0006"
        ],
        "device_name": "",
        "query": "",
        "outputs": 2,
        "output_rules": [
            {
                "type": "state",
                "format": "single",
                "output": "onupdate",
                "onstart": true,
                "payload": [
                    "open"
                ]
            },
            {
                "type": "homekit",
                "format": "single",
                "onstart": true,
                "onerror": true,
                "payload": [
                    "ContactSensorState"
                ]
            }
        ],
        "x": 110,
        "y": 700,
        "wires": [
            [
                "e2b0c8ec.4d35b8"
            ],
            [
                "e2b0c8ec.4d35b8"
            ]
        ]
    },
    {
        "id": "e2b0c8ec.4d35b8",
        "type": "debug",
        "z": "3187c254.adc20e",
        "name": "",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 320,
        "y": 700,
        "wires": []
    },
    {
        "id": "fd082de3.1357e",
        "type": "deconz-server",
        "name": "ConBee",
        "ip": "x.x.x.x",
        "port": "8080",
        "ws_port": "8081",
        "secure": false,
        "polling": "15"
    }
]```

### Environment

- deCONZ plugin version: 2.1.1
- HomeKit plugin version (if used): 1.4.3 (node-red-contrib-homekit-bridged) > hap-nodejs 0.9.6
- Node-RED version: 1.3.7
- Node.js version: 12.21.0
- npm version: 6.14.11
- Platform/OS: Linux
- Browser: Chrome

// Edit: HomeKit Plugin Version
Zehir commented 2 years ago

The fix is published in 2.1.2