patch stop command (#11612)
This commit is contained in:
parent
7a50450b92
commit
d88edb0661
1 changed files with 5 additions and 7 deletions
|
@ -15,11 +15,6 @@ DEPENDENCIES = ['tahoma']
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
TAHOMA_STOP_COMMAND = {
|
||||
'io:RollerShutterWithLowSpeedManagementIOComponent': 'my',
|
||||
'io:RollerShutterVeluxIOComponent': 'my',
|
||||
}
|
||||
|
||||
SCAN_INTERVAL = timedelta(seconds=60)
|
||||
|
||||
|
||||
|
@ -78,8 +73,11 @@ class TahomaCover(TahomaDevice, CoverDevice):
|
|||
|
||||
def stop_cover(self, **kwargs):
|
||||
"""Stop the cover."""
|
||||
self.apply_action(TAHOMA_STOP_COMMAND.get(self.tahoma_device.type,
|
||||
'stopIdentify'))
|
||||
if self.tahoma_device.type == \
|
||||
'io:RollerShutterWithLowSpeedManagementIOComponent':
|
||||
self.apply_action('setPosition', 'secured')
|
||||
else:
|
||||
self.apply_action('stopIdentify')
|
||||
|
||||
def device_class(self):
|
||||
"""Return the class of this device, from component DEVICE_CLASSES."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue