homebridge-eufy-security / plugin

Homebridge plugin to control certain Eufy Security devices
Apache License 2.0
165 stars 24 forks source link

[Bug]: Homekit arming alarm and disarming #438

Open alternativ opened 10 months ago

alternativ commented 10 months ago

What happened?

I was playing around with alarms and the contact sensor that I had installed at home. I found out that when I select away it is actually registering home in the eufy application and when I select away it disarms and sets home. I could manually circumvent this by setting the overrides as attached in the picture and the problem does not occur.

Please not that the attached config is showing after configuring the below.

Screenshot 2023-09-25 at 15 10 50

Device Type

Doorbell (Supported)

Plugin Version

v2.0.x (Supported)

HomeBridge Version

v1.6.x (Supported)

NodeJS Version

v18 (Supported)

Operating System

Raspbian 10+ (Supported)

Relevant log output

No logs displayed.

config

{
            "platform": "EufySecurity",
            "ignoreStations": [],
            "ignoreDevices": [],
            "cleanCache": true,
            "username": *masked*,
            "password": *masked*,
            "country": *masked*,
            "deviceName": "",
            "cameras": [
                {
                    "serialNumber": *masked*,
                    "rtsp": false,
                    "talkback": false
                },
                {
                    "serialNumber": *masked*,
                    "rtsp": false,
                    "enableCamera": true,
                    "enableButton": false,
                    "motionButton": false,
                    "indoorChimeButton": true,
                    "useCachedLocalLivestream": true,
                    "snapshotHandlingMethod": 2,
                    "videoConfig": {
                        "audio": false,
                        "audioSampleRate": 0
                    },
                    "refreshSnapshotIntervalMinutes": 5
                }
            ],
"_bridge": {
                "username": *masked*,
                "port": 44278
            },
            "stations": [
                {
                    "hkHome": 1,
                    "hkAway": 0,
                    "serialNumber": *masked*,
                    "hkNight": 2,
                    "hkOff": 63
                }
            ]
        }
github-actions[bot] commented 10 months ago

Did you check this Common Issues pages ?

gazzmanzx6 commented 10 months ago

It appears that in version 2.2.21 the home/away logic has been inverted. Rolling back to 2.2.20 fixes the issue for me.

alternativ commented 10 months ago

@lenoxys, I found the commit https://github.com/homebridge-eufy-security/plugin/commit/6e58ea768df66f3fb3df35e6df8a94548adda262

const config: StationConfig = { hkHome: stationConfig?.hkHome ?? this.platform.config.hkHome ?? 0, hkAway: stationConfig?.hkAway ?? this.platform.config.hkAway ?? 1, hkNight: stationConfig?.hkNight ?? this.platform.config.hkNight ?? 2, hkOff: stationConfig?.hkOff ?? this.platform.config.hkOff ?? 3,

hkHome should be 1 and hkAway should be 0.