I occasionally get this error when working with the UR3 and RTDE.
This error is so annoying, because I cannot shutdown my program that called the rtde modules with
ctrl+c. I have to kill the process.
How can I avoid this?
.../rtde/rtde.py(190)__on_packet() logging.error('Unknown package command: ' + str(cmd))
This is a traceback gathered from the debugger. Apparently it was caused when receiving the state:
state = self.socket.receive() .../rtde/rtde.py(169)receive() -> return self.recv(Command.RTDE_DATA_PACKAGE) .../rtde/rtde.py(236)recv() -> data = self.__on_packet(packet_header.command, packet) .../rtde/rtde.py(190)__on_packet()
The error always occurs after establishing a new rtde connection and starting the data exchange.
It is returned in a loop and blocks everything.
Using pdb I found out that the
cmd was 0 and payload was also empty with
I send over force/torque data and fill up the float registers. I get back tcp_speed.
My version is 126.96.36.1992 with a UR3.
Any help @jbm please?
@raphael have you tried upgrading the SW to 3.4? If you are using RTDE version 2 (the client code is currently available here: https://www.universal-robots.com/how-tos-and-faqs/how-to/ur-how-tos/real-time-data-exchange-rtde-guide-22229/), then you will need SW >= 3.4.
Software 3.3.x ran v1 protocol.
Software 3.4.x runs v2 RTDE protocol.
If you have recently downloaded the samples from the Support Site, these will be implementing the v2 protocol.
It is on my todo list to upgrade but is the new RTDE python 3 compatible? I had to rewrite the old packages to make it compatible.
Sorry, I can’t help you with that one. It is compatible with Python 2.7; maybe it’s worth giving it a quick try.