Does movej support URSim?
Opened this issue · 1 comments
Does the movej
support URSim? Although I can get the state right, why I always get this error when using movej
:
Current tool pose is: [-0.11606565366751193, -0.05602054660042595, -0.01930032084546665, 0.2398069576842853, -0.04788135162036506, 0.04752205982468178]
Traceback (most recent call last):
File "example_1.py", line 23, in
rob.movej((0.1, 0.1, 0.1, 0.1, 0.1, 0.1), 0.5, 0.1)
File "/usr/local/lib/python3.6/dist-packages/urx-0.11.0-py3.6.egg/urx/urrobot.py", line 330, in movej
self._wait_for_move(joints[:6], threshold=threshold, joints=True)
File "/usr/local/lib/python3.6/dist-packages/urx-0.11.0-py3.6.egg/urx/urrobot.py", line 270, in _wait_for_move
raise RobotException("Robot stopped")
urx.urrobot.RobotException: Robot stopped
thank you very much.
In URsim, you can use the urx library for simulation control. However, because the URsoftware used in URsim does not support setting up the network, the is_running() in the urx library is always judged to be False, so you need to modify the files in the urx (0.11.0) library.
- First ensure that URsim can be pinged by the host computer, that is, URsim can communicate with the host computer.
- There is an ursecmon.py file in the directory where urx was downloaded. Change this line
Line 316 in e277ef1
and self._dict["RobotModeData"]["isRobotConnected"] is False \
- If you are using URsoftware version >=3.5, refer to e1f78ce. The author submitted the update, but the update is not reflected in the
pip install urx
. So you can add these three lines manually. - If you use movel or getl function, you may encounter
AttributeError: 'PoseVector' object has no attribute 'tolist'
orCaught an unexpected exception: module 'collections' has no attribute 'Iterable'
. This is most likely caused by the incorrect math3d version. You can use
pip uninstall math3d
pip install math3d==3.0.0
to solve - If you encounter the problem of 4 and do not want to change the math3d version, you can refer to the link #117 (comment) to solve the problem, but functions such as movec still cannot be used.