(self, discover_delay=2, st='ssdp:all', **headers)
Perform an M-SEARCH SSDP request

        Send an SSDP M-SEARCH request for finding UPnP devices on the network.

        :param discover_delay: Device discovery delay in seconds
        :type discover_delay: int
        :param st: Specify device Search Target
        :type st: str
        :param headers: Specify M-SEARCH specific headers
        :type headers: str
        :return: List of device that replied
        :rtype: list
Perform an M-SEARCH SSDP request
Perform an M - SEARCH SSDP request
def m_search(self, discover_delay=2, st='ssdp:all', **headers):
        """Perform an M-SEARCH SSDP request

        Send an SSDP M-SEARCH request for finding UPnP devices on the network.

        :param discover_delay: Device discovery delay in seconds
        :type discover_delay: int
        :param st: Specify device Search Target
        :type st: str
        :param headers: Specify M-SEARCH specific headers
        :type headers: str
        :return: List of device that replied
        :rtype: list

        """
        self.set_method('M-SEARCH')

        self.set_header('MAN', '"ssdp:discover"')
        self.set_header('MX', discover_delay)
        self.set_header('ST', st)
        self.set_headers(**headers)

        self.socket.settimeout(discover_delay)

        devices = self._send_request(self._get_raw_request())

        for device in devices:
            yield device
def m_search ( self , discover_delay = 2 , st = 'ssdp:all' , * * headers ) : self . set_method ( 'M-SEARCH' ) self . set_header ( 'MAN' , '"ssdp:discover"' ) self . set_header ( 'MX' , discover_delay ) self . set_header ( 'ST' , st ) self . set_headers ( * * headers ) self . socket . settimeout ( discover_delay ) devices = self . _send_request ( self . _get_raw_request ( ) ) for device in devices : yield device