Add some new model names of Xiaomi Aqara devices (#17234)

* Add additional model name of the Xiaomi Aqara Button (WXKG11LM)

* Add additional model name of the Xiaomi Aqara Wireless Switch (WXKG02LM, WXKG03LM)

* Bump PyXiaomiGateway version
This commit is contained in:
Sebastian Muszynski 2018-10-08 09:32:01 +02:00 committed by Paulus Schoutsen
parent 4b7f85518f
commit 315f83e1ea
3 changed files with 8 additions and 5 deletions

View file

@ -36,21 +36,24 @@ def setup_platform(hass, config, add_entities, discovery_info=None):
elif model in ['natgas', 'sensor_natgas']:
devices.append(XiaomiNatgasSensor(device, gateway))
elif model in ['switch', 'sensor_switch',
'sensor_switch.aq2', 'sensor_switch.aq3']:
'sensor_switch.aq2', 'sensor_switch.aq3',
'remote.b1acn01']:
if 'proto' not in device or int(device['proto'][0:1]) == 1:
data_key = 'status'
else:
data_key = 'button_0'
devices.append(XiaomiButton(device, 'Switch', data_key,
hass, gateway))
elif model in ['86sw1', 'sensor_86sw1', 'sensor_86sw1.aq1']:
elif model in ['86sw1', 'sensor_86sw1', 'sensor_86sw1.aq1',
'remote.b186acn01']:
if 'proto' not in device or int(device['proto'][0:1]) == 1:
data_key = 'channel_0'
else:
data_key = 'button_0'
devices.append(XiaomiButton(device, 'Wall Switch', data_key,
hass, gateway))
elif model in ['86sw2', 'sensor_86sw2', 'sensor_86sw2.aq1']:
elif model in ['86sw2', 'sensor_86sw2', 'sensor_86sw2.aq1',
'remote.b286acn01']:
if 'proto' not in device or int(device['proto'][0:1]) == 1:
data_key_left = 'channel_0'
data_key_right = 'channel_1'

View file

@ -22,7 +22,7 @@ from homeassistant.helpers.event import async_track_point_in_utc_time
from homeassistant.util.dt import utcnow
from homeassistant.util import slugify
REQUIREMENTS = ['PyXiaomiGateway==0.11.0']
REQUIREMENTS = ['PyXiaomiGateway==0.11.1']
_LOGGER = logging.getLogger(__name__)

View file

@ -58,7 +58,7 @@ PyRMVtransport==0.1
PySwitchbot==0.3
# homeassistant.components.xiaomi_aqara
PyXiaomiGateway==0.11.0
PyXiaomiGateway==0.11.1
# homeassistant.components.rpi_gpio
# RPi.GPIO==0.6.1