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:
parent
4b7f85518f
commit
315f83e1ea
3 changed files with 8 additions and 5 deletions
|
@ -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'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue