mirror of
https://github.com/andvikt/mega_hacs.git
synced 2025-12-12 01:24:29 +05:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
768d46d952 | ||
|
|
359c6b99b7 |
@@ -72,6 +72,7 @@ async def async_setup_entry(hass: HomeAssistant, config_entry: ConfigEntry, asyn
|
|||||||
|
|
||||||
asyncio.create_task(scan())
|
asyncio.create_task(scan())
|
||||||
|
|
||||||
|
|
||||||
class MegaBinarySensor(BinarySensorEntity, BaseMegaEntity):
|
class MegaBinarySensor(BinarySensorEntity, BaseMegaEntity):
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
|
|||||||
@@ -268,7 +268,6 @@ class MegaD:
|
|||||||
return pty, m
|
return pty, m
|
||||||
|
|
||||||
async def scan_ports(self,):
|
async def scan_ports(self,):
|
||||||
async with self.lck:
|
|
||||||
for x in range(38):
|
for x in range(38):
|
||||||
ret = await self.scan_port(x)
|
ret = await self.scan_port(x)
|
||||||
if ret:
|
if ret:
|
||||||
|
|||||||
Reference in New Issue
Block a user