lolouk44 / xiaomi_mi_scale

Connector for Xiaomi Mi Scale
MIT License
325 stars 69 forks source link

Use with Bidge ESP32 and ESPHome #50

Closed mcgnai closed 2 years ago

mcgnai commented 2 years ago

I would like to ask for an aid to be able to use this project by integrating it with a bridge made with an ESP32 and connected with Home assistant via ESPHome. it's possible?

lolouk44 commented 2 years ago

Thanks for your interest. An official ESPHome integration already exists: https://esphome.io/components/sensor/xiaomi_miscale.html

mcgnai commented 2 years ago

Thanks for the answer, I have already seen the official integration of ESPHome but you can only extract two values ​​(weight and impedance) while with your integration it is possible to extract many more values ​​(BMI, water, visceral fat, etc.). I thought you could change the parameters of HCI_DEV (Bluetooth Device) which is set to hci0 in your package and replace it with the ble_client component used by ESPHome. do you think it is possible?

lolouk44 commented 2 years ago

I thought you could change the parameters of HCI_DEV (Bluetooth Device) which is set to hci0 in your package and replace it with the ble_client component used by ESPHome. do you think it is possible?

no that wouln't work. My code is based on a docker container running linux, HCI0 is location of the Bluetooth radio on a Linux system. ESPHome is based on a completely different base/OS.

Check this out instead: https://github.com/dckiller51/bodymiscale