Make mysensors component async (#13641)
* Make mysensors component async * Use async dispatcher and discovery. * Run I/O in executor. * Make mysensors actuator methods async. * Upgrade pymysensors to 0.13.0. * Use async serial gateway. * Use async TCP gateway. * Use async mqtt gateway. * Start gateway before hass start event * Make sure gateway is started after discovery of persistent devices and after corresponding platforms have been loaded. * Don't wait to start gateway until after hass start. * Bump pymysensors to 0.14.0
This commit is contained in:
parent
ef8fc1f201
commit
be3b227a87
7 changed files with 110 additions and 80 deletions
|
@ -42,7 +42,7 @@ class MySensorsNotificationService(BaseNotificationService):
|
|||
"""Initialize the service."""
|
||||
self.devices = mysensors.get_mysensors_devices(hass, DOMAIN)
|
||||
|
||||
def send_message(self, message="", **kwargs):
|
||||
async def async_send_message(self, message="", **kwargs):
|
||||
"""Send a message to a user."""
|
||||
target_devices = kwargs.get(ATTR_TARGET)
|
||||
devices = [device for device in self.devices.values()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue