Beginner help with ESPHome / Bluetooth proxy

Oh for sure, I would not recommend anyone to desolder components from their Pi if that is the way they are running Home Assistant. As I mentioned, I use a USB dongle, that is a USB one, and I run on Home Assistant Blue, which an Odroid board. :slight_smile:
I haven’t used a Pi for a while. Forgot that HA now detects the BT on Raspberry pi 3B+ and 4 boards

Hello,
I have 3 esp32 devices added in esphome.
I am trying to make them Bluetooth tracker by adding the bluetooth_proxy: to the config files directly in esphome.
I am getting an error.
Any idea what could be?

No, I have no idea what the error you get could be, especially since you didn’t tell us what the message was. And you also didn’t show anything of the yaml you use to configure it. But, on the bright side, all esp32’s are online. :wink:

4 Likes

I had used the API in the part, but it was very unreliable. Got a new more ESP’s and got this one running fairly quickly (even with my youngest kid constantly asking me questions as he was stuck “programming” in scratch as a major diversion :face_with_hand_over_mouth:) ! All switchbot devices are now getting into HA through MQTT. Very nice :slight_smile: Thank you for pointing me in this direction.

1 Like

@nicolae.fratila

you can put this in your code.

# For Bluetooth Proxy
esp32_ble_tracker:

bluetooth_proxy:
1 Like

Does this work in a Raspberry Pi 3b for example? I have a couple around the house. Seems dumb to use esp32 when I all ready have hardware connected all over the place… :slight_smile:

@klidberg
ESPHome is only for ESP devices, not for Raspberry Pi’s. Raspberry is a different architecture.
You could look at USB IP to use the bluetooth in the Raspberry Pi 3b over IP.

1 Like

@Blacky and @nicolae.fratila
As Active Bluetooth is now possible via ESPhome, try modifying the code to

esp32_ble_tracker:
bluetooth_proxy:
  active: true

That should turn your ESPHome device, even if it is doing other things, into an Active Bluetooth Proxy and also utilise the ble tracking component.

Hey @brendan

I have tried to install bluetooth proxy on my esp32 using this link: ESPHome Bluetooth Proxy . However after installing it there is no logs or anywhere that would allow me to insert the code:

esp32_ble_tracker:
bluetooth_proxy:
  active: true

What am I doing wrong? Thanks

@bachoo786
If you used the ESPHome Bluetooth Proxy script to make a dedicated BT Proxy device, the script in the YAML for that device automatically adds the lines.
You only need to add the three lines of code if you want to add BT Proxy to an existing ESPHome device.
Example: I have a 4 channel LED Strip controller using an ESP32 chip. I have the code setup in ESPHome for the light. If I want to add BT Proxy to that device, I would edit that devices ESPHome YAML and add the three lines.

If you are doing a dedicated ESPHome BT Proxy, just run install from the web page and jobs done.
You won’t see anything in logs unless you use the most verbose (debug level I think) logging. Just see if your bluetooth devices connect to it when you have no other Bluetooth dongle on Home Assistant to test it.

So I have installed the dedicated ESPHome BT Proxy from the webpage and it doesn’t recognize any of my bluetooth devices. I used to run ESPHome on it before I installed the BT Proxy.

Also the local web server of the dedicated ESP32 after installing BT Proxy is not reachable.

I have tried it with 4x ESP32s that I have sitting around and all have the same issue.

So just trying to add this to an existing device and getting component not found; bluetooth proxy

Im on the latest version though? Anyone seen that?

Home Assistant 2022.10.4
Supervisor 2022.10.0
Operating System 9.2
Frontend 20221010.0 - latest

EDIT
So Im just having a look at the add on and the version seems really old. But I cant see a way to update it :frowning:

v2022.3.1

You will need to update the ESPHome add-on. Mine was stuck on 2022.3.x also. I had to uninstall it and reinstall to get it to update properly again.

1 Like

Yes, thank you. I worked out that I somehow missed, that the addon was depreciated LOL

so I managed to install esp and I am stuck here on the web server of the esp32:

Now I am totally confused with bluetooth-proxy. If I add the following lines to the configuration of ESP32 in ESPhome:

esp32_ble_tracker:
bluetooth_proxy:

Do I still need any physical BT device connected to HomeAssistant server (I am using nuc with no bluetooth)?
Do I need to do anything else or should I just expect that BT devices will automatically appear in my HA integrations?

Have you tried your Mi Flora sensors now with active enabled? Does it work for you and how fast do they update. I’ve tried several ESP32s with different configurations, all active. Initially everything seems to work fine, but after a while all sensors turn unavailable.

I’ve not got a bluetooth device on my HA installation and this works just by having ESP32’s setup as you have done.

I did find that it took a little while before Bluetooth devices were seen, but that’s because I think it only shows them after it’s seen something like 5 advertisements for the same MAC and nearly everything I have is Apple based that changes it’s MAC every time so doesn’t show up!

Still trying to find out if this BLE Tracker is going to be usable for my Apple devices or if I am going to have to stick with ESPresense.

@Lampyridae
MiFlota sensors work great with the Bluetooth Proxy. They always did. The only thing Passive could not get was battery level. All the other sensors work even with Passive. But Active does pick up the battery sensor well I have several MiFlora devices . They update as soon as the sensors send the data,. I haven’t actually sat down to work it out as I don’t watch my plants every second of the day, so even once every half hour is fine for plant sensors in my mind, but I do know it is a lot quicker than that. I would say every couple of minutes updates are there, but it could even be quicker.

The only thing I still can’t get to work with the Active BT Proxy is my August Smartlock via the Yale Bluetooth Integration. It just refuses to work.

I guess I’ll have to look into it again. :man_shrugging:t2: Cheers!

1 Like