Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extract robot description into global package (again) #339

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion example_1/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ install(
DESTINATION include/ros2_control_demo_example_1
)
install(
DIRECTORY description/launch description/ros2_control description/urdf description/rviz
DIRECTORY description/launch description/ros2_control description/urdf
DESTINATION share/ros2_control_demo_example_1
)
install(
Expand Down
2 changes: 1 addition & 1 deletion example_1/bringup/launch/rrbot.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def generate_launch_description():
]
)
rviz_config_file = PathJoinSubstitution(
[FindPackageShare("ros2_control_demo_example_1"), "rviz", "rrbot.rviz"]
[FindPackageShare("ros2_control_demo_description"), "rrbot/rviz", "rrbot.rviz"]
)

control_node = Node(
Expand Down
6 changes: 3 additions & 3 deletions example_1/description/launch/view_robot.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def generate_launch_description():
declared_arguments.append(
DeclareLaunchArgument(
"description_package",
default_value="ros2_control_demo_example_1",
default_value="ros2_control_demo_description",
description="Description package with robot URDF/xacro files. Usually the argument \
is not set, it enables use of a custom description.",
)
Expand Down Expand Up @@ -69,7 +69,7 @@ def generate_launch_description():
PathJoinSubstitution([FindExecutable(name="xacro")]),
" ",
PathJoinSubstitution(
[FindPackageShare(description_package), "urdf", description_file]
[FindPackageShare("ros2_control_demo_example_1"), "urdf", description_file]
),
" ",
"prefix:=",
Expand All @@ -79,7 +79,7 @@ def generate_launch_description():
robot_description = {"robot_description": robot_description_content}

rviz_config_file = PathJoinSubstitution(
[FindPackageShare(description_package), "rviz", "rrbot.rviz"]
[FindPackageShare(description_package), "rrbot/rviz", "rrbot.rviz"]
)

joint_state_publisher_node = Node(
Expand Down
4 changes: 2 additions & 2 deletions example_1/description/urdf/rrbot.urdf.xacro
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ https://github.com/ros-simulation/gazebo_ros_demos/blob/kinetic-devel/rrbot_desc
<xacro:arg name="prefix" default="" />

<!-- Import RRBot macro -->
<xacro:include filename="$(find ros2_control_demo_example_1)/urdf/rrbot_description.urdf.xacro" />
<xacro:include filename="$(find ros2_control_demo_description)/rrbot/urdf/rrbot_description.urdf.xacro" />

<!-- Import Rviz colors -->
<xacro:include filename="$(find ros2_control_demo_example_1)/urdf/rrbot.materials.xacro" />
<xacro:include filename="$(find ros2_control_demo_description)/rrbot/urdf/rrbot.materials.xacro" />

<!-- Import RRBot ros2_control description -->
<xacro:include filename="$(find ros2_control_demo_example_1)/ros2_control/rrbot.ros2_control.xacro" />
Expand Down
119 changes: 0 additions & 119 deletions example_1/description/urdf/rrbot_description.urdf.xacro

This file was deleted.

4 changes: 2 additions & 2 deletions example_1/doc/userdoc.rst
Original file line number Diff line number Diff line change
Expand Up @@ -221,10 +221,10 @@ Files used for this demos
* Controllers yaml: `rrbot_controllers.yaml <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/example_1/bringup/config/rrbot_controllers.yaml>`__
* URDF file: `rrbot.urdf.xacro <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/example_1/description/urdf/rrbot.urdf.xacro>`__

* Description: `rrbot_description.urdf.xacro <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/example_1/description/urdf/rrbot_description.urdf.xacro>`__
* Description: `rrbot_description.urdf.xacro <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/ros2_control_demo_description/rrbot/urdf/rrbot_description.urdf.xacro>`__
* ``ros2_control`` tag: `rrbot.ros2_control.xacro <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/example_1/description/ros2_control/rrbot.ros2_control.xacro>`__

* RViz configuration: `rrbot.rviz <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/example_1/description/rviz/rrbot.rviz>`__
* RViz configuration: `rrbot.rviz <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/ros2_control_demo_description/rrbot/rviz/rrbot.rviz>`__
* Test nodes goals configuration:

+ `rrbot_forward_position_publisher <https://github.com/ros-controls/ros2_control_demos/tree/{REPOS_FILE_BRANCH}/example_1/bringup/config/rrbot_forward_position_publisher.yaml>`__
Expand Down
1 change: 1 addition & 0 deletions example_1/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
<exec_depend>joint_state_publisher_gui</exec_depend>
<exec_depend>joint_trajectory_controller</exec_depend>
<exec_depend>robot_state_publisher</exec_depend>
<exec_depend>ros2_control_demo_description</exec_depend>
<exec_depend>ros2_controllers_test_nodes</exec_depend>
<exec_depend>ros2controlcli</exec_depend>
<exec_depend>ros2launch</exec_depend>
Expand Down
2 changes: 1 addition & 1 deletion example_12/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ install(
DESTINATION include/ros2_control_demo_example_12
)
install(
DIRECTORY description/launch description/ros2_control description/urdf description/gazebo description/rviz
DIRECTORY description/launch description/ros2_control description/urdf description/gazebo
DESTINATION share/ros2_control_demo_example_12
)
install(
Expand Down
2 changes: 1 addition & 1 deletion example_12/bringup/launch/rrbot.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def generate_launch_description():
]
)
rviz_config_file = PathJoinSubstitution(
[FindPackageShare("ros2_control_demo_example_12"), "rviz", "rrbot.rviz"]
[FindPackageShare("ros2_control_demo_description"), "rrbot/rviz", "rrbot.rviz"]
)

control_node = Node(
Expand Down
6 changes: 3 additions & 3 deletions example_12/description/launch/view_robot.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def generate_launch_description():
declared_arguments.append(
DeclareLaunchArgument(
"description_package",
default_value="ros2_control_demo_example_12",
default_value="ros2_control_demo_description",
description="Description package with robot URDF/xacro files. Usually the argument \
is not set, it enables use of a custom description.",
)
Expand Down Expand Up @@ -59,7 +59,7 @@ def generate_launch_description():
PathJoinSubstitution([FindExecutable(name="xacro")]),
" ",
PathJoinSubstitution(
[FindPackageShare(description_package), "urdf", description_file]
[FindPackageShare("ros2_control_demo_example_12"), "urdf", description_file]
),
" ",
"prefix:=",
Expand All @@ -69,7 +69,7 @@ def generate_launch_description():
robot_description = {"robot_description": robot_description_content}

rviz_config_file = PathJoinSubstitution(
[FindPackageShare(description_package), "rviz", "rrbot.rviz"]
[FindPackageShare(description_package), "rrbot/rviz", "rrbot.rviz"]
)

joint_state_publisher_node = Node(
Expand Down
Loading
Loading