def startCall():
    processHTTPStreaming = Popen(['python3', 'HTTPStreamer.py'],
                                 stdout=PIPE,
                                 stderr=PIPE)
    time.sleep(4)
    messageToSend = aesCipher.encrypt("CALL")
    TCPClient.startTCPClient(messageToSend)
    print("wysylam start call")
    UDPSender.microphoneActivated = True
    UDPListener.speakersActivated = True
    UDPListener.startUDPListener()
    return processHTTPStreaming
Esempio n. 2
0
 def __init__(self, ip_address=None):
   CloudLog.log(self._component, "Initializing.")
   try:
     if ip_address is None:
       ip_address = UDPListener.search(
         self._search_ip, self._search_port, self._search_strings)
     self._phue = phue.Bridge(ip=ip_address, username=self._hueAppID)
     self._ready = True
     CloudLog.log(self._component, "Ready.")
   except Exception, e:
     CloudLog.error(self._component, "Error searching for Hue Bridge", e)
Esempio n. 3
0
 def __init__(self, commands, ip_address=None):
   CloudLog.log(self._component, "Initializing.")
   try:
     self._commands = commands
     if ip_address is None:
       self._ip_address = UDPListener.search(
         self._search_ip, self._search_port, self._search_strings)
     else:
       self._ip_address = ip_address
     self._ready = True
     CloudLog.log(self._component, "Ready. [" + str(self._ip_address) + "]")
   except Exception, e:
     CloudLog.error(self._component, "Error searching for iTach Device", e)
Esempio n. 4
0
 def __init__(self, ip_address=None):
     CloudLog.log(self._component, "Initializing.")
     try:
         if ip_address is None:
             ip_address = UDPListener.search(self._search_ip,
                                             self._search_port,
                                             self._search_strings)
         self._phue = phue.Bridge(ip=ip_address, username=self._hueAppID)
         self._ready = True
         CloudLog.log(self._component, "Ready.")
     except Exception, e:
         CloudLog.error(self._component, "Error searching for Hue Bridge",
                        e)
Esempio n. 5
0
    def __init__(self, commands, ip_address=None):
        CloudLog.log(self._component, "Initializing.")
        try:
            self._commands = commands
            if ip_address is None:
                self._ip_address = UDPListener.search(self._search_ip,
                                                      self._search_port,
                                                      self._search_strings)
            else:
                self._ip_address = ip_address
            self._ready = True

            CloudLog.log(self._component,
                         "Ready. [" + str(self._ip_address) + "]")
        except Exception, e:
            CloudLog.error(self._component, "Error searching for iTach Device",
                           e)