ebaauw / homebridge-nb

Homebridge plugin for Nuki Bridge
Apache License 2.0
51 stars 3 forks source link

Cant disable logs #124

Closed Maxiklaxi closed 9 months ago

Maxiklaxi commented 10 months ago

Regarding Issue #123

I am not a developer, so im not able to do that. But anyways, i am right now having the following issues:

Im trying to find a bug with another homebridge plugin which appears approx every 2.5 hours, but the logs are getting spammed away from nuki. So i thought to myself "Im getting all Nuki logs in my Nuki App on my Phone if i really need them" so ive tried your command:

Set Log Level on the accessory to 0 suppress the log messages.

    {
        "name": "Nuki",
        "latch": true,
        "port": 9999,
        "platform": "NB",
        "_bridge": {
            "logLevel": 0,
            "username": "0E:3F:A8:BB:72:3F",
            "port": 46423
        }
    },

(i also tried the command outside the bridge settings (below name), but that didnt work either) Im still getting all the logs. Where do i need to put the command?

Im also experiencing a bug where sometimes the door latches, even if im not using the latch button, with the unlock button which should not latch it. I can try to reproduce that for you and send you the logs.

ebaauw commented 10 months ago

You need to set the Log Level characteristic on the bridge accessory in Eve, or in another decent HomeKit app. Each accessory exposes this characteristic, so you can set different Log Level values for different accessories.

Maxiklaxi commented 10 months ago

Okay, so i was able to change the log level in my eve app. So that problem is solved for me! Thank you very much!

But the problem with the unlatch even that i did not usw the latch lever, still exists. When i just unlock my door without unlatching, this happens:

[5.11.2023, 16:10:30] [Nuki] Wohnungstür: Lock Target State: changed to 0 (from 1) [5.11.2023, 16:10:35] [Nuki] Wohnungstür: Lock Current State: set to 0 (from 1)

Its totally random, sometimes it happens, sometimes it works right. This is the log when i unlock and it unlatches without me wanting it to. Maybe this helps you.

ebaauw commented 10 months ago

I would need to see the debug log (Log Level 2 on the bridge while running Homebridge with debug enabled -D) for the interaction of Homebridge NB with the Nuki bridge.

I find that my v2.0 smart lock sometimes unlatches on lock or unlock, especially after being (un)locked manually, but not the full way. I suppose that’s just how the mechanism works in combination with my lock. Make sure to calibrate the lock and set the correct locking rotation in the Nuki app.

I think it could also be related with the Nuki bridge not reporting the state correctly, causing Homebridge NB to send unlock when the lock is already (half?) unlocked. Make sure the subscription of Homebridge NB for the Nuki bridge notifications works, and power cycle the Nuki bridge to make sure. If the first callback fails (typically because it’s stale), the next won’t be invoked.