diff --git a/sciurus17_description/robot_description_loader.py b/sciurus17_description/robot_description_loader.py index aa80469..9f87fd5 100755 --- a/sciurus17_description/robot_description_loader.py +++ b/sciurus17_description/robot_description_loader.py @@ -13,9 +13,11 @@ def __init__(self): get_package_share_directory('sciurus17_description'), 'urdf', 'sciurus17.urdf.xacro') + self.use_gazebo = 'false' def load(self): return Command([ 'xacro ', - self.robot_description_path + self.robot_description_path, + ' use_gazebo:=', self.use_gazebo ]) diff --git a/test/test_robot_description_loader.py b/test/test_robot_description_loader.py index b81365d..447c193 100644 --- a/test/test_robot_description_loader.py +++ b/test/test_robot_description_loader.py @@ -25,3 +25,10 @@ def test_change_description_path(): with pytest.raises(Exception) as e: exec_load(rdl) assert e.value + + +def test_use_gazebo(): + # use_gazeboが変更され、xacroにgazeboタグがセットされることを期待 + rdl = RobotDescriptionLoader() + rdl.use_gazebo = 'true' + assert ' - + + + + + + @@ -129,55 +139,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -198,4 +159,7 @@ + + + diff --git a/urdf/sciurus17_body.xacro b/urdf/sciurus17_body.xacro index e4d6753..99237bb 100644 --- a/urdf/sciurus17_body.xacro +++ b/urdf/sciurus17_body.xacro @@ -79,16 +79,6 @@ - - Gazebo/White - - - Gazebo/White - - - Gazebo/Black - - diff --git a/urdf/sciurus17_gazebo.xacro b/urdf/sciurus17_gazebo.xacro index e1f90bb..3393116 100644 --- a/urdf/sciurus17_gazebo.xacro +++ b/urdf/sciurus17_gazebo.xacro @@ -2,168 +2,138 @@ - - - - true - 0 - 0.418 - transmission_interface/SimpleTransmission - - - hardware_interface/PositionJointInterface - - - hardware_interface/VelocityJointInterface - - - hardware_interface/EffortJointInterface - - - - - hardware_interface/PositionJointInterface - - - hardware_interface/VelocityJointInterface - - - hardware_interface/EffortJointInterface - - 1 - - + + + + 0.2 0.2 0.2 1 + 0.0 0.0 0.0 1 + + - - - 30 - - 1.39626 - - 1280 - 800 - R8G8B8 - - - 0.02 - 300 - - - gaussian - 0 - 0.007 - - - - true - 0.0 - sciurus17/chest_camera_node - image - camera_info - chest_camera_link - 0.07 - 0.0 - 0.0 - 0.0 - 0.0 - 0.0 - - 0.114576 0 0.217659 0 0.5236 0 - - - - - - 1 - 1 - - 1.047 - - 640 - 480 - B8G8R8 - - - depths - - - 0.1 - 100 - - - - sciurus17 - true - 10.0 - camera - /camera_color_optical_frame - color/image_raw - depth/image_raw - depth_registered/points - color/camera_info - depth/camera_info - 0.4 - 0.07 - 0.0 - 0.0 - 0.0 - 0.0 - 0.0 - 0.0 - 0.0 - 0.0 - 0.0 - - 0.081785 0.03522 0.091 0 -0 0 - - - - - - - - - - - - - - - - - - - - /sciurus17/controller1 - gazebo_ros_control/DefaultRobotHWSim - false - - - - /sciurus17/controller2 - gazebo_ros_control/DefaultRobotHWSim - false - - - - /sciurus17/controller3 - gazebo_ros_control/DefaultRobotHWSim - false - - - - r_hand_joint - r_hand_mimic_joint - 1.0 - - - - l_hand_joint - l_hand_mimic_joint - 1.0 - - + + + + 0.95 0.95 0.95 1 + 0.95 0.95 0.95 1 + + + + + + + + 1.0 0.3 0.3 1 + 1.0 0.0 0.0 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.8 + 0.8 + + + + + 0.8 + 0.8 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.8 + 0.8 + + + + + 0.8 + 0.8 + + + + diff --git a/urdf/sciurus17_head.xacro b/urdf/sciurus17_head.xacro index c13deea..c541495 100644 --- a/urdf/sciurus17_head.xacro +++ b/urdf/sciurus17_head.xacro @@ -92,16 +92,6 @@ - - Gazebo/White - - - Gazebo/White - - - Gazebo/Black - - diff --git a/urdf/sciurus17_left_arm.xacro b/urdf/sciurus17_left_arm.xacro index 519ccf3..11979d3 100644 --- a/urdf/sciurus17_left_arm.xacro +++ b/urdf/sciurus17_left_arm.xacro @@ -55,14 +55,14 @@ - + - + @@ -261,25 +261,6 @@ - - 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 31750f1..adf3f34 100644 --- a/urdf/sciurus17_left_hand.xacro +++ b/urdf/sciurus17_left_hand.xacro @@ -94,16 +94,6 @@ - - Gazebo/Red - - - Gazebo/Red - - - Gazebo/Red - - diff --git a/urdf/sciurus17_right_arm.xacro b/urdf/sciurus17_right_arm.xacro index e95558f..8ceef8e 100644 --- a/urdf/sciurus17_right_arm.xacro +++ b/urdf/sciurus17_right_arm.xacro @@ -89,14 +89,14 @@ - + - + @@ -261,25 +261,6 @@ - - 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 036ac35..ee4fb70 100644 --- a/urdf/sciurus17_right_hand.xacro +++ b/urdf/sciurus17_right_hand.xacro @@ -96,16 +96,6 @@ - - Gazebo/Red - - - Gazebo/Red - - - Gazebo/Red - -