Bluetooth LE dropping with new HA 82 version

Hello all, now that version 82+ is out, bluetooth has started working for me! I’m running running HA in Docker. Excited to start using bluetooth for presence detection and related tasks. However, I’m seeing a problem that I haven’t been able to resolve. (would it be possible to add a tag called “bluetooth”?)

I’m using an Intel Nuc, which has built in bluetooth, and I also have a bluetooth dongle, both of which show the same symptom. I have three beacons (Estimote) they have been set to transmit in high power iBeacon mode. I can continuously see them from the command line using hcitool or btmon or btmgmt tooling, and I can see them using both hci devices.

What I’m seeing is I can start Docker and see all three beacons, but they will only be “home” for a few minutes, sometimes up to a few hours, but eventually they will fall to being “not_home” and stay that way forever.

Here’s my config:

device_tracker:
  - platform: nmap_tracker
    hosts: 192.168.0.100-199
    home_interval: 10
    exclude: !secret hass_ip
    track_new_devices: false
  - platform: bluetooth_le_tracker
#    hci_device: hci1
    track_new_devices: True
    interval_seconds: 2
    consider_home: 180

I don’t fully understand the consider_home flag, but I think 180 is the default setting to avoid having iPhones showing as not home when their wifi auto disconnects.

Hello all, still having problems with bluetooth dropping and showing “Not Home” after a while. But I made some changes to the config (I guess there are new syntax for some parameters?) and it now reliably works after I do a:

sudo hciconfig hci1 reset

command. Something on the machine periodically grabs the bluetooth device and HA loses control over it and all tracked devices turn to away and stay away forever until such a reset or full reboot of the machine. Any ideas?

device_tracker:
- platform: nmap_tracker
  hosts: 192.168.0.100-199
  interval_seconds: 10
  consider_home: 180
  exclude: !secret hass_ip
  new_device_defaults:
    track_new_devices: false
    hide_if_away: false
- platform: bluetooth_le_tracker
  interval_seconds: 3
  consider_home: 40
  hci_device: hci1
  track_new_devices: false
- platform: bluetooth_tracker

Not sure the hci_device option is in the standard component - are you using luca’s or my custom component (BLE custom component - #3 by kirichkov) ?

Changing to the standard one obviously won’t help with using hci1

I found that occasionally it would fall over *File I/O Error" in the log IIRC and then never try and run the le_scanner until a restart. In my custom_component I “successfully fail” if that happens (i.e. I let the run fail, but say it was successful - the following run then works okay)

I’m using the base blue_tracker and it works fine! Until it doesn’t. I suspect that what I have is some other service periodically grabbing the bluetooth device and HA loxes control and can’t get it back. Otherwise it will work great for a few hours now with no special components etc.