Exemple #1
0
def setAllValues(host, port, param, values):
    response = clienttcp.tcpConnection(
        host, port,
        "(S," + param + ",*," + ",".join([str(v) for v in values]) + ")")
    if response is not None:
        return parseGetAllValuesResponse(response)
    return None
Exemple #2
0
def setParams(params, host, port):
    frames = ""
    for p in params:
        frames += "(S," + ",".join(p) + ")"
    print frames
    response = clienttcp.tcpConnection(host, port, frames)
    if response is not None:
        return parseGetValuesResponse(response)
    return {}
Exemple #3
0
def setParams(params, host, port):
    frames = ""
    for p in params:
        frames += "(S," + ",".join(p) + ")"
    print frames
    response = clienttcp.tcpConnection(host, port, frames)
    if response is not None:
        return parseGetValuesResponse(response)
    return {}
 def run(self):
     response = clienttcp.tcpConnection(self.host, self.port, self.frames)
     if response is not None:
         self.responseRecived.emit(response)
 def run(self):
     response = clienttcp.tcpConnection(self.host, self.port, self.frames)
     if response is not None:
         self.responseRecived.emit(response)
Exemple #6
0
def getAxesVelocity(host, port):
    response = clienttcp.tcpConnection(host, port, "(G,A,s,*)")
    if response is not None:
        return parseAxesVelocity(response)
    return None
Exemple #7
0
def setAxesVelocity(host, port, values):
    response = clienttcp.tcpConnection(host, port, "(S,A,s,*," + ",".join([str(v) for v in values]) + ")")
    if response is not None:
        return parseAxesVelocity(response)
    return None
Exemple #8
0
def setAllValues(host, port, param, values):
    response = clienttcp.tcpConnection(host, port, "(S," + param + ",*," + ",".join([str(v) for v in values]) + ")")
    if response is not None:
        return parseGetAllValuesResponse(response)
    return None
Exemple #9
0
def getAllValues(host, port, param):
    response = clienttcp.tcpConnection(host, port, "(G," + param + ",*)")
    if response is not None:
        return parseGetAllValuesResponse(response)
    return None
Exemple #10
0
def getParam(param, host, port):
    response = clienttcp.tcpConnection(host, port, "(G," + param +")")
    print response
    if response is not None:
        return parseGetValuesResponse(response)
    return None
Exemple #11
0
def echo(host, port):
    response = clienttcp.tcpConnection(host, port, "(?)")
    if response is not None:
        return True
    return False
Exemple #12
0
def setAxesVelocity(host, port, values):
    response = clienttcp.tcpConnection(
        host, port, "(S,A,s,*," + ",".join([str(v) for v in values]) + ")")
    if response is not None:
        return parseAxesVelocity(response)
    return None
Exemple #13
0
def getAllValues(host, port, param):
    response = clienttcp.tcpConnection(host, port, "(G," + param + ",*)")
    if response is not None:
        return parseGetAllValuesResponse(response)
    return None
Exemple #14
0
def getParam(param, host, port):
    response = clienttcp.tcpConnection(host, port, "(G," + param + ")")
    print response
    if response is not None:
        return parseGetValuesResponse(response)
    return None
Exemple #15
0
def echo(host, port):
    response = clienttcp.tcpConnection(host, port, "(?)")
    if response is not None:
        return True
    return False
Exemple #16
0
def getAxesVelocity(host, port):
    response = clienttcp.tcpConnection(host, port, "(G,A,s,*)")
    if response is not None:
        return parseAxesVelocity(response)
    return None