From 8ab59bee47b1f6596644a7319e6b914cf40fe282 Mon Sep 17 00:00:00 2001 From: zry98 Date: Sun, 13 Apr 2025 22:41:43 +0200 Subject: [PATCH] [xiaomi_ble] Support Body Composition Scale S400 (#142705) --- homeassistant/components/xiaomi_ble/sensor.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/homeassistant/components/xiaomi_ble/sensor.py b/homeassistant/components/xiaomi_ble/sensor.py index 57dfaead232..0fcae1925bb 100644 --- a/homeassistant/components/xiaomi_ble/sensor.py +++ b/homeassistant/components/xiaomi_ble/sensor.py @@ -177,6 +177,25 @@ SENSOR_DESCRIPTIONS = { native_unit_of_measurement=UnitOfTime.MINUTES, state_class=SensorStateClass.MEASUREMENT, ), + # Low frequency impedance sensor (ohm) + (ExtendedSensorDeviceClass.IMPEDANCE_LOW, Units.OHM): SensorEntityDescription( + key=str(ExtendedSensorDeviceClass.IMPEDANCE_LOW), + native_unit_of_measurement=Units.OHM, + state_class=SensorStateClass.MEASUREMENT, + icon="mdi:omega", + ), + # Heart rate sensor (bpm) + (ExtendedSensorDeviceClass.HEART_RATE, "bpm"): SensorEntityDescription( + key=str(ExtendedSensorDeviceClass.HEART_RATE), + native_unit_of_measurement="bpm", + state_class=SensorStateClass.MEASUREMENT, + icon="mdi:heart-pulse", + ), + # User profile ID sensor + (ExtendedSensorDeviceClass.PROFILE_ID, None): SensorEntityDescription( + key=str(ExtendedSensorDeviceClass.PROFILE_ID), + icon="mdi:identifier", + ), }