-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add option to force on flood light for light devices #154
base: main
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -171,6 +171,14 @@ | |
self.camera_id = camera.id | ||
await self.save_device(data_before_changes, force_emit=True) | ||
|
||
async def set_flood_light(self, enabled: bool) -> None: | ||
"""Sets the flood light (force on) for the light""" | ||
|
||
def callback() -> None: | ||
self.light_on_settings.is_led_force_on = enabled | ||
|
||
await self.queue_update(callback) | ||
Comment on lines
+174
to
+180
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Reminder: Add tests. The new method Do you want me to generate the unit testing code or open a GitHub issue to track this task? ToolsGitHub Check: codecov/patch
|
||
|
||
async def set_status_light(self, enabled: bool) -> None: | ||
"""Sets the status indicator light for the light""" | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reminder: Add tests.
The new function
set_flood_light
lacks unit tests.Do you want me to generate the unit testing code or open a GitHub issue to track this task?