home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
69.89k stars 28.98k forks source link

iBeacons without names are not seen by the integration #80357

Closed Sorien closed 5 months ago

Sorien commented 1 year ago

The problem

im testing iBeacon with android app https://play.google.com/store/apps/details?id=net.alea.beaconsimulator&hl=en&gl=US iBeacom is detected and integreation configured but no device added

image

What version of Home Assistant Core has the issue?

2022.10.4

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Container

Integration causing the issue

iBeacon Tracker

Link to integration documentation on our website

No response

Diagnostics information

iBeacon packets are transmitted and looks ok verified by Acrylic Bluetooth LE Analyzer

image

but no device visible in home assistant

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

home-assistant[bot] commented 1 year ago

Hey there @bdraco, mind taking a look at this issue as it has been labeled with an integration (bluetooth) you are listed as a code owner for? Thanks! (message by CodeOwnersMention)


bluetooth documentation bluetooth source (message by IssueLinks)

home-assistant[bot] commented 1 year ago

ibeacon documentation ibeacon source

Electronlibre2012 commented 1 year ago

hello @Sorien

i have try and it works like a charm. Strange thinh its when i create a ibeacon and shutdown after 1 minute and on again i have an another one create.

But it works.

Perhaps you Bluethooth on HA is no recognize well?

bluethooth

have you got a bluthooth integration like this in HA?

Sorien commented 1 year ago

Bluetooth integration works well I have multiple temperature and motions sensors

image

I've tried to restart home assistant multiple times, remove and readd iBeacon tracker integration but still no device

bluetooth diagnostics https://gist.github.com/Sorien/2045397188ea1f4198f7a84bed5715e0

guibom commented 1 year ago

I have the same issue, but interestingly the second I installed an esphome bluetooth proxy, it was able to pick them all up! But it doesn't look like a distance issue, since I was testing with the beacons right next to my HA rpi.

kk-sonata commented 1 year ago

Same issue here, I also have a Qingping/Xiaomi BLE temp/humidity monitor and wonder if it's related?

Sorien commented 1 year ago

it looks like a parser issue I'm sure iBeacon was working on Bluetooth ble integration and now a few days later I see some random devices but not my phone...

Sorien commented 1 year ago

2022.11.0 still broken

Sorien commented 1 year ago

missing device is caused by this line https://github.com/home-assistant/core/blob/dev/homeassistant/components/ibeacon/coordinator.py#L300 where device name is like 63-65-B7-CA-B4-E5 and address 63:65:B7:CA:B4:E5 it looks like beacons without a transmitted name are not recognized

danielduerr commented 1 year ago

I believe I am having the same issues. Initially installed iBeacon integration using the built-in BT adapter in my RPI. Everything worked great for like a week and then one by one I started losing my devices -- 2 BlueCharm iBeacons, and the built-in Tesla Model 3 iBeacon. The devices would eventually disappear entirely without me deleting them. Adding an ESPHome BT proxy did not make any difference. Yesterday I changed the UUID, major, and minor on my BlueCharm iBeacons hoping that would help, but still no luck. At this point, I'm thinking this issue is the root cause.

Fonsohome commented 1 year ago

I have the same problem. I bought a Chipolo ONE and it automatically detected the integration but when configuring it it does not create any entity, I specifically bought this ibeacon because it appears on the compatible list.

Fonsohome commented 1 year ago

through the Passive BLE integration of HACS if it detects it but does not create a presence or distance sensor, any ideas?

arnoo commented 1 year ago

Same here, Chipolo ONE entities do not get created.

Sorien commented 1 year ago
    The integration is explicitly not supporting iBeacon's without a name set because it created too many transient entities during beta testing.

Originally posted by @bdraco in https://github.com/home-assistant/core/issues/81599#issuecomment-1306114964

Fonsohome commented 1 year ago
    The integration is explicitly not supporting iBeacon's without a name set because it created too many transient entities during beta testing.

Publicado originalmente por@bdracoen #81599 (comentario)

Well, remove the support of the ibeacons from the web, such as the chipolo.

fprokop commented 1 year ago

I have the same issue as OP. Bluetooth integration works as a charm, but nothing gets picked up from the iBeacon integration. There are several people with the same issue in the community: https://community.home-assistant.io/t/ibeacon-and-android-companion-app-ibeacon-tracker-does-not-show-anything/488904

I hoped that with the Shelly Proxy update something might get picked up, but still nothing, so it seems related to the integration,

vinz486 commented 1 year ago

But, even the Android Companion app, enabling beacon transmitter, can be detected by HA.

ghost commented 1 year ago

I would like to know if anyone actually has an instance of the of the android home assistant companion app successfully working with the BLE ibeacon integration using the Linux bluetooth stack, ie. no ESPhome remote BLE receivers. The linux bluetooth stack doesn't seem to be receiving anything from android home assistant companion at all. The linux btmon command is showing nothing from the phone. I've tried multiple phones, multiple BLE dongles on different machines, but still nothing. However my bluecharm transmitter works 50 feet away.

My suspicion is that the altbeacon library that all the android "ibeacon" transmitters/receivers are based upon are not transmitting actual "ibeacon" style advertisments in same manner as a dedicated hardware transmitter, but the advertisment packets are differently formatted and are getting ignored by the linux bluetooth stack. The ibeacon transmitter works between android devices using the same library, but not from android to linux.

vinz486 commented 1 year ago

Interesting. I just tried between HA App and my Ubuntu box: no packets. There is some configuration, linux side, to make packets pass?

Sorien commented 1 year ago

@eyager1 I can't test it but I'm almost sure that companion's app beacons are not detected by the iBeacon extension

altbeacon lib is not submitting the device name in beacon (packet length restrictions) and doesn't handle on scan response https://github.com/AltBeacon/android-beacon-library/blob/master/lib/src/main/java/org/altbeacon/beacon/BeaconTransmitter.java#L201

findel commented 1 year ago

I've added Bluetooth integration today (HA Container via Docker Compose on a Raspberry Pi), turned on the BLE Transmitter setting on my phone Companion app, and added the iBeacon Tracker integration also. Nothing is showing up for me either.

Sorien commented 1 year ago

the current implementation in the companion app is useless, android will restrict ble transmitter usage when the app is in the background (even with the highest transmission rate you can/will have delays in the transmitted beacons in hours)...

if anybody wants I can share my implementation it's not nice code you have to compile it yourself but it's working without any problem for a month or so and can transmit 1 beacon in 10 minutes, with some automation it controls heating at my house

findel commented 1 year ago

I did just manage to get something to show up in the iBeacon Tracker. I had to Bluetooth pair my phone with the Raspberry Pi. Then a "Phone DFCE" showed up. However, I expect this will not continue keep a connection unless I connect to the Pi manually, which don't expect is how things are meant to work. I've not much experience with iBeacon stuff.

vinz486 commented 1 year ago

I did just manage to get something to show up in the iBeacon Tracker. I had to Bluetooth pair my phone with the Raspberry Pi. Then a "Phone DFCE" showed up. However, I expect this will not continue keep a connection unless I connect to the Pi manually, which don't expect is how things are meant to work. I've not much experience with iBeacon stuff.

iBeacon is not a "pairing" stuff. Each device broadcast an UUID that should be picked by a scanner without any pairing.

JakobTewes commented 1 year ago

I have the same problem. I bought a Chipolo ONE and it automatically detected the integration but when configuring it it does not create any entity, I specifically bought this ibeacon because it appears on the compatible list.

Got exactly the same. My emulated (bluez-utils) iBeacons were not recognized. Now I´ve purchased some Chipolo ONE (as they were listed as supported) only to not find them recognized ;-(

Can you please check and solve?

JakobTewes commented 1 year ago
    The integration is explicitly not supporting iBeacon's without a name set because it created too many transient entities during beta testing.

Publicado originalmente por@bdracoen #81599 (comentario)

Well, remove the support of the ibeacons from the web, such as the chipolo.

Is there tested recommendations for manufacturers with tested working ibeacons?

Crazy5how commented 1 year ago
    The integration is explicitly not supporting iBeacon's without a name set because it created too many transient entities during beta testing.

Publicado originalmente por@bdracoen #81599 (comentario)

Well, remove the support of the ibeacons from the web, such as the chipolo.

Is there tested recommendations for manufacturers with tested working ibeacons?

I bought Feasycom FSC-BP108, after I failed with Chipolos, and it got recognised after few seconds. Chipolos just don´t work and they should not be listed as supported in my opinion.

boswelja commented 1 year ago

I have a similar issue, my previously detected Tesla beacon no longer appears, and enabling BLE Transmitter in the android app also shows nothing. Why do we have integrations that straight up don't work?

Edit: It did eventually appear, it just took a while. Like 2-3 hours

SpecialDelivery1 commented 1 year ago

I have a Chipolo ONE as well. I had it working after a long struggle. I tried so much and suddenly I discovered it worked but I don't know why or how to reproduce. Recently I migrated from home assistant inside a docker container to haos. Now I am struggling again. I am hopeful, because I know it is possible somehow. Things I gathered so far:

My Chipolo only transmits as an iBeacon, if it is a) connected to the chipolo app on my phone. Otherwise it shuts of after a few seconds to convert battery b) phone location permission is set to 'always' c) not currently communicating with that phone. I discovered, it regularly send updates, when I turn off bluetooth. I don't know if shutting down the app is enough.

I connected it to an old phone which I then turn off and leave in my drawer unused. I had it working but after migrating I only see the integration. Also the tracked beacon was always marked as 'home'. To circumvent this I created an Automation which uses the device_tracker.see service to update a custom device tracker based on the time of the last received transmission.

SpecialDelivery1 commented 1 year ago

Ok, I got it working again, but I have no idea what caused it.

  1. I ssh into haos and used bluetoothctl to trust, pair and connect to my chipolo. I have no idea, why this would work but that's what I did
  2. I also removed and readded both bluetooth and ibeacon integration. Again, I don't think this did anything, but I mention everything I did
  3. I gave up and tried to implement a bluetooth_le_tracker and after restarting homeassistant the chipolo was discovered in the iBeacon Tracker.

Maybe this helped, maybe it was coincidence.

swejmansson commented 1 year ago

+1, same issue for me.... Added a ASUS USB-BT400 to HAOS 2023.1.4 and cannot get any beacons to show-up. Removed and re-added pretty much everything I can think of + trying the above advices, still nothing shows up. BT is working fine with Switchbot Lock.

dtrochow commented 1 year ago

I am having the same issue. I have two Holy-IOT iBeacon trackers and BT integration set up.

I have checked if the beacons work properly using bluetoothctl and I am even able to connect to them from Terminal where HA is running, but unfortunately no devices shows up in iBeacon Tracker integration.

I can even see the logs that HA receiving something from my beacons 2023-01-17 00:06:57.304 DEBUG (MainThread) [bleak.backends.bluezdbus.manager] received D-Bus signal: org.freedesktop.DBus.Properties.PropertiesChanged (/org/bluez/hci0/dev_F8_3E_66_AB_F4_A2): ['org.bluez.Device1', {'RSSI': <dbus_fast.signature.Variant ('n', -96)>}, []]

JakobTewes commented 1 year ago

Sent back the Chipolo beacons and bought Holy-IOT NRF51822 ones. Frustratingly only one of them (although sending their names) is recognized. This integration tbh. feels totally beta. Maybe marking that as beta is a good idea in terms of expectation management?

markusleh commented 1 year ago

The documentation states that Chipolo One Spot (i.e. Find My tag) is supported and Chipolo One (Bluetooth only) is a completely different product. Could you @SpecialDelivery1 confirm that you were able to get it working using the Chipolo One tag so the documentation could be fixed?

Crazy5how commented 1 year ago

The documentation states that Chipolo One Spot (i.e. Find My tag) is supported and Chipolo One (Bluetooth only) is a completely different product. Could you @SpecialDelivery1 confirm that you were able to get it working using the Chipolo One tag so the documentation could be fixed?

There was only "Chipolo One" before in documentation. So it got finally updated to "Chipolo One Spot" to avoid confusion. Chipolo One does not work with this integration.

markusleh commented 1 year ago

There was only "Chipolo One" before in documentation. So it got finally updated to "Chipolo One Spot" to avoid confusion. Chipolo One does not work with this integration.

But Chipolo One Spot is for Find My network. Why would it work with the iBeacon integration?

SpecialDelivery1 commented 1 year ago

@markusleh I am using the 'normal' Chipolo One without 'Find My' integration. I chose this one specifically, because I needed a way to detect my girlfriend's presence at home without the possibility to track her location at all times which I deem intrusive.

Sadly, I cannot provide a fool-proof solution as to how to get it working. But so far I have managed to get the Chipolo One to show up in the iBeacon Integration twice. I had HA inside a docker container before and upon migrating the Chipolo stopped being recognized, but I was able to get it working again. 'Working' might not be the correct term though, as it is never marked as 'away'. For presence detection I created my own, hacky solution. HA receives a signal from the Chipolo every minute or so and I use the time of the last received signal for detection. If the last signal is longer than x amount of time ago, I update my girlfriend's status with the device_tracker.see service.

I am using a Raspberry Pi 4B and it's built-in bluetooth. As metioned before I have it working with HAOS, but I also had it working in a docker container as well.

mrIngrid commented 1 year ago

@markusleh Sto usando il "normale" Chipolo One senza l'integrazione "Trova il mio". Ho scelto questo in particolare, perché avevo bisogno di un modo per rilevare la presenza della mia ragazza a casa senza la possibilità di rintracciare la sua posizione in ogni momento che ritengo invadente.

Purtroppo, non posso fornire una soluzione infallibile su come farlo funzionare. Ma finora sono riuscito a far apparire il Chipolo One due volte nell'integrazione iBeacon. Avevo HA all'interno di un contenitore docker prima e dopo la migrazione il Chipolo ha smesso di essere riconosciuto, ma sono riuscito a farlo funzionare di nuovo. Tuttavia, "lavorare" potrebbe non essere il termine corretto, poiché non viene mai contrassegnato come "assente". Per il rilevamento della presenza ho creato la mia soluzione hacky. HA riceve un segnale dal Chipolo ogni minuto circa e io utilizzo l'ora dell'ultimo segnale ricevuto per il rilevamento. Se l'ultimo segnale è più lungo di x quantità di tempo fa, aggiorno lo stato della mia ragazza con il servizio device_tracker.see.

Sto usando un Raspberry Pi 4B ed è bluetooth integrato. Come accennato in precedenza, l'ho fatto funzionare con HAOS, ma l'ho fatto funzionare anche in un contenitore docker.

Hi, i have purchased Chipolo One and Chipolo One Spot, and neither is detected by Home Assistant. While in the official documentation it appears that Chipolo One Spot is compatible. Is it a documentation error? Does anyone have any news? HassOS , Raspberry pi 4 , bluetooth integrated, cheers.

dersch81 commented 1 year ago

I have ordered this device https://de.aliexpress.com/item/1005004651009865.html?spm=a2g0o.order_list.order_list_main.69.d0e95c5fQQLMZ7&gatewayAdapt=glo2deu

But it is not detected by HASS. But NRF52810 is listed as supported.

This device https://de.aliexpress.com/item/1005003744908346.html?spm=a2g0o.order_list.order_list_main.70.d0e95c5fQQLMZ7&gatewayAdapt=glo2deu is NRF51822 and detected automatically.

olo81 commented 1 year ago

I also cannot detect the NRF52810 chip

wastez commented 1 year ago

Does anybody try Passive BLE monitor from HACS with Chipolo one? Maybe this will work better.

Sorry for the off-topic comment.

@Fonsohome You have to configure the device in Passive BLE monitor for tracking. Did you do that?

Loic691 commented 1 year ago

Hi I have several Nut devices. One is discovered but others not. I checked with an android app and they are online. (I used them before with Jeedom BLEA plugin). Is nut (nutale ?) compatible ?

cipnt commented 1 year ago

In my testing on the a RPi4 using the onboard BT, the Chipolo One Spot does not work with the iBeacon integration

wastez commented 1 year ago

Just to inform you all. With ble monitor and chipolo one (not spot) everything is working, even tracking. (My dog is now smart home automated)

cipnt commented 1 year ago

Hey @wastez please make a post with more details on how you got it working on the community. My testing of bluetooth_le_tracker with Chipolo One and One Spot got me nowhere and only managed to acquire a couple of thousands random entries in known_devices.yaml since all these BLE devices constantly change mac address. As far as I could tell, nothing useful could be done with this. Thanks

wastez commented 1 year ago

@cipnt That's the reason why I use ble monitor because it can handle iBeacon devices, even if the MAC address changes the beacon uuid is the same. I installed ble monitor via hacs. If you need additional informations just contact me over this thread.

danielduerr commented 1 year ago

@wastez I'm super interested in learning more about your ble monitor install via HACS. I'm tired of having to constantly babysit this iBeacon integration. Also, does your ble monitor still work with/benefit from the Bluetooth Proxy devices?

wastez commented 1 year ago

@danielduerr If you mean esp32 bt proxy it is not working because this is made to send the data on the internal bt integration. But as I read you can use esp32 bt gateway for this. But this is all described on their site: https://github.com/custom-components/ble_monitor

danielduerr commented 1 year ago

Thank you @wastez -- nice to know another option exists.

cipnt commented 1 year ago

I can't get Passive BLE monitor to detect any of my Chipolo One Spot, but it detects other iBeacons which are already detected by the official iBeacon tracker Unfortunately I returned the Chipolo One (non Spot) so cannot test that one