diff --git a/homeassistant/components/reolink/icons.json b/homeassistant/components/reolink/icons.json index 4fbc8e82ae3aca..cee044189ea168 100644 --- a/homeassistant/components/reolink/icons.json +++ b/homeassistant/components/reolink/icons.json @@ -222,6 +222,9 @@ "hdr": { "default": "mdi:hdr" }, + "binning_mode": { + "default": "mdi:code-block-brackets" + }, "hub_alarm_ringtone": { "default": "mdi:music-note", "state": { diff --git a/homeassistant/components/reolink/select.py b/homeassistant/components/reolink/select.py index f1147c503288fa..8625f7fb60013b 100644 --- a/homeassistant/components/reolink/select.py +++ b/homeassistant/components/reolink/select.py @@ -8,6 +8,7 @@ from typing import Any from reolink_aio.api import ( + BinningModeEnum, Chime, ChimeToneEnum, DayNightEnum, @@ -175,6 +176,19 @@ def _get_quick_reply_id(api: Host, ch: int, mess: str) -> int: value=lambda api, ch: HDREnum(api.HDR_state(ch)).name, method=lambda api, ch, name: api.set_HDR(ch, HDREnum[name].value), ), + ReolinkSelectEntityDescription( + key="binning_mode", + cmd_key="GetIsp", + translation_key="binning_mode", + entity_category=EntityCategory.CONFIG, + entity_registry_enabled_default=False, + get_options=[method.name for method in BinningModeEnum], + supported=lambda api, ch: api.supported(ch, "binning_mode"), + value=lambda api, ch: BinningModeEnum(api.binning_mode(ch)).name, + method=lambda api, ch, name: api.set_binning_mode( + ch, BinningModeEnum[name].value + ), + ), ReolinkSelectEntityDescription( key="main_frame_rate", cmd_key="GetEnc", diff --git a/homeassistant/components/reolink/strings.json b/homeassistant/components/reolink/strings.json index 5e885d9ac77542..3fe7fe14ec5fb5 100644 --- a/homeassistant/components/reolink/strings.json +++ b/homeassistant/components/reolink/strings.json @@ -490,7 +490,7 @@ "name": "Floodlight mode", "state": { "off": "[%key:common::state::off%]", - "auto": "Auto", + "auto": "[%key:component::reolink::entity::select::day_night_mode::state::auto%]", "onatnight": "On at night", "schedule": "Schedule", "adaptive": "Adaptive", @@ -529,7 +529,7 @@ "name": "Doorbell LED", "state": { "stayoff": "Stay off", - "auto": "Auto", + "auto": "[%key:component::reolink::entity::select::day_night_mode::state::auto%]", "alwaysonatnight": "Auto & always on at night", "alwayson": "Always on" } @@ -539,7 +539,15 @@ "state": { "off": "[%key:common::state::off%]", "on": "[%key:common::state::on%]", - "auto": "Auto" + "auto": "[%key:component::reolink::entity::select::day_night_mode::state::auto%]" + } + }, + "binning_mode": { + "name": "Binning mode", + "state": { + "off": "[%key:common::state::off%]", + "on": "[%key:common::state::on%]", + "auto": "[%key:component::reolink::entity::select::day_night_mode::state::auto%]" } }, "hub_alarm_ringtone": {