When I type in “pip install --user ur-rtde”, I get errors. I have attached a picture with the error message, as it is too big to fit into a post.
I want to use RTDE to help with received data. I currently have been experimenting with using a socket connection in python and setting digital inputs and outputs. I want to start sending integer variables to the cobot and read received data. I know how to receive data from the cobot using the socket connection, but I don’t understand anything that I receive back from the cobot. It is just a big hex string.
So I have 3 questions:
Is there some pre-requisite that I have to do before I try to install this? Is there another way to install this withou pip?
Does anyone have any information on how to send integer values using python socket library?
Does anyone have any information on how to interpret the data received using the socket.recv(1024) command? The
received data looks something like
this:
b’\x00\x00\x007\x14\xff\xff\xff\xff\xff\xff\xff\xff\xfe\x03\tURControl\x05\x05\x00\x00\x00\x00\x00\x00\x00\x0028-08-2019,
08:56:36\x00\x00\x00\x18\x14\xff\xff\xff\xff\xff\xff\xff\xff\xfe\x0c\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x05j\x10\x00\x00\x00/\x00\x00\x00\x00\x01\xbd\
Please ask these questions on the issue tracker related to ur_rtde. Regarding your specific question, there is currently an issue with pip installation of ur_rtde on Windows, until I fix this you can try to build it from source.
‘the source does not appear to contain CMakeLists.txt’
How did you guys get it running? I would like to use it on Win 10 with Python 3.10
I would love to use an alternative to ur_rtde but couldn’t find one.
I use the WSL for other purposes, but I still did steps 1 and 2. I have a Virtual Machine with Ubuntu 20 that I use for the RTDE, but for this post I tried to run the commands from step 3 on the Ubuntu terminal in Windows and it worked, so I hope you can do it too.
The disadvantage from using the WSL is that it still counts as a separate OS, so sharing files can be tricky. On the other hand, since they are both running on the same machine, they both can access and share data through the internal IP address 127.0.0.1, so you can make server/client functions to send/receive data in separate processes. For example, you can use the terminal to access the RTDE server, get the TCP position from the UR and stream or re-send the data to a data-logger through UDP, TCP, XML-RPC, ROS topics…
In case you like this approach, this is how I work with the WSL:
Use Visual Code to edit programs in Python and run them from the Visual Code terminal.
For the RTDE, I follow this tutorial for beginners on how to use UR-RTDE on python. I use the VM, but I see no difference between using Visual Code inside a VM with Ubuntu 20 and using Visual Code with a Ubuntu 20 terminal on Windows.
Once you have installed the Ubuntu terminal and the extension on VCode, you’ll see a new option on the left bar, which is for connecting to the WSL. Then VCode will connect to it and re-open from the WSL directory.
Afterwards, you can navigate and edit files located in the Linux subsystem. If you open a terminal, it’ll be a Ubuntu terminal, and you can run Linux commands on it.