homeassistant_bold icon indicating copy to clipboard operation
homeassistant_bold copied to clipboard

Use Home Assistant with bluetooth to unlock instead of requiring a Bold Connect

Open lwestenberg opened this issue 2 years ago • 19 comments

The Homey integration also does this, it doesn't require a Bold Connect

lwestenberg avatar Jan 31 '23 09:01 lwestenberg

There is a Nuki Smart Lock integration that uses a pure BT approach, as well as an ESP32 option that is good for co-locating near the lock - it then communicates to HA via MQTT.

nickdos avatar Mar 11 '23 03:03 nickdos

I reverse engineered the Bold bluetooth lock system and made my own ESP32 implementation. It worked good for quite a while, but then they changed their API server side and then I decided to just buy a bold connect.

You need to make api calls to the bold server and send the payload data to the lock via bluetooth. I could share the source on github if you can want? The code isn't nice though haha

koenieee avatar Mar 18 '23 11:03 koenieee

That would be nice! Does your code connect to the lock over bluetooth?

lwestenberg avatar Mar 18 '23 12:03 lwestenberg

Yes it does, but it also needs wifi to retrieve de payload to unlock the lock via de Bold servers (although the payload is valid for a few days, so it can be re-used).

koenieee avatar Mar 18 '23 12:03 koenieee

When I have some spare time I can create a repository

koenieee avatar Mar 18 '23 13:03 koenieee

I found this Homebridge plugin that activates Bold Smart lock over Bluetooth:

https://github.com/robbertkl/homebridge-bold-ble

sibartlett avatar Jun 15 '23 23:06 sibartlett

That's looking way better than my code haha. Think it's not that hard to convert it for home assistant or esp32.

Op vr 16 jun. 2023 01:55 schreef Simon @.***>:

I found this plugin that activates Bold Smart lock over Bluetooth:

https://github.com/robbertkl/homebridge-bold-ble

— Reply to this email directly, view it on GitHub https://github.com/lwestenberg/homeassistant_bold/issues/17#issuecomment-1593856791, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAN3OVDBHG5HZ46WM3LFWSTXLOOH7ANCNFSM6AAAAAAUMFCZAM . You are receiving this because you were mentioned.Message ID: @.***>

koenieee avatar Jun 16 '23 06:06 koenieee

I tried it out. My thinking was that I could use the HomeKit Controller integration in HA to communicate with the Bold lock via Homebridge.

However I found it very unreliable; I needed to regularly reboot homebridge. I don't know if that's due to the plugin or homebridge itself... but that is out of scope of this thread.

I can confirm that the Homebridge plugin does unlock over Bluetooth, though it takes at least 3-4 seconds to perform.

sibartlett avatar Jun 16 '23 16:06 sibartlett

I am very interested in this feature :)

digwa-ing avatar Sep 11 '23 15:09 digwa-ing

Hi @koenieee

I'm working on the side to convert homebridge-bold-ble to work directly with HA. I saw in the comments that you also wrote a BLE integration for HA. Would you be open to sharing the code with me?

melicin avatar Oct 18 '23 21:10 melicin

Hi melicin, I wanted to upload it but it needed quite some work (ugly code haha) before it was shipable. The code is'nt really readable, because of the reverse engineering proces. I can just upload it in a repo but I don't really have time to support at the moment.

koenieee avatar Oct 19 '23 06:10 koenieee

I will try today to upload it again without adjustments (only clear my own data ofcourse), i have an older and a new version, but it could be it won't compile anymore because I was trying to refactor it a few months back.

By the way, be prepared that we are making our own Bold Connect. It would actually be really nice to just make a linux python integration with bluetooth usb in a raspberry pi. So you really don't need anything else.

koenieee avatar Oct 19 '23 06:10 koenieee

It took me some time, but here it is haha: https://github.com/koenieee/ESP32-BoldlockBluetoothImplementation

Questions about code or help wanted with your own code, make new issue at the above repo.

koenieee avatar Oct 19 '23 14:10 koenieee

Thank you so much @koenieee If I have any questions, I'll post it in your repository.

melicin avatar Oct 19 '23 15:10 melicin

Hi all. I'm quite interested in this feature to implement it into ESPHome if it was possible. Does somebody work on it lately?

Thank you in advance

jorgezazo avatar Mar 06 '24 08:03 jorgezazo

The Homey integration also does this, it doesn't require a Bold Connect

Hi! Any updates on this? Really curious if this works without the need of a Bold Connect. Thanks

BasPost avatar May 15 '24 12:05 BasPost

Bought a Bold lock recently and I am trying to stay away from the connect module. I am currently giving it a go to see if I can implement the bluetooth connection. I am not a huge expert in both python and home assistant, but so far I have the smartlock being discovered, you can configure it and a dummy lock entity is being created.

Now the hard part comes in understanding what I have created so far and seeing if I can get the further communication with the lock, based upon the code in the homebridge-ble repository.

peternijssen avatar Jun 15 '24 18:06 peternijssen

Bought a Bold lock recently and I am trying to stay away from the connect module. I am currently giving it a go to see if I can implement the bluetooth connection. I am not a huge expert in both python and home assistant, but so far I have the smartlock being discovered, you can configure it and a dummy lock entity is being created.

Now the hard part comes in understanding what I have created so far and seeing if I can get the further communication with the lock, based upon the code in the homebridge-ble repository.

How did you get on?

simonrb2000 avatar Jul 09 '24 11:07 simonrb2000

Bought a Bold lock recently and I am trying to stay away from the connect module. I am currently giving it a go to see if I can implement the bluetooth connection. I am not a huge expert in both python and home assistant, but so far I have the smartlock being discovered, you can configure it and a dummy lock entity is being created. Now the hard part comes in understanding what I have created so far and seeing if I can get the further communication with the lock, based upon the code in the homebridge-ble repository.

How did you get on?

I am working in my own fork of this library. Currently the device is auto discovered and when adding it a lock is being created.

Next step is getting the actual connection up and running which is complicated. Its hard as I don't have homebridge to compare the outputs with the python code. Took me a while to figure out that there is also a difference in output.

Furthermore I've got the API calls in postman running to get all the necessary data.

So I got all the necessary ingredients, but now I have to mix it all together.

If anyone is interested to contribute, please go ahead in my fork of this library.

peternijssen avatar Jul 09 '24 21:07 peternijssen