예제 #1
0
def discover(handshake):
    """Search for robots in the network."""
    if handshake:
        MiIOProtocol.discover()
    else:
        miio.Discovery.discover_mdns()
예제 #2
0
파일: finder.py 프로젝트: gittubbs/giuliot
from miio.miioprotocol import MiIOProtocol
import logging
#from miio.vacuum_cli
logger = logging.getLogger(__name__)
logging.basicConfig(level=logging.INFO)

MiIOProtocol.discover()
예제 #3
0
def discover():
    """Search for plugs in the network."""
    MiIOProtocol.discover()
예제 #4
0
def discover(mdns, handshake, network, timeout):
    """Discover devices using both handshake and mdns methods."""
    if handshake:
        MiIOProtocol.discover(addr=network, timeout=timeout)
    if mdns:
        Discovery.discover_mdns(timeout=timeout)