I have been working on a vision project, incorporating a ur3e.
I was hoping to be able to send a request over socket using python to receive coordinates from a PC program.
Ive looked at several tutorials where the PC is controlling the arm remotely, however for my purposes i would not like all the moves to be done remotely.
Every time i call socket_open i get false as the return.
I was wondering if perhaps there is a firewall blocking this or something i am unaware of was looking to see if anyone may know.
“Every time i call socket_open i get false as the return.”
This is going to be hard to figure out with the little information there is on your post. The issue can vary from a small detail, some beginner slip or a more advanced issue going on underneath, but I’ll give you a list of things you can check to figure it out. So, first things first: you have two separate devices that try to communicate with each other, so it can be that one is doing something wrong, maybe it’s the other one, or maybe it’s both of them.
Some stuff you can try from the PC side (server):
That is binded to a reachable IP address from the same network (e.g. 192.168.0.230, never use 127.0.0.1).
The ports number match in both sides.
You start up the server always before than the client.
The server is reachable by another processes (e.g. try to run a small script that connects to your Server and can retrieves info from it).
The server can reach the robot (open the command prompt from Windows and try to ping the robot IP address). In Windows there is a tricky thing that when a computer is connected to more than one network, it tends to “have a preference” for the one with Internet access, so if you cannot reach the robot, disable the Wi-Fi and other LANs and try again.
Some stuff you can try from the robot side (client):
The IP address and port are correct. Remember that UR controllers reserved ports for special processes, so make sure that your program is not trying to connect to port numbers like 3002, 3003,… or any other ports that are used by URCaps. Most of the examples from UR use port numbers like 50000 or 50002. If you are trying to use a reserved port, change it to an available port nr. on both the server and on the UR program.
The UR controller is within the same network than the PC (so the mask does not necessarily have to match as well, but I’d give it a try to this too). If you do changes on the IP address - mask settings, you might need to restart the controller because some OS internal settings only apply changes after a restart.
The server is reachable from the UR side. To try this, you’ll need to connect a keyboard to the controller, open a terminal and ping to the PC.
Give it a try to the suggestion of @androidflorent to see if you have any restrictions from Polyscope.
One last idea is to try first TCP-IP before XML-RPC. If it is only a connection issue, connecting server-client through TCP will be fine after fixing it. If you have different XML versions on the server and client side, you will have a connection error message when actually the connection is fine but the XML differences messes it up. Here you have an XML-RPC example using Python.
Connect a keyboard to the UR, and use CTRL-ALT-F1 to open one of the virtual terminals (You can use F1-F6, F7 is the Linux X server where polyscope runs)
username: root
pw: easybot
Windows blocks ICMP ping requests sometimes. Another thing to try would be making sure “Network discovery” is turned on in windows for that network. Might also need to make the LAN connection Private so it has full permissions.