Пример #1
0
 def _sendRequest(self, signal, request):
     ''' Sending a request under a certain signal
     
     Args:
         signal (str): stringrepresentation of the signal about to be emitted
         request (dict):  dictionary that will be transmitted as a JSON-string'''
     UAV_Logger.log_debug("-->  SIGNAL: " + signal + " | REQUEST: " + str(request))
     self.socketIO.emit(signal, request)
Пример #2
0
 def _sendRequest_requireCallback(self, signal, request, callbackFkt):
     ''' Sending a request under a certain signal
     
     Args:
         signal (str): the signal to emit
         request (dict): dictionary that will be transmitted as a JSON-string
         callbackFkt (type): the callbackfunktion executed on positive response
         '''
     UAV_Logger.log_debug("--> SIGNAL: " + signal + " | REQUEST: " + str(request))
     self.socketIO.emit(signal, request, callbackFkt)
Пример #3
0
 def _receive(self, args):
     ''' First handling a received request, by parsing it'''
     request = Request(self.getModuleName()).parse(args)
     UAV_Logger.log_debug("<-- DATA: " + str(request))
     return request
Пример #4
0
 def onPySignal_acknowledged(self, *args):
     LOG.log_debug("received callback" + str(args[0]))