Closedown
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
import threading
|
||||
|
||||
class RobotTCP(TcpDevice, Stoppable):
|
||||
def __init__(self, name, server, timeout = 1000, retries = 1):
|
||||
TcpDevice.__init__(self, name, server)
|
||||
@@ -17,7 +15,6 @@ class RobotTCP(TcpDevice, Stoppable):
|
||||
self.empty = None
|
||||
self.working_mode = None
|
||||
self.status = None
|
||||
self.lock = threading.Lock()
|
||||
|
||||
def _sendReceive(self, msg_id, msg = "", timeout = None):
|
||||
tx = self.header if (self.header != None) else ""
|
||||
@@ -330,7 +327,7 @@ class RobotTCP(TcpDevice, Stoppable):
|
||||
#self.setState(State.Busy if self.status=="move" else State.Ready)
|
||||
if not self.settled: self.setState(State.Busy)
|
||||
if not self.empty: self.setState(State.Paused)
|
||||
else self.setState(State.Ready)
|
||||
else: self.setState(State.Ready)
|
||||
|
||||
def doUpdate(self):
|
||||
try:
|
||||
@@ -355,12 +352,5 @@ class RobotTCP(TcpDevice, Stoppable):
|
||||
|
||||
def on_event(self,ev):
|
||||
pass
|
||||
|
||||
def mount(self, puck, sample):
|
||||
return self.execute('mount', puck, sample)
|
||||
|
||||
|
||||
|
||||
add_device(RobotTCP("robot_tcp", "129.129.126.100:1000"), force = True)
|
||||
robot_tcp.setPolling(100)
|
||||
#robot_tcp.set_monitor_speed(20)
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ from ch.psi.pshell.serial import TcpDevice
|
||||
from ch.psi.pshell.modbus import ModbusTCP
|
||||
|
||||
|
||||
run("RobotTCP")
|
||||
run("RobotMX")
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user