diy ble bluetooth gateway
Here are a quick guide to get ble bluetooth gateway running in Home Assistant.
Requirements
You are running Home Assistant version 2022.8.0 or newer.
You have qualified product based on bluez.
You have Access to the device in Yeelight app.
You know how to Eight Deprecated BlueZ tools.
You know how to get the Bluetooth working.
You have a Firmware can be updated in the application after connecting the bulb
Bluetooth adapters
1.Some Bluetooth adapters are bundled with a Wi-Fi card (e.g. Intel Centrino). These require that the Wi-Fi card is firstly enabled (typically a keyboard shortcut on a laptop) in order to make the Bluetooth adapter visible to the kernel.
2.Some Bluetooth cards (e.g. Broadcom) conflict with the network adapter. Thus, you need to make sure that your Bluetooth device gets connected before the network service boot.
https://wiki.archlinux.org/title/Bluetooth
3.You have qualified product based on bluez
Supported devices
https://www.msly.cn/boards/postcreate/14403/20178
https://www.home-assistant.io/integrations/govee_ble#supported-devices
https://www.home-assistant.io/integrations/yalexs_ble/#supported-devices
YRD216 (Yale Assure Lock Keypad with Physical Key)
YRL216 (Yale Assure Door Lever Lock with Push Button Keypad)
...
bluez-utils bluetoothctl utility
Install the bluez-utils package, providing the bluetoothctl
utility.
Since Sept 2016’s release of Bluez5.42, many packages that online guides use were deprecated (https://wiki.archlinux.org/index.php/Bluetooth#Troubleshooting). Oh, and the Bluez package is severely lacking in official documentation.
Some tools such as hcitool and hciconfig have been deprecated upstream, and are no longer included in bluez-utils. Since these tools will no longer be updated, it is recommended that scripts be updated to avoid using them.
Eight Deprecated BlueZ tools and replacement
https://wiki.archlinux.org/title/Bluetooth#Deprecated_BlueZ_tools
bluetoothctl
btmgmt
There is a bug with some motherboard bluetooth controllers.
To see if this might be the issue, run journalctl | grep hci. If there are entries like "command tx timeout" or "Reading Intel version command failed", then power off your pc and physically unplug the power cable for a few seconds. This forces the controller to reload the firmware (while a standard reboot will not).
Useful links
Passive BLE Monitor integration
ESPHome Miscale integration
Xiaomi RTCGQ11LM control via MQTT