PilzDE / pilz_tutorials

Files for PILZ tutorials on wiki.ros.org
http://wiki.ros.org/pilz_robots/Tutorials/
Apache License 2.0
9 stars 7 forks source link

Error while executing the tutorial's code #31

Closed GitNzino closed 3 years ago

GitNzino commented 3 years ago

Commit

1602681

Steps to reproduce

Use the code shown in the tutorial to move another robot: the Kinova Kortex Gen3 Lite.

The robot is able to move through the Rviz and pilz planner, but I am not able to move with a python script.

Expected behavior

The robot should move

Observed behavior

Appears only this message on the terminal and the robot does not move

[INFO] [1627287567.431922]: Waiting for connection to action server sequence_move_group...

Furthermore after terminating the script pressing Ctrl+C appears the following message:

[INFO] [1627288014.706463]: Waiting for connection to service /prbt/get_speed_override...
Traceback (most recent call last):
  File "/home/lorenzo/cw_kinova/src/kortex_planner/scripts/pliz_motion_planner_2.py", line 30, in <module>
    r = Robot(__REQUIRED_API_VERSION__) # instance of the robot
  File "/opt/ros/melodic/lib/python2.7/dist-packages/pilz_robot_programming/robot.py", line 137, in __init__
    self._establish_connections()
  File "/opt/ros/melodic/lib/python2.7/dist-packages/pilz_robot_programming/robot.py", line 542, in _establish_connections
    rospy.wait_for_service(self._GET_SPEED_OVERRIDE_SRV, self._SERVICE_WAIT_TIMEOUT_S)
  File "/opt/ros/melodic/lib/python2.7/dist-packages/rospy/impl/tcpros_service.py", line 146, in wait_for_service
    raise ROSInterruptException("rospy shutdown")
rospy.exceptions.ROSInterruptException: rospy shutdown
jschleicher commented 3 years ago

Note that the prbt packages are deprecated in the meantime. The planner was integrated into upstream moveit but we won't support the Python API any longer.

If you want to use the python interface with a different robot, you either have to use the fake_speed_override node as in some tests or comment the corresponding section in robot.py