def do_GetOutputOn(self, outputIDs): cmds = [] ids = outputIDs.split(',') for outputId in ids: eventBus.putEventOnBus( eventBus.E_OUTPUT_SET, (outputId, "64") ) self.send_response(200) self.send_header('Content-type', 'text/json') self.end_headers() return
def handleCommands(cmds): global OutputStatuses global EventQueue for cmd in cmds: output = None status = None if cmd.startswith('<OS'): output = cmd[3:6] status = cmd[6:8] if cmd.startswith('<GET OUTPUT LEVEL'): output = cmd[18:21] status = cmd[22:24] if output and status: eventBus.putEventOnBus(eventBus.E_OUTPUT_STATE, (output, status)) OutputStatuses[output] = status
def handleCommands(cmds): global OutputStatuses global EventQueue for cmd in cmds: output = None status = None if cmd.startswith('<OS'): output = cmd[3:6] status = cmd[6:8] if cmd.startswith('<GET OUTPUT LEVEL'): output = cmd[18:21] status = cmd[22:24] if output and status: eventBus.putEventOnBus( eventBus.E_OUTPUT_STATE, (output, status) ) OutputStatuses[ output ] = status
def requestFullSystemStatus(host, port): eventBus.putEventOnBus(eventBus.E_SEND_TIMEKEEPER_COMMAND, ("<PUSH STATUS ON />\n", ))
def requestFullSystemStatus(host, port): eventBus.putEventOnBus(eventBus.E_SEND_TIMEKEEPER_COMMAND, ( "<PUSH STATUS ON />\n", ) )