Send Data From PC to Robot

Hello,

I do some Computer Vision on PC. Then, I want to send the location of the objects to the robot for picking up. Which communication protocol suits best to this use case?

You can use the socket communication.
After building the socket server on your pc, the command “socket_open” can be used on robot program as client.

1 Like

Check out this page which details all the ways you can communicate with your robot: Overview of client interfaces - 21744

To send a position, I advise you either :

  • Implement your own TCP socket protocol by creating a socket listener in your PC application and using socket_open() in your robot script
  • You can also use XML-RPC, which allows you to call from your robot a remote method implemented on your PC that returns the position. The advantage is that you get a position variable in your robot.
  • You can also use Primary Interface to ask to move your robot to a certain position by executing a movej via TCP

The articles on the UR website offer simple implementations in Python.

In addition, industrial libraries implement all these protocols and many others. Take a look at this one: UR+ | Communication & Toolkit Software Library for Universal Robots

1 Like

Where can I a Python sample for sending a move command to the robot over TCP socket?