-
-
Notifications
You must be signed in to change notification settings - Fork 37.4k
Add cover platform to Dynalite #32594
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
Merged
Merged
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
89f5ca9
lib version
ziv1234 55a7b4b
unit-test refactoring
ziv1234 e6503dd
added type hints
ziv1234 2dcbc13
added cover
ziv1234 18b9d9f
added test to see that consts have the same value as library consts
ziv1234 5350ce8
Update tests/components/dynalite/test_init.py
ziv1234 baaeace
removed trigger template
ziv1234 c3b570a
Update homeassistant/components/dynalite/__init__.py
ziv1234 d613606
Update homeassistant/components/dynalite/const.py
ziv1234 5430cc7
removed CONF_TRIGGER from const
ziv1234 a8fbce9
Merge branch 'dynalite_cover2' of https://github.com/ziv1234/home-ass…
ziv1234 d158be3
conversion of the config to library CONFs
ziv1234 17d3a89
moved to use the value since it should come from the library
ziv1234 77dbc04
taking CONF_HOST from homeassistant.const instead of module const
ziv1234 fed451d
use dict.get
ziv1234 989d96b
force device_class to be from homeassistant consts
ziv1234 d9b0bac
move dict.get to inline
ziv1234 d33df14
removed CONF from values
ziv1234 1033851
moved some CONF values out of const.py and taking them from homeassis…
ziv1234 fe361eb
verifying that device class is a valid HA device class
ziv1234 ad907e7
moved shutter to home assistant const
ziv1234 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,31 +1,54 @@ | ||
| """Constants for the Dynalite component.""" | ||
| import logging | ||
|
|
||
| from homeassistant.components.cover import DEVICE_CLASS_SHUTTER | ||
| from homeassistant.const import CONF_ROOM | ||
|
|
||
| LOGGER = logging.getLogger(__package__) | ||
| DOMAIN = "dynalite" | ||
|
|
||
| ENTITY_PLATFORMS = ["light", "switch"] | ||
| ENTITY_PLATFORMS = ["light", "switch", "cover"] | ||
|
|
||
|
|
||
| CONF_ACTIVE = "active" | ||
| CONF_ACTIVE_INIT = "init" | ||
| CONF_ACTIVE_OFF = "off" | ||
| CONF_ACTIVE_ON = "on" | ||
| ACTIVE_INIT = "init" | ||
| ACTIVE_OFF = "off" | ||
| ACTIVE_ON = "on" | ||
| CONF_ALL = "ALL" | ||
| CONF_AREA = "area" | ||
| CONF_AUTO_DISCOVER = "autodiscover" | ||
| CONF_BRIDGES = "bridges" | ||
| CONF_CHANNEL = "channel" | ||
| CONF_CHANNEL_TYPE = "type" | ||
| CONF_CHANNEL_COVER = "channel_cover" | ||
| CONF_CLOSE_PRESET = "close" | ||
| CONF_DEFAULT = "default" | ||
| CONF_DEVICE_CLASS = "class" | ||
| CONF_DURATION = "duration" | ||
| CONF_FADE = "fade" | ||
| CONF_HOST = "host" | ||
| CONF_NAME = "name" | ||
| CONF_NO_DEFAULT = "nodefault" | ||
| CONF_POLLTIMER = "polltimer" | ||
| CONF_PORT = "port" | ||
| CONF_OPEN_PRESET = "open" | ||
| CONF_POLL_TIMER = "polltimer" | ||
| CONF_PRESET = "preset" | ||
| CONF_ROOM_OFF = "room_off" | ||
| CONF_ROOM_ON = "room_on" | ||
| CONF_STOP_PRESET = "stop" | ||
| CONF_TEMPLATE = "template" | ||
| CONF_TILT_TIME = "tilt" | ||
| CONF_TIME_COVER = "time_cover" | ||
|
|
||
| DEFAULT_CHANNEL_TYPE = "light" | ||
| DEFAULT_COVER_CLASS = DEVICE_CLASS_SHUTTER | ||
| DEFAULT_NAME = "dynalite" | ||
| DEFAULT_PORT = 12345 | ||
| DEFAULT_TEMPLATES = { | ||
| CONF_ROOM: [CONF_ROOM_ON, CONF_ROOM_OFF], | ||
|
MartinHjelmare marked this conversation as resolved.
|
||
| CONF_TIME_COVER: [ | ||
| CONF_CHANNEL_COVER, | ||
| CONF_DEVICE_CLASS, | ||
| CONF_OPEN_PRESET, | ||
| CONF_CLOSE_PRESET, | ||
| CONF_STOP_PRESET, | ||
| CONF_DURATION, | ||
| CONF_TILT_TIME, | ||
| ], | ||
| } | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.