Home Assistant and August Connect and August Lock

Yeah, I’ll take a look at that. Maybe create a persistent notification telling them they have no devices. It is pretty unlikely for that to happen though so maybe just a log message… A hub counts as a device and 99% of Wink users have a hub (most think it is a requirement for anything to work)

I only recently learned that you don’t need one. Now it seems like a good option to control e.g. the August Lock, which pairs with Wink with no hub and doesn’t have it’s own implementation in HASS.

LOL

Silly me :S I didn’t realize I had to add that in the app. I don’t have a Wink hub so I tough it would find the lock automatically … Not thinking today. I just added the lock and will try again.

That was a good catch @marthocoo :wink:

Cheers

DONE!!! @marthocoo … Again! That was a very good catch. They should add that to the installation process so newbies like me don’t get too lost :slight_smile:

Thanks a lot

Glad it worked! Haha sometimes the obvious things end up being the problem. Should probably update the docs to state that you must have at least one device paired if you aren’t using a hub, and I think @w1ll1am23 is going to make pywink fail more gracefully haha.

What’s everyones thoughts on this?

Screen Shot 2017-11-03 at 2.44.01 PM

If its good I’ll open a pull request.

Hi @w1ll1am23

You were luckier than me. I got an error but it worked after I added my august lock to the app.

What devices do you have?

Cheers

No, this is new I just added the code for it. I am asking if everyone thinks it is acceptable. If it is, I will open a pull request to get it added.

I think that would be a useful tool for new people looking to use it.

Apart from the typo in “devices”, I think it’s great! :slight_smile:

Actually maybe a small change: “You have no devices paired to your Wink account”. Your original wording makes it sound like you need a Wink branded device (ie hub) for it to work.

1 Like

Cool, thanks.

Just want to say thanks for this post, it is getting me setup for my august locks so that I can get them showing in hass! Before I saw this the best I came up was an August lock -> IFTTT -> webhook -> PHP script -> mqtt topic -> hass and that was only able to give me the state of the lock with no control over lock/unlock remotely (yuck!). So needless to say this is very much appreciated.

1 Like

I think I’m in the same boat here. I followed the steps and got the API keys, a configuration card in HA, the file .wink.conf with the 4 keys in it, but now when I restart, I get invalid configuration for wink and

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/setup.py", line 148, in _async_setup_component
    component.setup, hass, processed_config)
  File "/usr/lib/python3.5/asyncio/futures.py", line 380, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.5/asyncio/tasks.py", line 304, in _wakeup
    future.result()
  File "/usr/lib/python3.5/asyncio/futures.py", line 293, in result
    raise self._exception
  File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/wink/__init__.py", line 312, in setup
    pywink.get_subscription_key())
  File "/srv/homeassistant/lib/python3.5/site-packages/pywink/api.py", line 582, in get_subscription_key
    raise WinkAPIException("No Wink devices associated with account.")
pywink.api.WinkAPIException: No Wink devices associated with account.

I don’t have a wink hub but I do have an august door lock with august connect module. What was the eureka moment you all had here?

@mlefevre, so do you have the lock showing up in your home assistant UI? If not, the issue you are running into is you need to associate the lock with a wink account. You have to make a wink account and link it to your account then the lock will work.

You need to add the lock to your Wink account. Download the Wink app on your phone, sign in, add the August lock, then restart Home Assistant. No hub necessary.

Great. That fixed the initialization issues and I have a lock in my overview:

![Home%20Assistant%20(1)|497x140](upload://s5CUVkR2q9kFmK3BySPNN9WJOWV.png)

Thank you very much.

Now, on to the next problem. When I toggle the control, there is a 4 to 5 second delay before the lock actually changes state. After about two seconds, the panel control goes back to the previous state and then, a second or two after the lock actually changes state, the control returns to the state I requested. It kind of acts like it gives up on getting an acknowledgment of the request after two seconds but then gets it a couple of seconds after the lock actually changes. Is there any way to improve this behavior?

Home%20Assistant%20(1)

I have this issue too from time to time. It’s just the communication with the connect and home assistant and the Wink API. The delay is normal - this method inserts a bit of a delay.

For the state, do you mean the toggle - when selected - go from right (locked) to unlocked and then back to the locked position in the ui or you mean it actually changes state and then goes back to it’s previous state?

I’m afraid not - the delay is due to the August Connect, which IMO is a horrible piece of hot garbage (basically, your request is going to the Wink server, which goes to your August Connect (so August’s servers are involved), which then makes a Bluetooth connection to your lock, which then unlocks, which then sends its status to the connect via Bluetooth and so on, you get the idea.

Having not gotten an state update in a timely fashion, the lock platform assumes it is still in its old state. Then, it gets the new state and changes the toggle representation. Unfortunately, not much to do about it.