mirror of
https://github.com/home-assistant/core.git
synced 2025-07-17 10:17:09 +00:00
Insteon lib (#6505)
* use lib with caching to reduce collisions * use 0.43 * change requirements * update the lib to 0.44 * update req * fix typo * just keep checking * just keep checking - switch * use 0.45 with file cache * requirements * Update requirements_all.txt * Update insteon_local.py * Update requirements_all.txt * Update insteon_local.py * update library * fix lint
This commit is contained in:
parent
49308bec13
commit
330d352d3a
@ -13,7 +13,7 @@ from homeassistant.const import (
|
|||||||
CONF_PASSWORD, CONF_USERNAME, CONF_HOST, CONF_PORT, CONF_TIMEOUT)
|
CONF_PASSWORD, CONF_USERNAME, CONF_HOST, CONF_PORT, CONF_TIMEOUT)
|
||||||
import homeassistant.helpers.config_validation as cv
|
import homeassistant.helpers.config_validation as cv
|
||||||
|
|
||||||
REQUIREMENTS = ['insteonlocal==0.39']
|
REQUIREMENTS = ['insteonlocal==0.48']
|
||||||
|
|
||||||
_LOGGER = logging.getLogger(__name__)
|
_LOGGER = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
@ -152,6 +152,10 @@ class InsteonLocalDimmerDevice(Light):
|
|||||||
def update(self):
|
def update(self):
|
||||||
"""Update state of the light."""
|
"""Update state of the light."""
|
||||||
resp = self.node.status(0)
|
resp = self.node.status(0)
|
||||||
|
|
||||||
|
while 'error' in resp and resp['error'] is True:
|
||||||
|
resp = self.node.status(0)
|
||||||
|
|
||||||
if 'cmd2' in resp:
|
if 'cmd2' in resp:
|
||||||
self._value = int(resp['cmd2'], 16)
|
self._value = int(resp['cmd2'], 16)
|
||||||
|
|
||||||
|
@ -143,6 +143,10 @@ class InsteonLocalSwitchDevice(SwitchDevice):
|
|||||||
def update(self):
|
def update(self):
|
||||||
"""Get the updated status of the switch."""
|
"""Get the updated status of the switch."""
|
||||||
resp = self.node.status(0)
|
resp = self.node.status(0)
|
||||||
|
|
||||||
|
while 'error' in resp and resp['error'] is True:
|
||||||
|
resp = self.node.status(0)
|
||||||
|
|
||||||
if 'cmd2' in resp:
|
if 'cmd2' in resp:
|
||||||
self._state = int(resp['cmd2'], 16) > 0
|
self._state = int(resp['cmd2'], 16) > 0
|
||||||
|
|
||||||
|
@ -310,7 +310,7 @@ influxdb==3.0.0
|
|||||||
insteon_hub==0.4.5
|
insteon_hub==0.4.5
|
||||||
|
|
||||||
# homeassistant.components.insteon_local
|
# homeassistant.components.insteon_local
|
||||||
insteonlocal==0.39
|
insteonlocal==0.48
|
||||||
|
|
||||||
# homeassistant.components.insteon_plm
|
# homeassistant.components.insteon_plm
|
||||||
insteonplm==0.7.4
|
insteonplm==0.7.4
|
||||||
|
Loading…
x
Reference in New Issue
Block a user