mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
patch stop command (#11612)
This commit is contained in:
parent
37427d052e
commit
5e81736f88
@ -15,11 +15,6 @@ DEPENDENCIES = ['tahoma']
|
|||||||
|
|
||||||
_LOGGER = logging.getLogger(__name__)
|
_LOGGER = logging.getLogger(__name__)
|
||||||
|
|
||||||
TAHOMA_STOP_COMMAND = {
|
|
||||||
'io:RollerShutterWithLowSpeedManagementIOComponent': 'my',
|
|
||||||
'io:RollerShutterVeluxIOComponent': 'my',
|
|
||||||
}
|
|
||||||
|
|
||||||
SCAN_INTERVAL = timedelta(seconds=60)
|
SCAN_INTERVAL = timedelta(seconds=60)
|
||||||
|
|
||||||
|
|
||||||
@ -78,8 +73,11 @@ class TahomaCover(TahomaDevice, CoverDevice):
|
|||||||
|
|
||||||
def stop_cover(self, **kwargs):
|
def stop_cover(self, **kwargs):
|
||||||
"""Stop the cover."""
|
"""Stop the cover."""
|
||||||
self.apply_action(TAHOMA_STOP_COMMAND.get(self.tahoma_device.type,
|
if self.tahoma_device.type == \
|
||||||
'stopIdentify'))
|
'io:RollerShutterWithLowSpeedManagementIOComponent':
|
||||||
|
self.apply_action('setPosition', 'secured')
|
||||||
|
else:
|
||||||
|
self.apply_action('stopIdentify')
|
||||||
|
|
||||||
def device_class(self):
|
def device_class(self):
|
||||||
"""Return the class of this device, from component DEVICE_CLASSES."""
|
"""Return the class of this device, from component DEVICE_CLASSES."""
|
||||||
|
Loading…
x
Reference in New Issue
Block a user