Skip to content

Commit

Permalink
Add Spotlight mode 'On at night'
Browse files Browse the repository at this point in the history
  • Loading branch information
starkillerOG committed Sep 13, 2023
1 parent e935271 commit 99b3e7b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions reolink_aio/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -625,6 +625,8 @@ def whiteled_mode(self, channel: int) -> Optional[int]:

def whiteled_mode_list(self, channel: int) -> list[str]:
mode_values = [SpotlightModeEnum.off, SpotlightModeEnum.auto, SpotlightModeEnum.schedule]
if self.api_version("supportFLKeepOn", channel) > 0:
mode_values.extend([SpotlightModeEnum.onatnight])
if self.api_version("supportLightAutoBrightness", channel) > 0:
mode_values.extend([SpotlightModeEnum.adaptive, SpotlightModeEnum.autoadaptive])
return [val.name for val in mode_values]
Expand Down
1 change: 1 addition & 0 deletions reolink_aio/enums.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class SpotlightModeEnum(Enum):

off = 0
auto = 1
onatnight = 2
schedule = 3
adaptive = 5
autoadaptive = 4
Expand Down

0 comments on commit 99b3e7b

Please sign in to comment.