Add computed_torque_controller configuration.
Add pid_plus_gravity_controller configuration.
--- /dev/null
+/computed_torque_controller:
+ ros__parameters:
+ joints:
+ - shoulder_active_joint
+ - elbow_active_joint
+ Kp: [2500.0, 0.0, 0.0, 300.0]
+ Kd: [0.3, 0.0, 0.0, 0.3]
+ gravity: {x: 0.0, y: 0.0, z: -9.8}
+ chain: {root: "origin_link", tip: "tool_link"}
+ priority: 99
--- /dev/null
+/pid_plus_gravity_controller:
+ ros__parameters:
+ joints:
+ - shoulder_active_joint
+ - elbow_active_joint
+ shoulder_active_joint: {p: 2310.0, i: 4640.0, d: 0.299, i_clamp_max: 27.94, i_clamp_min: -27.94}
+ elbow_active_joint: {p: 339.0, i: 851.0, d: 0.351, i_clamp_max: 13.62, i_clamp_min: -13.62}
+ gravity: {x: 0.0, y: 0.0, z: -9.8}
+ chain: {root: "origin_link", tip: "tool_link"}
+ priority: 99
--- /dev/null
+<!--******************************************************************************
+ Quanser 2DSFJE Bringup
+ Computed Torque Controller Launch File
+ Copyright (C) 2021 Walter Fetter Lages <w.fetter@ieee.org>
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Geneal Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see
+ <http://www.gnu.org/licenses/>.
+
+*******************************************************************************-->
+
+<launch>
+ <arg name="config" default="$(find-pkg-share q2d_bringup)/config/computed_torque.yaml"/>
+
+ <node name="computed_torque_controller_spawner" pkg="controller_manager" exec="spawner"
+ args="-t effort_controllers/ComputedTorqueController -p $(var config) computed_torque_controller"/>
+
+ <node name="joint_state_broadcaster_spawner" pkg="controller_manager" exec="spawner"
+ args="-t joint_state_broadcaster/JointStateBroadcaster joint_state_broadcaster"/>
+</launch>
--- /dev/null
+<!--******************************************************************************
+ Quanser 2DSFJE Bringup
+ PID+gravity Controller Launch File
+ Copyright (C) 2021 Walter Fetter Lages <w.fetter@ieee.org>
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Geneal Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see
+ <http://www.gnu.org/licenses/>.
+
+*******************************************************************************-->
+
+<launch>
+ <arg name="config" default="$(find-pkg-share q2d_bringup)/config/pid_plus_gravity.yaml"/>
+
+ <node name="pid_plus_gravity_controller_spawner" pkg="controller_manager" exec="spawner"
+ args="-t effort_controllers/PidPlusGravityController -p $(var config) pid_plus_gravity_controller"/>
+
+ <node name="joint_state_broadcaster_spawner" pkg="controller_manager" exec="spawner"
+ args="-t joint_state_broadcaster/JointStateBroadcaster joint_state_broadcaster"/>
+</launch>
+<!--******************************************************************************
+ Quanser 2DSFJE Description
+ Gazebo Launch File
+ Copyright (C) 2018, 2021 Walter Fetter Lages <w.fetter@ieee.org>
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Geneal Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see
+ <http://www.gnu.org/licenses/>.
+
+*******************************************************************************-->
+
<launch>
<arg name="pause" default="true"/>
<arg name="gui" default="true"/>
<arg name="use_sim_time" default="true"/>
- <set_env name="GAZEBO_MODEL_PATH" value="$(env GAZEBO_MODEL_PATH ''):$(find-pkg-prefix q2d_description)/share/"/>
-
<include file="$(find-pkg-share gazebo_ros)/launch/gazebo.launch.py">
<arg name="pause" value="$(var pause)"/>
<arg name="gui" value="$(var gui)"/>
<arg name="use_sim_time" value="$(var use_sim_time)"/>
<arg name="world" value="worlds/empty_sky.world" />
- <arg name="extra_gazebo_args" value=" --ros-args --params-file $(find-pkg-share q2d_description)/config/gazebo.yaml"/>
+ <arg name="extra_gazebo_args" value="--ros-args --params-file $(find-pkg-share q2d_description)/config/gazebo.yaml"/>
</include>
<include file="$(find-pkg-share q2d_description)/launch/q2d.launch.xml">
<export>
<build_type>ament_cmake</build_type>
+ <gazebo_ros gazebo_model_path="${prefix}/.."/>
</export>
</package>