Skip to content
Snippets Groups Projects
Commit c64bca19 authored by jkerdreu's avatar jkerdreu
Browse files

Summary: Added support for new devices..

git-svn-id: https://redmine.imt-atlantique.fr/svn/xaal/code/Python/trunk@2158 b32b6428-25c9-4566-ad07-03861ab6144f
parent 1427ff3a
Branches
No related tags found
No related merge requests found
......@@ -106,6 +106,7 @@ class Motion(AqaraDev):
self.devices.append(devices.motion(self.base_addr+'00'))
def on_report(self,data):
print(data)
val = data.get('status',None)
if val and val == 'motion':
self.devices[0].attributes['presence'] = True
......@@ -243,4 +244,4 @@ class Gateway(AqaraDev):
if rgb:
rgb = int(rgb)
if rgb != 0:
self.rgb = rgb
\ No newline at end of file
self.rgb = rgb
......@@ -15,7 +15,7 @@ logger = logging.getLogger(PACKAGE_NAME)
def find_device_class(model):
if model in ['sensor_switch.aq3','sensor_switch.aq2','switch','86sw1']:
return devices.Switch
if model == '86sw2':
if model in ['86sw2','remote.b286acn01']:
return devices.Switch86sw2
if model == 'gateway':
return devices.Gateway
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment