Skip to content
This repository has been archived by the owner on Nov 5, 2021. It is now read-only.

Delayed status update to home.app #117

Open
mbriney opened this issue Nov 4, 2018 · 14 comments
Open

Delayed status update to home.app #117

mbriney opened this issue Nov 4, 2018 · 14 comments

Comments

@mbriney
Copy link

mbriney commented Nov 4, 2018

I'm having some issues with the plugin polling the Schlage Connect locks. In the home.app when I press the door lock it starts the process. Immediately homebridge responds, the doors lock and I get these two items in the log:

[2018-11-3 23:14:27] [Wink] Sending update: Rear Door (lock/262658) { locked: true }
[2018-11-3 23:14:27] [Wink] Update sent successfully: Rear Door (lock/262658)

However the home.app keeps on spinning the pinwheel and saying that the door is still "Locking..."

Eventually it re-polls the status on the hub of all devices and shows the item as locked.

Earlier in the log it also shows the following wink related entries.

[2018-11-3 23:13:52] [Wink] Checking if hub is reachable (Wink Hub 2, 192.168.7.149)...
[2018-11-3 23:13:52] [Wink] Hub is reachable locally (Wink Hub 2, 192.168.7.149)
[2018-11-3 23:13:53] [Wink] Authenticated with local hub (Wink Hub 2, 192.168.7.149)

I've also tried adjusting the config to set "direct_access": false. But that doesn't seem to improve the response time either.

How can I get it to show the door lock status faster to the home.app?

Thank you,
-Matt

@sibartlett
Copy link
Owner

Does restarting homebridge resolve the issue?

I have the exact same lock, so I can also check what is happening with mine.

@mbriney
Copy link
Author

mbriney commented Nov 7, 2018

Restarting Homebridge will then poll everything and show the correct status but it eventually does get back into this state again.

@mbriney
Copy link
Author

mbriney commented Nov 10, 2018

I'm wondering. In src/devices/lock.js

In the set: value => function. After setting the lock state could you have it pause for 3 seconds and have it run Characteristic.LockCurrentState.

I'm wondering if calling that would then have the Wink hub run a check to see if the door did lock/unlock?

@themick4u
Copy link

themick4u commented Nov 28, 2018

I frequently experience the same thing with my Schlage lock as well. A pause then poll seems logical if it can be done. Thoughts>?

@jason-klein
Copy link

Thanks to @sibartlett for their work on the Homebridge Wink plugin!

I occasionally experience the same issue with same lockset @mbriney described. Here is more detail. I will update this issue with any other symptoms or patterns I notice, or any solutions I find!

If someone can give me some direction, I would be glad to attempt to code/test a solution locally and submit a PR.

Related Symptoms

When I LOCK or UNLOCK the Schlage Connect device via Home App on iOS (or via Siri on HomePod), the device status in Home App may show "Locking..." or "Unlocking..." for 3-5 seconds OR indefinitely. The physical device ALWAYS immediately locks or unlocks as expected. However the device status in Home App does NOT always change to "Locked" or "Unlocked" as expected.

Note - If I restart Homebridge when the device status is stuck as "Locking..." or "Unlocking...", the device status is repolled immediately after Homebridge restart and Home App correctly shows "Locked" or "Unlocked". However, this does NOT resolve the problem. The next time I try to LOCK or UNLOCK the device, the Home App may show "Locking..." or "Unlocking..." 3-5 seconds OR indefinitely.

When Home App is receiving the device status change correctly, the Homebridge logs look like this:

ELECTRONIC UNLOCK

[4/1/2019, 2:21:10 AM] [Wink] Sending update: Front Door (lock/123456) { locked: false }
[4/1/2019, 2:21:10 AM] [Wink] Update sent successfully: Front Door (lock/123456)
[4/1/2019, 2:21:14 AM] [Wink] Received update notification: Front Door (lock/123456)
[4/1/2019, 2:21:17 AM] [Wink] Received update notification: Front Door (lock/123456)

ELECTRONIC LOCK

[4/1/2019, 2:21:22 AM] [Wink] Sending update: Front Door (lock/123456) { locked: true }
[4/1/2019, 2:21:22 AM] [Wink] Update sent successfully: Front Door (lock/123456)
[4/1/2019, 2:21:25 AM] [Wink] Received update notification: Front Door (lock/123456)
[4/1/2019, 2:21:29 AM] [Wink] Received update notification: Front Door (lock/123456)
[4/1/2019, 2:21:32 AM] [Wink] Received update notification: Front Door (lock/123456)

When Home App is NOT receiving the device status change, the Homebridge logs are as follows. Note the physical lock DOES unlock or lock immediately after the "Update sent successfully" message, but there are no "Received update notification" messages.

ELECTRONIC UNLOCK

[4/1/2019, 1:37:55 AM] [Wink] Sending update: Front Door (lock/123456) { locked: false }
[4/1/2019, 1:37:55 AM] [Wink] Update sent successfully: Front Door (lock/123456)

ELECTRONIC LOCK

[4/1/2019, 1:38:02 AM] [Wink] Sending update: Front Door (lock/123456) { locked: true }
[4/1/2019, 1:38:02 AM] [Wink] Update sent successfully: Front Door (lock/123456)

Status Change when Physically Unlocking/Locking Schlage Connect

If I go to the door and physically lock or unlock the Schlage Connect lock, the Home App device status may change in 3-5 seconds or may not change at all (e.g. still shows "Locked" even after I unlock door). When the Home App device status changes as expected, the Homebridge logs show the "Received update notification" messages. When the Home App device status does not change, the Homebridge logs do NOT show the "Received update notification" messages.

PHYSICAL UNLOCK

[4/1/2019, 2:19:38 AM] [Wink] Received update notification: Front Door (lock/123456)

PHYSICAL LOCK

[4/1/2019, 2:19:43 AM] [Wink] Received update notification: Front Door (lock/123456)

As far as I can tell, the WINK App always shows the correct "Locked" or "Unlocked" status about 1-2 seconds after I physically change the door from unlocked to locked, or from locked to unlocked respectively. Unsure if it is coincidence, but each time I open the WINK App to investigate the hanging "Unlocking.." or "Locking..." device status issue, the issue seems to clear up.

@themick4u
Copy link

themick4u commented Apr 1, 2019 via email

@jason-klein
Copy link

My Environment Details Homebridge 0.4.47 in a Docker 18.06 container on a Raspberry Pi 3 connected to same ethernet switch as Wink hub and wireless router/AP. I have a new/clean install of Raspbian Stretch Lite (version 2018-11-13) and a fresh/clean install of the latest Homebridge Docker image published 3 days ago (https://hub.docker.com/r/oznu/homebridge) via the Quick Install Script provided by @oznu (https://github.com/oznu/docker-homebridge/wiki/Homebridge-on-Raspberry-Pi).

@jasontproject
Copy link

@jason-klein I also have the exact same issue after just doing a fresh installation of homebridge 0.4.49 and homebridge-wink3 2.0.0

@sibartlett
Copy link
Owner

Wink changed their push notification infrastructure, I've pushed a new version of this plugin.

Please update homebridge-wink3 to 2.1.0

@jasontproject
Copy link

very nice, I should have checked this issue before spending the last couple of hours figuring this out and preparing a PR:)
Updated to 2.1.0 and works

@Kepete
Copy link

Kepete commented Sep 21, 2019

I'm experiencing the same issue as described here before by others. The lock stays in unlocking... or locking... state for few hours or until i restart homebridge.

The difference is that I'm using August Smart Lock 3rd(non pro).

I'm running homebridge-wink3 v2.1.0

@Kepete
Copy link

Kepete commented Oct 9, 2019

Still struggling with this issue :(

@Kepete
Copy link

Kepete commented Oct 9, 2019

Updated everything to the newest:
node: v10.16.3
homebridge: 0.4.50
wink-3 plugin: homebridge-wink3 v2.1.0

@sibartlett
Copy link
Owner

Sorry, I am no longer actively maintaining this project. I am no longer using Wink, and do not have the time or resources to dedicate more to ongoing maintenance.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants