mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 21:27:38 +00:00
Mark Ring battery and signal strength sensors as diagnostic (#107503)
This commit is contained in:
parent
810c6ea5ae
commit
426a1511d5
@ -10,7 +10,11 @@ from homeassistant.components.sensor import (
|
|||||||
SensorEntityDescription,
|
SensorEntityDescription,
|
||||||
)
|
)
|
||||||
from homeassistant.config_entries import ConfigEntry
|
from homeassistant.config_entries import ConfigEntry
|
||||||
from homeassistant.const import PERCENTAGE, SIGNAL_STRENGTH_DECIBELS_MILLIWATT
|
from homeassistant.const import (
|
||||||
|
PERCENTAGE,
|
||||||
|
SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
|
||||||
|
EntityCategory,
|
||||||
|
)
|
||||||
from homeassistant.core import HomeAssistant, callback
|
from homeassistant.core import HomeAssistant, callback
|
||||||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||||
|
|
||||||
@ -194,6 +198,7 @@ SENSOR_TYPES: tuple[RingSensorEntityDescription, ...] = (
|
|||||||
category=["doorbots", "authorized_doorbots", "stickup_cams"],
|
category=["doorbots", "authorized_doorbots", "stickup_cams"],
|
||||||
native_unit_of_measurement=PERCENTAGE,
|
native_unit_of_measurement=PERCENTAGE,
|
||||||
device_class=SensorDeviceClass.BATTERY,
|
device_class=SensorDeviceClass.BATTERY,
|
||||||
|
entity_category=EntityCategory.DIAGNOSTIC,
|
||||||
cls=RingSensor,
|
cls=RingSensor,
|
||||||
),
|
),
|
||||||
RingSensorEntityDescription(
|
RingSensorEntityDescription(
|
||||||
@ -234,6 +239,7 @@ SENSOR_TYPES: tuple[RingSensorEntityDescription, ...] = (
|
|||||||
translation_key="wifi_signal_category",
|
translation_key="wifi_signal_category",
|
||||||
category=["chimes", "doorbots", "authorized_doorbots", "stickup_cams"],
|
category=["chimes", "doorbots", "authorized_doorbots", "stickup_cams"],
|
||||||
icon="mdi:wifi",
|
icon="mdi:wifi",
|
||||||
|
entity_category=EntityCategory.DIAGNOSTIC,
|
||||||
cls=HealthDataRingSensor,
|
cls=HealthDataRingSensor,
|
||||||
),
|
),
|
||||||
RingSensorEntityDescription(
|
RingSensorEntityDescription(
|
||||||
@ -243,6 +249,7 @@ SENSOR_TYPES: tuple[RingSensorEntityDescription, ...] = (
|
|||||||
native_unit_of_measurement=SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
|
native_unit_of_measurement=SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
|
||||||
icon="mdi:wifi",
|
icon="mdi:wifi",
|
||||||
device_class=SensorDeviceClass.SIGNAL_STRENGTH,
|
device_class=SensorDeviceClass.SIGNAL_STRENGTH,
|
||||||
|
entity_category=EntityCategory.DIAGNOSTIC,
|
||||||
cls=HealthDataRingSensor,
|
cls=HealthDataRingSensor,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user