Bluetooth Proxy with ESPHome

Anyone who owns a house with several floors knows the problem, the simple Bluetooth devices are no longer recognized over several floors. For me, it’s simple thermometers that I read out via Bluetooth and have integrated into Home Assistant.

Bluetooth Proxy with ESPHome

These thermometers can be obtained for a few euros. With me, the thermometers in the attic were no longer found by the home assistant and could no longer be read.

A Bluetooth proxy can also be used if the Home Assistant hardware itself does not have Bluetooth support.

For the realization I got myself an ESP32 developer board that I made into a Bluetooth proxy with ESPHome. For the initial loading of the firmware, the board must be connected via USB to the Home Assistant computer or the computer on which you opened the Home Assistant interface. The existing WiFi connection can then be used for further corrections to the firmware. Cool, you don’t have to connect the microcontroller locally anymore. The advantage of a development board is that it has a USB connection.

Bluetooth Proxy with ESPHome

Let’s go! Connect the board to the computer on which you are currently operating Home Assistant. If the board is not recognized by your computer, take a look here , then you are missing the right driver. Go to the “New Device” button under ESPHome in the Home Assistant. In the next dialog, the name for the new device is assigned and then ESPHome tries to recognize the type of board and automatically creates and installs the appropriate firmware. The following steps appear and at the end the new board is equipped with the basic firmware. Now we just need to get the logic on board to set up the BlueTooth proxy.

Bluetooth Proxy with ESPHome

We can find the required configuration, the YAML code, on the ESPHome website at: https://esphome.io/components/bluetooth_proxy.html
From there we copy the part that is for the Bluetooth proxy and copy it to our board configuration

esp32_ble_tracker:
  scan_parameters:
    interval: 1100ms
    window: 1100ms
    active: true

bluetooth_proxy:
  active: true

To reduce the power consumption of the ESP board even further, I send the ESP into DeepSleep mode for 3 minutes between the scan intervals.

deep_sleep:
  run_duration: 310s
  sleep_duration: 180sec

In Home Assistant ESPHome we then click on EDIT on our board and copy the code at the end of the YAML script. Now that the board is connected via WiFi, we can save the new configuration and then install it via WiFi.

That was all, it’s that easy to install an ESP board as a BlueTooth proxy and integrate it into Home Assistant.
And since I have the Bluetooth proxy running on the 1st floor, I can also reliably reach my Bluetooth devices on the top floor.

Leave a Comment