Skip to content

Commit f1ecb33

Browse files
committed
debugging
1 parent 7b6fc4b commit f1ecb33

File tree

4 files changed

+16
-19
lines changed

4 files changed

+16
-19
lines changed

conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@
5656
'rosdocs': ('http://docs.ros.org/' + ros_distro + '/api/%s', ''),
5757
'moveit_core': ('http://docs.ros.org/' + ros_distro + '/api/moveit_core/html/classmoveit_1_1core_1_1%s.html', ''),
5858
'planning_scene': ('http://docs.ros.org/' + ros_distro + '/api/moveit_core/html/classplanning__scene_1_1%s.html', ''),
59+
'moveit_python': ('file:///home/peter/projects/moveit_ws/doc/moveit_core/html/python/_autosummary/moveit.%s.html', ''),
5960
'planning_scene_monitor': ('http://docs.ros.org/' + ros_distro + '/api/moveit_ros_planning/html/classplanning__scene__monitor_1_1%s.html', ''),
6061
'collision_detection_struct': ('http://docs.ros.org/' + ros_distro + '/api/moveit_core/html/structcollision__detection_1_1%s.html', ''),
6162
'collision_detection_class': ('http://docs.ros.org/' + ros_distro + '/api/moveit_core/html/classcollision__detection_1_1%s.html', ''),

doc/planning_scene_python/planning_scene_tutorial.rst

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Planning Scene Python
22
==================================
33

4-
The :planning_scene:`PlanningScene` class provides the main interface that you will use
4+
The :moveit_python:`core.planning_scene.PlanningScene` class provides the main interface that you will use
55
for collision checking and constraint checking. In this tutorial, we
66
will explore the Python interface to this class.
77

@@ -17,6 +17,10 @@ The entire code can be seen :codedir:`here in the MoveIt GitHub project<planning
1717

1818
Running the code
1919
----------------
20+
Open two shells. Start RViz and wait for everything to finish loading in the first shell. You need to first clone `panda_moveit_config <http://github.com/ros-planning/panda_moveit_config>`_ in your catkin workspace and build: ::
21+
22+
roslaunch panda_moveit_config demo.launch
23+
2024
Roslaunch the launch file to run the code directly from moveit_tutorials: ::
2125

2226
rosrun moveit_tutorials planning_scene_tutorial.py
@@ -41,4 +45,4 @@ joint values so some things may be different. ::
4145
[INFO] [1615403459.498652]: Test 10: Random state is not constrained
4246
[INFO] [1615403459.503490]: Test 12: Random state is not valid
4347

44-
**Note:** Don't worry if your output has different ROS console format. You can customize your ROS console logger by following `this blog post <http://dav.ee/blog/notes/archives/898>`_.
48+
**Note:** Don't worry if your output has different ROS console format. You can customize your ROS console logger by following `this blog post <http://dav.ee/blog/notes/archives/898>`_.

doc/planning_scene_python/src/planning_scene_tutorial.py

Lines changed: 8 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def main():
1919
# Setup
2020
# ^^^^^
2121
#
22-
# The :planning_scene:`PlanningScene` class can be easily setup and
22+
# The :moveit_python:`core.planning_scene.PlanningScene` class can be easily setup and
2323
# configured using a URDF and
2424
# SRDF. This is, however, not the recommended way to instantiate a
2525
# PlanningScene. At the time of writing there are not yet python bindings
@@ -46,8 +46,8 @@ def main():
4646
# current state is in *self-collision*, i.e. whether the current
4747
# configuration of the robot would result in the robot's parts
4848
# hitting each other. To do this, we will construct a
49-
# :collision_detection_struct:`CollisionRequest` object and a
50-
# :collision_detection_struct:`CollisionResult` object and pass them
49+
# :moveit_python:`core.collision_detection.CollisionRequest` object and a
50+
# :moveit_python:`core.collision_detection.CollisionResult` object and pass them
5151
# into the collision checking function. Note that the result of
5252
# whether the robot is in self-collision or not is contained within
5353
# the result. Self collision checking uses an *unpadded* version of
@@ -73,7 +73,6 @@ def main():
7373
for (first_name, second_name), contacts in collision_result.contacts.items():
7474
rospy.loginfo(f"Contact between {first_name} and {second_name}")
7575

76-
7776
# Change the state
7877
# ~~~~~~~~~~~~~~~~
7978
#
@@ -122,7 +121,7 @@ def main():
122121
# Modifying the Allowed Collision Matrix
123122
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
124123
#
125-
# The :collision_detection_class:`AllowedCollisionMatrix` (ACM)
124+
# The :moveit_python:`core.collision_detection.AllowedCollisionMatrix` (ACM)
126125
# provides a mechanism to tell the collision world to ignore
127126
# collisions between certain object: both parts of the robot and
128127
# objects in the world. We can tell the collision checker to ignore
@@ -163,25 +162,17 @@ def main():
163162
# Constraint Checking
164163
# ^^^^^^^^^^^^^^^^^^^
165164
#
166-
# The PlanningScene class also includes easy to use function calls
167-
# for checking constraints. The constraints can be of two types:
168-
# (a) constraints chosen from the
169-
# :kinematic_constraints:`KinematicConstraint` set:
170-
# i.e. :kinematic_constraints:`JointConstraint`,
171-
# :kinematic_constraints:`PositionConstraint`,
172-
# :kinematic_constraints:`OrientationConstraint` and
173-
# :kinematic_constraints:`VisibilityConstraint` and (b) user
174-
# defined constraints specified through a callback. We will first
175-
# look at an example with a simple KinematicConstraint.
165+
# The PlanningScene class also includes easy to use function calls for checking constraints. The constraints can be
166+
# of two types: (a) constraints constructed using :moveit_python:`core.kinematic_constraints`, or (b) user defined
167+
# constraints specified through a callback. We will first look at an example with a simple
168+
# KinematicConstraint.
176169
#
177170
# Checking Kinematic Constraints
178171
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
179172
#
180173
# We will first define a simple position and orientation constraint
181174
# on the end-effector of the panda_arm group of the Panda robot. Note the
182175
# use of convenience functions for filling up the constraints
183-
# (these functions are found in the :moveit_core_files:`utils.h<utils_8h>` file from the
184-
# kinematic_constraints directory in moveit_core).
185176

186177
end_effector_name = joint_model_group.getLinkModelNames()[-1]
187178

index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ Building more complex applications with MoveIt often requires developers to dig
3838
doc/planning_scene/planning_scene_tutorial
3939
doc/planning_scene_monitor/planning_scene_monitor_tutorial
4040
doc/planning_scene_ros_api/planning_scene_ros_api_tutorial
41+
doc/planning_scene_python/planning_scene_tutorial
4142
doc/motion_planning_api/motion_planning_api_tutorial
4243
doc/motion_planning_pipeline/motion_planning_pipeline_tutorial
4344
doc/creating_moveit_plugins/plugin_tutorial

0 commit comments

Comments
 (0)