From d9d5c208dae5226769b60687968327a9b26909a3 Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 29 Sep 2023 19:05:00 +0900 Subject: [PATCH 01/14] =?UTF-8?q?CMakeLists.txt=E3=81=AEROS=202=E5=AF=BE?= =?UTF-8?q?=E5=BF=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CMakeLists.txt | 44 +++++++++++++++++++------------------------- 1 file changed, 19 insertions(+), 25 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2c5e7d6..4971666 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,33 +1,27 @@ -cmake_minimum_required(VERSION 2.8.3) +cmake_minimum_required(VERSION 3.5) project(sciurus17_description) -# add_definitions(-std=c++11) +find_package(ament_cmake REQUIRED) -find_package(catkin REQUIRED COMPONENTS - rospy - std_msgs +install(DIRECTORY + launch + meshes + urdf + DESTINATION share/${PROJECT_NAME}/ ) -# catkin_python_setup() +ament_python_install_package(${PROJECT_NAME}) +install(PROGRAMS + ${PROJECT_NAME}/robot_description_loader.py + DESTINATION lib/${PROJECT_NAME}) -################################### -## catkin specific configuration ## -################################### -catkin_package( -) +if(BUILD_TESTING) + find_package(ament_lint_auto REQUIRED) + set(ament_cmake_copyright_FOUND TRUE) # Skip copyright checks + ament_lint_auto_find_test_dependencies() -########### -## Build ## -########### -include_directories( - ${catkin_INCLUDE_DIRS} -) + find_package(ament_cmake_pytest REQUIRED) + # ament_add_pytest_test(test_robot_description_loader test/test_robot_description_loader.py) +endif() -############# -## Install ## -############# -foreach(dir config launch meshes urdf) - install(DIRECTORY ${dir}/ - DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/${dir} - ) -endforeach(dir) +ament_package() From 0646ef1ce61768400e8152b4bfab48641381047b Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 29 Sep 2023 19:05:22 +0900 Subject: [PATCH 02/14] =?UTF-8?q?package.xml=E3=81=AEROS=202=E5=AF=BE?= =?UTF-8?q?=E5=BF=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.xml | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/package.xml b/package.xml index b2753b1..e304614 100644 --- a/package.xml +++ b/package.xml @@ -1,25 +1,29 @@ - + + sciurus17_description - 1.0.0 - The SCIURUS17 description package - + 2.0.0 + The Sciurus17 description package RT Corporation - Hiroyuki Nomura NON-COMMERCIAL LICENSE AGREEMENT - catkin + Hiroyuki Nomura + ShotaAk - rospy - std_msgs + ament_cmake - rospy - std_msgs + ign_ros2_control + joint_state_publisher_gui + launch + robot_state_publisher + rviz2 + xacro - joint_state_publisher - joint_state_publisher_gui - robot_state_publisher - rviz - xacro + ament_lint_auto + ament_lint_common + ament_cmake_pytest - + + ament_cmake + + \ No newline at end of file From b877b62b932dd5cbf8f20099a794ab279fcf2161 Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 29 Sep 2023 19:07:03 +0900 Subject: [PATCH 03/14] =?UTF-8?q?display.launch.py=E3=81=AEROS=202?= =?UTF-8?q?=E5=AF=BE=E5=BF=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- launch/display.launch | 13 -- launch/display.launch.py | 36 +++++ launch/display.rviz | 294 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 330 insertions(+), 13 deletions(-) delete mode 100644 launch/display.launch create mode 100644 launch/display.launch.py create mode 100644 launch/display.rviz diff --git a/launch/display.launch b/launch/display.launch deleted file mode 100644 index de0bc53..0000000 --- a/launch/display.launch +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - ["/sciurus17/joint_states"] - - - - - - diff --git a/launch/display.launch.py b/launch/display.launch.py new file mode 100644 index 0000000..8fec3ad --- /dev/null +++ b/launch/display.launch.py @@ -0,0 +1,36 @@ +# Copyright 2023 RT Corporation + +from ament_index_python.packages import get_package_share_directory +from sciurus17_description.robot_description_loader import RobotDescriptionLoader +from launch import LaunchDescription +from launch.actions import DeclareLaunchArgument +from launch.substitutions import LaunchConfiguration +from launch_ros.actions import Node + + +def generate_launch_description(): + description_loader = RobotDescriptionLoader() + + rsp = Node(package='robot_state_publisher', + executable='robot_state_publisher', + output='both', + parameters=[{'robot_description': description_loader.load()}]) + jsp = Node( + package='joint_state_publisher_gui', + executable='joint_state_publisher_gui', + output='screen') + + rviz_config_file = get_package_share_directory( + 'sciurus17_description') + '/launch/display.rviz' + rviz = Node(package='rviz2', + executable='rviz2', + name='rviz2', + output='log', + arguments=['-d', rviz_config_file]) + + ld = LaunchDescription() + ld.add_action(rsp) + ld.add_action(jsp) + ld.add_action(rviz) + + return ld diff --git a/launch/display.rviz b/launch/display.rviz new file mode 100644 index 0000000..1d81865 --- /dev/null +++ b/launch/display.rviz @@ -0,0 +1,294 @@ +Panels: + - Class: rviz_common/Displays + Help Height: 78 + Name: Displays + Property Tree Widget: + Expanded: + - /Global Options1 + - /Status1 + Splitter Ratio: 0.5 + Tree Height: 555 + - Class: rviz_common/Selection + Name: Selection + - Class: rviz_common/Tool Properties + Expanded: + - /2D Goal Pose1 + - /Publish Point1 + Name: Tool Properties + Splitter Ratio: 0.5886790156364441 + - Class: rviz_common/Views + Expanded: + - /Current View1 + - /Current View1/Focal Point1 + Name: Views + Splitter Ratio: 0.5 + - Class: rviz_common/Time + Experimental: false + Name: Time + SyncMode: 0 + SyncSource: "" +Visualization Manager: + Class: "" + Displays: + - Alpha: 0.5 + Cell Size: 1 + Class: rviz_default_plugins/Grid + Color: 160; 160; 164 + Enabled: true + Line Style: + Line Width: 0.029999999329447746 + Value: Lines + Name: Grid + Normal Cell Count: 0 + Offset: + X: 0 + Y: 0 + Z: 0 + Plane: XY + Plane Cell Count: 10 + Reference Frame: + Value: true + - Alpha: 1 + Class: rviz_default_plugins/RobotModel + Collision Enabled: false + Description File: "" + Description Source: Topic + Description Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /robot_description + Enabled: true + Links: + All Links Enabled: true + Expand Joint Details: false + Expand Link Details: false + Expand Tree: false + Link Tree Style: Links in Alphabetic Order + base_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + body_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + camera_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + chest_camera_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_handA_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_handB_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link1: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link2: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link3: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link4: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link5: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link5_armarker: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link6: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + l_link7: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + neck_pitch_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + neck_yaw_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_handA_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_handB_link: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link1: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link2: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link3: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link4: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link5: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link5_armarker: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link6: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + r_link7: + Alpha: 1 + Show Axes: false + Show Trail: false + Value: true + world: + Alpha: 1 + Show Axes: false + Show Trail: false + Mass Properties: + Inertia: false + Mass: false + Name: RobotModel + TF Prefix: "" + Update Interval: 0 + Value: true + Visual Enabled: true + Enabled: true + Global Options: + Background Color: 48; 48; 48 + Fixed Frame: base_link + Frame Rate: 30 + Name: root + Tools: + - Class: rviz_default_plugins/Interact + Hide Inactive Objects: true + - Class: rviz_default_plugins/MoveCamera + - Class: rviz_default_plugins/Select + - Class: rviz_default_plugins/FocusCamera + - Class: rviz_default_plugins/Measure + Line color: 128; 128; 0 + - Class: rviz_default_plugins/SetInitialPose + Covariance x: 0.25 + Covariance y: 0.25 + Covariance yaw: 0.06853891909122467 + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /initialpose + - Class: rviz_default_plugins/SetGoal + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /goal_pose + - Class: rviz_default_plugins/PublishPoint + Single click: true + Topic: + Depth: 5 + Durability Policy: Volatile + History Policy: Keep Last + Reliability Policy: Reliable + Value: /clicked_point + Transformation: + Current: + Class: rviz_default_plugins/TF + Value: true + Views: + Current: + Class: rviz_default_plugins/Orbit + Distance: 2.5 + Enable Stereo Rendering: + Stereo Eye Separation: 0.05999999865889549 + Stereo Focal Distance: 1 + Swap Stereo Eyes: false + Value: false + Focal Point: + X: 0 + Y: 0 + Z: 0 + Focal Shape Fixed Size: true + Focal Shape Size: 0.05000000074505806 + Invert Z Axis: false + Name: Current View + Near Clip Distance: 0.009999999776482582 + Pitch: 0.5 + Target Frame: + Value: Orbit (rviz) + Yaw: 0 + Saved: ~ +Window Geometry: + Displays: + collapsed: false + Height: 846 + Hide Left Dock: false + Hide Right Dock: false + QMainWindow State: 000000ff00000000fd000000040000000000000156000002b4fc0200000008fb0000001200530065006c0065006300740069006f006e00000001e10000009b0000005c00fffffffb0000001e0054006f006f006c002000500072006f007000650072007400690065007302000001ed000001df00000185000000a3fb000000120056006900650077007300200054006f006f02000001df000002110000018500000122fb000000200054006f006f006c002000500072006f0070006500720074006900650073003203000002880000011d000002210000017afb000000100044006900730070006c006100790073010000003b000002b4000000c700fffffffb0000002000730065006c0065006300740069006f006e00200062007500660066006500720200000138000000aa0000023a00000294fb00000014005700690064006500530074006500720065006f02000000e6000000d2000003ee0000030bfb0000000c004b0069006e0065006300740200000186000001060000030c00000261000000010000010f000002b4fc0200000003fb0000001e0054006f006f006c002000500072006f00700065007200740069006500730100000041000000780000000000000000fb0000000a00560069006500770073010000003b000002b4000000a000fffffffb0000001200530065006c0065006300740069006f006e010000025a000000b200000000000000000000000200000490000000a9fc0100000001fb0000000a00560069006500770073030000004e00000080000002e10000019700000003000004b00000003efc0100000002fb0000000800540069006d00650100000000000004b00000025300fffffffb0000000800540069006d006501000000000000045000000000000000000000023f000002b400000004000000040000000800000008fc0000000100000002000000010000000a0054006f006f006c00730100000000ffffffff0000000000000000 + Selection: + collapsed: false + Time: + collapsed: false + Tool Properties: + collapsed: false + Views: + collapsed: false + Width: 1200 + X: 237 + Y: 81 From ff5b3e85a806e1334786b3283e48b4eebd606a36 Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 29 Sep 2023 19:10:51 +0900 Subject: [PATCH 04/14] =?UTF-8?q?robot=5Fdescription=5Floader.py=E8=BF=BD?= =?UTF-8?q?=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sciurus17_description/__init__.py | 0 .../robot_description_loader.py | 21 +++++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 sciurus17_description/__init__.py create mode 100755 sciurus17_description/robot_description_loader.py diff --git a/sciurus17_description/__init__.py b/sciurus17_description/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/sciurus17_description/robot_description_loader.py b/sciurus17_description/robot_description_loader.py new file mode 100755 index 0000000..aa80469 --- /dev/null +++ b/sciurus17_description/robot_description_loader.py @@ -0,0 +1,21 @@ +# Copyright 2023 RT Corporation + +import os + +from ament_index_python.packages import get_package_share_directory +from launch.substitutions import Command + + +class RobotDescriptionLoader(): + + def __init__(self): + self.robot_description_path = os.path.join( + get_package_share_directory('sciurus17_description'), + 'urdf', + 'sciurus17.urdf.xacro') + + def load(self): + return Command([ + 'xacro ', + self.robot_description_path + ]) From f376c85ea952b411d19832c57dcc4bcc8a91128f Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Thu, 5 Oct 2023 13:50:39 +0900 Subject: [PATCH 05/14] =?UTF-8?q?link=E3=80=81joint=E5=90=8D=E3=81=AEprope?= =?UTF-8?q?rty=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- urdf/sciurus17.urdf.xacro | 66 ++++++++++++++++++++++++++++- urdf/sciurus17_body.xacro | 24 +++++------ urdf/sciurus17_head.xacro | 30 ++++++------- urdf/sciurus17_left_arm.xacro | 74 ++++++++++++++++----------------- urdf/sciurus17_left_hand.xacro | 26 ++++++------ urdf/sciurus17_right_arm.xacro | 74 ++++++++++++++++----------------- urdf/sciurus17_right_hand.xacro | 26 ++++++------ 7 files changed, 191 insertions(+), 129 deletions(-) diff --git a/urdf/sciurus17.urdf.xacro b/urdf/sciurus17.urdf.xacro index 6dea7bc..5102a10 100644 --- a/urdf/sciurus17.urdf.xacro +++ b/urdf/sciurus17.urdf.xacro @@ -15,6 +15,68 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -70,9 +132,9 @@ - + - + - + @@ -32,9 +32,9 @@ - - - + + + - + @@ -65,13 +65,13 @@ - - - + + + - + @@ -87,13 +87,13 @@ - + Gazebo/White - + Gazebo/White - + Gazebo/Black diff --git a/urdf/sciurus17_head.xacro b/urdf/sciurus17_head.xacro index 700293b..74521ea 100644 --- a/urdf/sciurus17_head.xacro +++ b/urdf/sciurus17_head.xacro @@ -13,9 +13,9 @@ camera_color "> - - - + + + - + @@ -45,9 +45,9 @@ - - - + + + - + @@ -79,13 +79,13 @@ - - - + + + - + @@ -101,13 +101,13 @@ - + Gazebo/White - + Gazebo/White - + Gazebo/Black diff --git a/urdf/sciurus17_left_arm.xacro b/urdf/sciurus17_left_arm.xacro index 535043e..6eb20cd 100644 --- a/urdf/sciurus17_left_arm.xacro +++ b/urdf/sciurus17_left_arm.xacro @@ -22,9 +22,9 @@ arm_color "> - - - + + + - + @@ -56,9 +56,9 @@ - - - + + + - + @@ -90,9 +90,9 @@ - - - + + + - + @@ -124,9 +124,9 @@ - - - + + + - + @@ -158,9 +158,9 @@ - - - + + + - + @@ -210,13 +210,13 @@ - - - + + + - + @@ -232,9 +232,9 @@ - - - + + + - + @@ -266,9 +266,9 @@ - - - + + + - + Gazebo/White - + Gazebo/White - + Gazebo/White - + Gazebo/White - + Gazebo/White - + Gazebo/White diff --git a/urdf/sciurus17_left_hand.xacro b/urdf/sciurus17_left_hand.xacro index 107f345..7d5c140 100644 --- a/urdf/sciurus17_left_hand.xacro +++ b/urdf/sciurus17_left_hand.xacro @@ -10,7 +10,7 @@ hand_color "> - + @@ -31,9 +31,9 @@ - - - + + + - + @@ -65,9 +65,9 @@ - - - + + + - + - + @@ -100,13 +100,13 @@ - + Gazebo/Red - + Gazebo/Red - + Gazebo/Red diff --git a/urdf/sciurus17_right_arm.xacro b/urdf/sciurus17_right_arm.xacro index 75ff676..41b45ad 100644 --- a/urdf/sciurus17_right_arm.xacro +++ b/urdf/sciurus17_right_arm.xacro @@ -22,9 +22,9 @@ arm_color "> - - - + + + - + @@ -56,9 +56,9 @@ - - - + + + - + @@ -90,9 +90,9 @@ - - - + + + - + @@ -124,9 +124,9 @@ - - - + + + - + @@ -158,9 +158,9 @@ - - - + + + - + @@ -210,13 +210,13 @@ - - - + + + - + @@ -232,9 +232,9 @@ - - - + + + - + @@ -266,9 +266,9 @@ - - - + + + - + Gazebo/White - + Gazebo/White - + Gazebo/White - + Gazebo/White - + Gazebo/White - + Gazebo/White diff --git a/urdf/sciurus17_right_hand.xacro b/urdf/sciurus17_right_hand.xacro index d63a72a..f2d5f2c 100644 --- a/urdf/sciurus17_right_hand.xacro +++ b/urdf/sciurus17_right_hand.xacro @@ -10,7 +10,7 @@ hand_color "> - + @@ -31,9 +31,9 @@ - - - + + + - + @@ -66,9 +66,9 @@ - - - + + + - + - + @@ -102,13 +102,13 @@ - + Gazebo/Red - + Gazebo/Red - + Gazebo/Red From e075335de9cf36a7507f757acb3ef31ed436e581 Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Thu, 5 Oct 2023 13:53:00 +0900 Subject: [PATCH 06/14] =?UTF-8?q?industrial=5Fci=E3=81=AE=E7=92=B0?= =?UTF-8?q?=E5=A2=83=E3=82=92humble=E3=81=AB=E5=A4=89=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/industrial_ci.yml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/.github/workflows/industrial_ci.yml b/.github/workflows/industrial_ci.yml index d1c1fea..3ecf7af 100644 --- a/.github/workflows/industrial_ci.yml +++ b/.github/workflows/industrial_ci.yml @@ -7,23 +7,14 @@ on: pull_request: paths-ignore: - '**.md' - schedule: - - cron: "0 2 * * 0" # Weekly on Sundays at 02:00 + workflow_dispatch: jobs: industrial_ci: - continue-on-error: ${{ matrix.experimental }} strategy: matrix: env: - - { ROS_DISTRO: melodic, ROS_REPO: main } - - { ROS_DISTRO: noetic, ROS_REPO: main } - experimental: [false] - include: - - env: { ROS_DISTRO: melodic, ROS_REPO: testing } - experimental: true - - env: { ROS_DISTRO: noetic, ROS_REPO: testing } - experimental: true + - { ROS_DISTRO: humble, ROS_REPO: ros, BEFORE_RUN_TARGET_TEST_EMBED: "ici_with_unset_variables source /root/target_ws/install/setup.bash" } runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 From c26397736603eb61ac8ed35b7d204c21c6cfb74b Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Thu, 5 Oct 2023 15:46:15 +0900 Subject: [PATCH 07/14] =?UTF-8?q?joint=20limit=E3=82=92property=E3=81=A7?= =?UTF-8?q?=E5=AE=9A=E7=BE=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- urdf/sciurus17.urdf.xacro | 118 ++++++++++++++++++++++++++------------ 1 file changed, 80 insertions(+), 38 deletions(-) diff --git a/urdf/sciurus17.urdf.xacro b/urdf/sciurus17.urdf.xacro index 5102a10..8fe89b2 100644 --- a/urdf/sciurus17.urdf.xacro +++ b/urdf/sciurus17.urdf.xacro @@ -80,6 +80,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -138,8 +180,8 @@ From c34b1fa105634407b0db9146e3c4f446ba3c188c Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Thu, 5 Oct 2023 15:57:31 +0900 Subject: [PATCH 08/14] =?UTF-8?q?color=E3=82=92property=E3=81=A7=E5=AE=9A?= =?UTF-8?q?=E7=BE=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- urdf/sciurus17.urdf.xacro | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/urdf/sciurus17.urdf.xacro b/urdf/sciurus17.urdf.xacro index 8fe89b2..dec3f80 100644 --- a/urdf/sciurus17.urdf.xacro +++ b/urdf/sciurus17.urdf.xacro @@ -122,6 +122,13 @@ + + + + + + + @@ -184,9 +191,9 @@ waist_yaw_lower_limit="${NAME_JOINT_BODY_UPPER_LIMIT}" waist_yaw_effort_limit="${EFFORT_LIMIT}" waist_yaw_velocity_limit="${VELOCITY_LIMIT}" - base_color="white" - body_color="white" - camera_color="white"> + base_color="${COLOR_LINK_BASE}" + body_color="${COLOR_LINK_BODY}" + camera_color="${COLOR_LINK_CAMERA}"> + head_color="${COLOR_LINK_HEAD}" + camera_color="${COLOR_LINK_CAMERA}"> + arm_color="${COLOR_LINK_ARM}"> + hand_color="${COLOR_LINK_HAND}"> + arm_color="${COLOR_LINK_ARM}"> + hand_color="${COLOR_LINK_HAND}"> From fc6fcd2cf68d211bb8199b8b13077818431640bc Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Thu, 5 Oct 2023 16:59:37 +0900 Subject: [PATCH 09/14] =?UTF-8?q?=E4=BD=BF=E7=94=A8=E3=81=97=E3=81=A6?= =?UTF-8?q?=E3=81=84=E3=81=AA=E3=81=84=E3=83=A9=E3=82=A4=E3=83=96=E3=83=A9?= =?UTF-8?q?=E3=83=AA=E3=82=92=E5=89=8A=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- launch/display.launch.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/launch/display.launch.py b/launch/display.launch.py index 8fec3ad..6b857b4 100644 --- a/launch/display.launch.py +++ b/launch/display.launch.py @@ -3,8 +3,6 @@ from ament_index_python.packages import get_package_share_directory from sciurus17_description.robot_description_loader import RobotDescriptionLoader from launch import LaunchDescription -from launch.actions import DeclareLaunchArgument -from launch.substitutions import LaunchConfiguration from launch_ros.actions import Node From 66e00c83f50cd93c30ecda277a612a3faaa84063 Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 6 Oct 2023 16:57:52 +0900 Subject: [PATCH 10/14] =?UTF-8?q?macro=E3=81=AE=E5=BC=95=E6=95=B0=E3=81=AB?= =?UTF-8?q?=E3=82=88=E3=82=8B=E3=83=91=E3=83=A9=E3=83=A1=E3=83=BC=E3=82=BF?= =?UTF-8?q?=E8=A8=AD=E5=AE=9A=E3=82=92=E5=89=8A=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- urdf/sciurus17.urdf.xacro | 87 ++++--------------------------- urdf/sciurus17_body.xacro | 24 +++------ urdf/sciurus17_head.xacro | 33 +++++------- urdf/sciurus17_left_arm.xacro | 90 +++++++++++++-------------------- urdf/sciurus17_left_hand.xacro | 30 +++++------ urdf/sciurus17_right_arm.xacro | 90 +++++++++++++-------------------- urdf/sciurus17_right_hand.xacro | 30 +++++------ 7 files changed, 127 insertions(+), 257 deletions(-) diff --git a/urdf/sciurus17.urdf.xacro b/urdf/sciurus17.urdf.xacro index dec3f80..bae6543 100644 --- a/urdf/sciurus17.urdf.xacro +++ b/urdf/sciurus17.urdf.xacro @@ -186,81 +186,16 @@ - - - - - - - - - - - - - - - - - + + + + + + + + + + + diff --git a/urdf/sciurus17_body.xacro b/urdf/sciurus17_body.xacro index 41ae2eb..e4d6753 100644 --- a/urdf/sciurus17_body.xacro +++ b/urdf/sciurus17_body.xacro @@ -2,22 +2,14 @@ - + - + @@ -37,10 +29,10 @@ + lower="${NAME_JOINT_BODY_LOWER_LIMIT}" + upper="${NAME_JOINT_BODY_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -50,7 +42,7 @@ - + @@ -77,7 +69,7 @@ - + diff --git a/urdf/sciurus17_head.xacro b/urdf/sciurus17_head.xacro index 74521ea..0a74484 100644 --- a/urdf/sciurus17_head.xacro +++ b/urdf/sciurus17_head.xacro @@ -2,26 +2,17 @@ - + + lower="${JOINT_NECK_1_LOWER_LIMIT}" + upper="${JOINT_NECK_1_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -31,7 +22,7 @@ - + @@ -50,10 +41,10 @@ + lower="${JOINT_NECK_2_LOWER_LIMIT}" + upper="${JOINT_NECK_2_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -64,7 +55,7 @@ - + @@ -91,7 +82,7 @@ - + diff --git a/urdf/sciurus17_left_arm.xacro b/urdf/sciurus17_left_arm.xacro index 6eb20cd..519ccf3 100644 --- a/urdf/sciurus17_left_arm.xacro +++ b/urdf/sciurus17_left_arm.xacro @@ -2,35 +2,17 @@ - + + lower="${JOINT_ARM_L_1_LOWER_LIMIT}" + upper="${JOINT_ARM_L_1_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -41,7 +23,7 @@ - + @@ -61,10 +43,10 @@ + lower="${JOINT_ARM_L_2_LOWER_LIMIT}" + upper="${JOINT_ARM_L_2_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -75,7 +57,7 @@ - + @@ -95,10 +77,10 @@ + lower="${JOINT_ARM_L_3_LOWER_LIMIT}" + upper="${JOINT_ARM_L_3_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -109,7 +91,7 @@ - + @@ -129,10 +111,10 @@ + lower="${JOINT_ARM_L_4_LOWER_LIMIT}" + upper="${JOINT_ARM_L_4_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -143,7 +125,7 @@ - + @@ -163,10 +145,10 @@ + lower="${JOINT_ARM_L_5_LOWER_LIMIT}" + upper="${JOINT_ARM_L_5_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -177,7 +159,7 @@ - + @@ -222,7 +204,7 @@ - + @@ -237,10 +219,10 @@ + lower="${JOINT_ARM_L_6_LOWER_LIMIT}" + upper="${JOINT_ARM_L_6_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -251,7 +233,7 @@ - + @@ -271,10 +253,10 @@ + lower="${JOINT_ARM_L_7_LOWER_LIMIT}" + upper="${JOINT_ARM_L_7_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> diff --git a/urdf/sciurus17_left_hand.xacro b/urdf/sciurus17_left_hand.xacro index 7d5c140..31750f1 100644 --- a/urdf/sciurus17_left_hand.xacro +++ b/urdf/sciurus17_left_hand.xacro @@ -2,13 +2,7 @@ - + @@ -16,7 +10,7 @@ - + @@ -36,10 +30,10 @@ + lower="${JOINT_HAND_L_LOWER_LIMIT}" + upper="${JOINT_HAND_L_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -50,7 +44,7 @@ - + @@ -70,10 +64,10 @@ + lower="${JOINT_HAND_L_LOWER_LIMIT}" + upper="${JOINT_HAND_L_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -85,7 +79,7 @@ - + diff --git a/urdf/sciurus17_right_arm.xacro b/urdf/sciurus17_right_arm.xacro index 41b45ad..e95558f 100644 --- a/urdf/sciurus17_right_arm.xacro +++ b/urdf/sciurus17_right_arm.xacro @@ -2,35 +2,17 @@ - + + lower="${JOINT_ARM_R_1_LOWER_LIMIT}" + upper="${JOINT_ARM_R_1_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -41,7 +23,7 @@ - + @@ -61,10 +43,10 @@ + lower="${JOINT_ARM_R_2_LOWER_LIMIT}" + upper="${JOINT_ARM_R_2_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -75,7 +57,7 @@ - + @@ -95,10 +77,10 @@ + lower="${JOINT_ARM_R_3_LOWER_LIMIT}" + upper="${JOINT_ARM_R_3_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -109,7 +91,7 @@ - + @@ -129,10 +111,10 @@ + lower="${JOINT_ARM_R_4_LOWER_LIMIT}" + upper="${JOINT_ARM_R_4_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -143,7 +125,7 @@ - + @@ -163,10 +145,10 @@ + lower="${JOINT_ARM_R_5_LOWER_LIMIT}" + upper="${JOINT_ARM_R_5_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -177,7 +159,7 @@ - + @@ -222,7 +204,7 @@ - + @@ -237,10 +219,10 @@ + lower="${JOINT_ARM_R_6_LOWER_LIMIT}" + upper="${JOINT_ARM_R_6_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -251,7 +233,7 @@ - + @@ -271,10 +253,10 @@ + lower="${JOINT_ARM_R_7_LOWER_LIMIT}" + upper="${JOINT_ARM_R_7_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> diff --git a/urdf/sciurus17_right_hand.xacro b/urdf/sciurus17_right_hand.xacro index f2d5f2c..036ac35 100644 --- a/urdf/sciurus17_right_hand.xacro +++ b/urdf/sciurus17_right_hand.xacro @@ -2,13 +2,7 @@ - + @@ -16,7 +10,7 @@ - + @@ -36,10 +30,10 @@ + lower="${JOINT_HAND_R_LOWER_LIMIT}" + upper="${JOINT_HAND_R_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -51,7 +45,7 @@ - + @@ -71,10 +65,10 @@ + lower="${JOINT_HAND_R_LOWER_LIMIT}" + upper="${JOINT_HAND_R_UPPER_LIMIT}" + effort="${EFFORT_LIMIT}" + velocity="${VELOCITY_LIMIT}"/> @@ -87,7 +81,7 @@ - + From 458f068e89fb5efb609a8ff18b4751f64002094c Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 6 Oct 2023 18:07:35 +0900 Subject: [PATCH 11/14] =?UTF-8?q?author=E3=82=BF=E3=82=B0=E6=9B=B4?= =?UTF-8?q?=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/package.xml b/package.xml index e304614..fd11130 100644 --- a/package.xml +++ b/package.xml @@ -9,6 +9,7 @@ Hiroyuki Nomura ShotaAk + Atsushi Kuwagata ament_cmake From 2474bfae8c553c153811a134922e96b39cdd5a86 Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 6 Oct 2023 18:10:06 +0900 Subject: [PATCH 12/14] =?UTF-8?q?camera=E3=81=AEproperty=E5=90=8D=E5=A4=89?= =?UTF-8?q?=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- urdf/sciurus17.urdf.xacro | 4 ++-- urdf/sciurus17_head.xacro | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/urdf/sciurus17.urdf.xacro b/urdf/sciurus17.urdf.xacro index bae6543..ef0e162 100644 --- a/urdf/sciurus17.urdf.xacro +++ b/urdf/sciurus17.urdf.xacro @@ -21,7 +21,7 @@ - + @@ -52,7 +52,7 @@ - + diff --git a/urdf/sciurus17_head.xacro b/urdf/sciurus17_head.xacro index 0a74484..c13deea 100644 --- a/urdf/sciurus17_head.xacro +++ b/urdf/sciurus17_head.xacro @@ -70,13 +70,13 @@ - + - + - + @@ -98,7 +98,7 @@ Gazebo/White - + Gazebo/Black From a738beb78d049cceecad0afed9a5a3d5c4f43ab5 Mon Sep 17 00:00:00 2001 From: Kuwagata Date: Fri, 6 Oct 2023 18:59:02 +0900 Subject: [PATCH 13/14] =?UTF-8?q?=E3=83=A6=E3=83=8B=E3=83=83=E3=83=88?= =?UTF-8?q?=E3=83=86=E3=82=B9=E3=83=88=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CMakeLists.txt | 2 +- test/test_robot_description_loader.py | 27 +++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 test/test_robot_description_loader.py diff --git a/CMakeLists.txt b/CMakeLists.txt index 4971666..4e57676 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -21,7 +21,7 @@ if(BUILD_TESTING) ament_lint_auto_find_test_dependencies() find_package(ament_cmake_pytest REQUIRED) - # ament_add_pytest_test(test_robot_description_loader test/test_robot_description_loader.py) + ament_add_pytest_test(test_robot_description_loader test/test_robot_description_loader.py) endif() ament_package() diff --git a/test/test_robot_description_loader.py b/test/test_robot_description_loader.py new file mode 100644 index 0000000..b81365d --- /dev/null +++ b/test/test_robot_description_loader.py @@ -0,0 +1,27 @@ +# Copyright 2023 RT Corporation + +from sciurus17_description.robot_description_loader import RobotDescriptionLoader +from launch.launch_context import LaunchContext +import pytest + + +def exec_load(loader): + # Command substitutionの実行方法はCommandのテストを参考にした + # https://github.com/ros2/launch/blob/074cd2903ddccd61bce8f40a0f58da0b7c200481/launch/test/launch/substitutions/test_command.py#L47 + context = LaunchContext() + return loader.load().perform(context) + + +def test_load_description(): + # xacroの読み込みが成功することを期待 + rdl = RobotDescriptionLoader() + assert exec_load(rdl) + + +def test_change_description_path(): + # xacroのファイルパスを変更し、読み込みが失敗することを期待 + rdl = RobotDescriptionLoader() + rdl.robot_description_path = 'hoge' + with pytest.raises(Exception) as e: + exec_load(rdl) + assert e.value From 2bbecb077145974995c9306a08f9e7e1491e1751 Mon Sep 17 00:00:00 2001 From: Kuwamai Date: Wed, 11 Oct 2023 15:31:18 +0900 Subject: [PATCH 14/14] =?UTF-8?q?=E9=A0=AD=E9=83=A8=E3=82=AB=E3=83=A1?= =?UTF-8?q?=E3=83=A9=E3=83=AA=E3=83=B3=E3=82=AF=E3=82=92head=5Fcamera=5Fli?= =?UTF-8?q?nk=E3=81=AB=E5=A4=89=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Shota Aoki --- urdf/sciurus17.urdf.xacro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/urdf/sciurus17.urdf.xacro b/urdf/sciurus17.urdf.xacro index ef0e162..e78f95d 100644 --- a/urdf/sciurus17.urdf.xacro +++ b/urdf/sciurus17.urdf.xacro @@ -21,7 +21,7 @@ - +