Add Deconz support for Zigbee green power devices like Hue Tap (#11455)

* Add support for Zigbee green power devices such as the Hue Tap

* Clarify that imported SWITCH is a DECONZ_REMOTE
This commit is contained in:
Kane610 2018-01-15 10:47:55 +01:00 committed by Martin Hjelmare
parent f86b645417
commit 3979387c80
3 changed files with 4 additions and 5 deletions

View file

@ -17,7 +17,7 @@ from homeassistant.helpers import discovery
from homeassistant.helpers.aiohttp_client import async_get_clientsession
from homeassistant.util.json import load_json, save_json
REQUIREMENTS = ['pydeconz==23']
REQUIREMENTS = ['pydeconz==24']
_LOGGER = logging.getLogger(__name__)

View file

@ -17,7 +17,6 @@ from homeassistant.util import slugify
DEPENDENCIES = ['deconz']
ATTR_EVENT_ID = 'event_id'
ATTR_ZHASWITCH = 'ZHASwitch'
@asyncio.coroutine
@ -26,13 +25,13 @@ def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
if discovery_info is None:
return
from pydeconz.sensor import DECONZ_SENSOR
from pydeconz.sensor import DECONZ_SENSOR, SWITCH as DECONZ_REMOTE
sensors = hass.data[DECONZ_DATA].sensors
entities = []
for sensor in sensors.values():
if sensor.type in DECONZ_SENSOR:
if sensor.type == ATTR_ZHASWITCH:
if sensor.type in DECONZ_REMOTE:
DeconzEvent(hass, sensor)
if sensor.battery:
entities.append(DeconzBattery(sensor))

View file

@ -678,7 +678,7 @@ pycsspeechtts==1.0.2
pydaikin==0.4
# homeassistant.components.deconz
pydeconz==23
pydeconz==24
# homeassistant.components.zwave
pydispatcher==2.0.5