2022-02-05 00:20:21 +00:00
|
|
|
"""Constants for the WiZ Platform integration."""
|
2022-02-05 16:36:44 +00:00
|
|
|
from datetime import timedelta
|
|
|
|
|
2022-02-12 02:42:41 +00:00
|
|
|
from pywizlight.exceptions import (
|
|
|
|
WizLightConnectionError,
|
|
|
|
WizLightNotKnownBulb,
|
|
|
|
WizLightTimeOutError,
|
|
|
|
)
|
2022-02-05 00:20:21 +00:00
|
|
|
|
|
|
|
DOMAIN = "wiz"
|
|
|
|
DEFAULT_NAME = "WiZ"
|
2022-02-05 15:23:19 +00:00
|
|
|
|
2022-02-05 16:36:44 +00:00
|
|
|
DISCOVER_SCAN_TIMEOUT = 10
|
|
|
|
DISCOVERY_INTERVAL = timedelta(minutes=15)
|
|
|
|
|
2022-02-05 15:23:19 +00:00
|
|
|
WIZ_EXCEPTIONS = (
|
|
|
|
OSError,
|
|
|
|
WizLightTimeOutError,
|
|
|
|
TimeoutError,
|
|
|
|
WizLightConnectionError,
|
|
|
|
ConnectionRefusedError,
|
|
|
|
)
|
2022-02-12 02:42:41 +00:00
|
|
|
WIZ_CONNECT_EXCEPTIONS = (WizLightNotKnownBulb, *WIZ_EXCEPTIONS)
|
2022-02-14 13:25:15 +00:00
|
|
|
|
|
|
|
SIGNAL_WIZ_PIR = "wiz_pir_{}"
|