Device Registry (#15980)
* First draft * Generate device id * No obscure registry * Dont store config_entry_id in device * Storage * Small mistake on rebase * Do storage more like entity registry * Improve device identification * Add tests * Remove deconz device support from PR * Fix hound comments, voff! * Fix comments and clean up * Fix proper indentation * Fix pydoc issues * Fix mochad component to not use self.device * Fix mochad light platform to not use self.device * Fix TankUtilitySensor to not use self.device * Fix Soundtouch to not use self.device * Fix Plex to not use self.device * Fix Emby to not use self.device * Fix Heatmiser to not use self.device * Fix Wemo lights to not use self.device * Fix Lifx to not use self.device * Fix Radiotherm to not use self.device * Fix Juicenet to not use self.device * Fix Qwikswitch to not use self.device * Fix Xiaomi miio to not use self.device * Fix Nest to not use self.device * Fix Tellduslive to not use self.device * Fix Knx to not use self.device * Clean up a small mistake in soundtouch * Fix comment from Ballob * Fix bad indentation * Fix indentatin * Lint * Remove unused variable * Lint
This commit is contained in:
parent
7e7f9bc6ac
commit
0009be595c
40 changed files with 538 additions and 331 deletions
|
@ -187,11 +187,6 @@ class XiaomiMiioRemote(RemoteDevice):
|
|||
"""Return the name of the remote."""
|
||||
return self._name
|
||||
|
||||
@property
|
||||
def device(self):
|
||||
"""Return the remote object."""
|
||||
return self._device
|
||||
|
||||
@property
|
||||
def hidden(self):
|
||||
"""Return if we should hide entity."""
|
||||
|
@ -212,7 +207,7 @@ class XiaomiMiioRemote(RemoteDevice):
|
|||
"""Return False if device is unreachable, else True."""
|
||||
from miio import DeviceException
|
||||
try:
|
||||
self.device.info()
|
||||
self._device.info()
|
||||
return True
|
||||
except DeviceException:
|
||||
return False
|
||||
|
@ -247,7 +242,7 @@ class XiaomiMiioRemote(RemoteDevice):
|
|||
|
||||
_LOGGER.debug("Sending payload: '%s'", payload)
|
||||
try:
|
||||
self.device.play(payload)
|
||||
self._device.play(payload)
|
||||
except DeviceException as ex:
|
||||
_LOGGER.error(
|
||||
"Transmit of IR command failed, %s, exception: %s",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue