Hello.
Im trying to add some miflora sensors, but in the configuration i need the MAC address.
Anyone know what command i shall use to start a BLE scan in hass.io?
I was able to connect to the Mi Flora using the Bluetooth on my phone, and pulled the MAC address from that.
I also recommend use phone to get mac address. It is much easier.
What app on an iphone can I used to pull the mac address?
I used Bluetooth Discovery by Manjul Saini. Found the mac address within 30 seconds. I think MiFloras all start with C4:
Thank you
This was a very old post. Home assistant autodiscovers Xiaomi plant sensors if bluetooth is enabled and the device is in range of HA.
If it is too far removed, use an ESP32 with ESPHome on it. Up until the last release that did require you to scan for the mac. But as of this lovely 2022.9 release, I recommend you use the Bluetooth proxy feature. The esp will then relay the bluetooth data over wifi to HA, so it can again autodiscover your Xiaomi plant sensors.
hello, my, you are sent from heaven to me… thanks for wanting to help me… yes, xiaomi (ie HA) really finds the sensor if it is at most 2m away from pi, but that’s my problem … 10 sensors, in 4 different rooms and also on the terrace, on 3 floors…
I also found the solution mentioned (“Bluetooth Extender”) but I have no idea what to write there(?) same as in “BLE-Tracker”? There have been such stupid examples on github lately that I can’t do anything with ("Light switch via Bluetooth is an example… I really wonder who came up with the idea and for what purpose? Telephone operation? Why do you have Google? or Xiri?)
I would like to ask you to help me with this “Blutooth solution”…
At the moment I tried “BLE-Tracker”, it works somehow… BUT(!)
the one Xiaomi, with which I actually started my experiment and integrated it into HA, is not displayed by the tracker and because it is probably too far, does not deliver any values ​​in HA… When I go to the window, I see it on the phone in Android App…
Do I have to uninstall this sensor in HA to make it work with “bluetooth tracker” (or wait, with this “extender”)?
I read out all the MAC addresses (HandyApp)
could you please support me
What you need is an esp32 device and the EspHome integration in Home Assistant. The esp32 has bluetooth and is placed close to the plant sensor. It also has wifi to connect to HA. Thus is acts as a bluetooth “extender”. What is installed on the esp32 is a bluetooth low energy tracker integration to listen to the plant sensor, and a bluetooth proxy to send its information to HA.
The functionality is new in 2022.9 - you can find more information here, together with example yaml files to install on the esp32:
If the plant sensor is still present in Home assistant (but unavailable) it will start working again as soon as the esp32 is transmitting the messages from afar. If the device is new, it will be autodiscovered. One esp32 can serve all plants withing bluetooth range. So you’ll probably need one per room. I’d buy one first to see how many plant sensors it finds, and add more when you have it working.
Oh - if you have ignored (hidden) the plant sensors in HA from earlier attempts, make sure to unhide them. That fooled me for a while.
Hello, thank you for your support.
I have some ESP32 lying around, that wouldn’t be a problem… But my problem is this… I don’t understand what I have to do… In ESPHome, and in Home Assistant…
I once tried 3 sensors… (also because of the range of Pi) ESP32 “sees” all 3, but under Xiaomi not all 3 are displayed because one is still in HA integration (without values, entities have no values) Must I delete this one from HA so that these are also recorded via ESP32?
And how am I supposed to continue here?
I’m not sure if a sensor found by HA itself must be deleted to be found through the proxy. But I would not be surprised if that is the case. Usually it issn’t a big deal to delete it and have it rediscovered, as long as you make sure the entities have the same id afterward.