kind3r / hass-addons

Integration of the offline TTLock sdk into Home Assistant
63 stars 23 forks source link

How about the bluetooth gateway? #32

Closed felipecrs closed 2 years ago

felipecrs commented 2 years ago

Hi, first, amazing project.

I started looking for smart locks to buy and integrate with my HA, and then I found your project and https://github.com/kind3r/hass-addons/issues/3. The model suggested there is very cool, but my door would not be close to my HA server, so direct connection via Bluetooth would not work for me.

I see that there is a gateway: https://aliexpress.com/item/33014871696.html

Any advice on this? Would it work with this project? I guess no, as it says that it requires Bluetooth.

Thank you!

kind3r commented 2 years ago

Hi @felipecrs ,

That is the official TTLock gateway that works with their app via their cloud. The goal of this project was to build an direct/offline integration that does not depend on their cloud.

There is another project that uses an ESP32-WROVER module as a bluetooth gateway: https://github.com/kind3r/esp32-ble-gateway exactly for the purpose of extending the bluetooth range.

In theory, their official gateway could be repurposed to work as a BLE extender, but someone would have to write a firmware for that. Also, it's way more expensive than an ESP32 module.

felipecrs commented 2 years ago

Got it. Thank you very much for the answer. I would suggest you to mention this in the README.md.

Fusseldieb commented 2 years ago

There is another project that uses an ESP32-WROVER module as a bluetooth gateway: https://github.com/kind3r/esp32-ble-gateway exactly for the purpose of extending the bluetooth range.

The sad part it, afaik, that it just connects to one lock, am I right?

kind3r commented 2 years ago

No, multiple locks work fine, the limitation is only one BLE gateway, for now. And you can't use both the BLE from the PI and a gateway.

Fusseldieb commented 2 years ago

the limitation is only one BLE gateway, for now.

Is this a limitation of the addon? Or the locks?

kind3r commented 2 years ago

the limitation is only one BLE gateway, for now.

Is this a limitation of the addon? Or the locks?

Of the addon. When I built it, living in an apartment building, I did not think that people will use more than one lock (like for entry). But again, it is possible to adapt and use multiple gateways + embeded BLE. The catch would be deciding which one should connect to which lock and how to report RSSI.