Hello,
I am working with an UR5e in my university project. Currently I am trying to activate my gripper through setting the “Tool Digital Output 1” to true, which works when changing its value on the robots controller.
While searching for a way I found the possibility of sending an UR-Script command via a socket to the robot. While it seems to work for the examples I found, the value does not change for my robot.
Is my code (see below) correct or am I missing something?
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect(("192.168.12.200", 30002))
output = "set_tool_digital_out(1,True)"
s.send(output)
data = s.recv(1024)
s.close
print("Received", repr(data))
Specs:
Ubuntu 20.04
Python: 3.8
Robot: UR5e (Software Version: 5.12)