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

add yamls and launch file for demo3 #19

Draft
wants to merge 2 commits into
base: humble-devel
Choose a base branch
from
Draft
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
32 changes: 32 additions & 0 deletions agimus_demo_03_mpc_dummy_traj/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
cmake_minimum_required(VERSION 3.22.1)

#
# Project definition
#
project(agimus_demo_03_mpc_dummy_traj LANGUAGES CXX)


#
# Handle dependencies by reading the package.xml
#
find_package(ament_cmake_auto REQUIRED)
ament_auto_find_build_dependencies()

#
# Unit tests
#
include(CTest)
if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)
ament_auto_find_test_dependencies()
# Integration test of the roscontrol controller with simulation on Talos.
# add_rostest(tests/test_integration.py)
endif()

#
# Installation
#
install(DIRECTORY config DESTINATION share/${PROJECT_NAME})
install(DIRECTORY launch DESTINATION share/${PROJECT_NAME})

ament_auto_package()
Comment on lines +1 to +32
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
cmake_minimum_required(VERSION 3.22.1)
#
# Project definition
#
project(agimus_demo_03_mpc_dummy_traj LANGUAGES CXX)
#
# Handle dependencies by reading the package.xml
#
find_package(ament_cmake_auto REQUIRED)
ament_auto_find_build_dependencies()
#
# Unit tests
#
include(CTest)
if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)
ament_auto_find_test_dependencies()
# Integration test of the roscontrol controller with simulation on Talos.
# add_rostest(tests/test_integration.py)
endif()
#
# Installation
#
install(DIRECTORY config DESTINATION share/${PROJECT_NAME})
install(DIRECTORY launch DESTINATION share/${PROJECT_NAME})
ament_auto_package()
cmake_minimum_required(VERSION 3.22.1)
project(agimus_demo_03_mpc_dummy_traj)
find_package(ament_cmake REQUIRED)
install(DIRECTORY
launch
config
DESTINATION share/${PROJECT_NAME}/
)
ament_package()

Isn't it simpler? There is not code so there is no need to expect anything related to C++ and testing

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There will be integration tests here so yes we should keep the things + we can use the linting of ROS if we want.
Though I guess with pre-commit it's gonna conflict...

15 changes: 15 additions & 0 deletions agimus_demo_03_mpc_dummy_traj/config/controller_manager.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
controller_manager:
ros__parameters:
update_rate: 1000 # Hz

linear_feedback_controller:
type: linear_feedback_controller/LinearFeedbackController

joint_state_estimator:
type: linear_feedback_controller/JointStateEstimator

joint_state_broadcaster:
type: joint_state_broadcaster/JointStateBroadcaster

franka_robot_state_broadcaster:
type: franka_robot_state_broadcaster/FrankaRobotStateBroadcaster
27 changes: 27 additions & 0 deletions agimus_demo_03_mpc_dummy_traj/config/joint_state_estimator.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
joint_state_estimator:
ros__parameters:
type: linear_feedback_controller/JointStateEstimator
interfaces: [
'fer_joint1/position',
'fer_joint2/position',
'fer_joint3/position',
'fer_joint4/position',
'fer_joint5/position',
'fer_joint6/position',
'fer_joint7/position',
'fer_joint1/velocity',
'fer_joint2/velocity',
'fer_joint3/velocity',
'fer_joint4/velocity',
'fer_joint5/velocity',
'fer_joint6/velocity',
'fer_joint7/velocity',
'fer_joint1/effort',
'fer_joint2/effort',
'fer_joint3/effort',
'fer_joint4/effort',
'fer_joint5/effort',
'fer_joint6/effort',
'fer_joint7/effort'
]
command_prefix: "linear_feedback_controller"
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
linear_feedback_controller:
ros__parameters:
type: linear_feedback_controller/LinearFeedbackController
moving_joint_names: [
'fer_joint1',
'fer_joint2',
'fer_joint3',
'fer_joint4',
'fer_joint5',
'fer_joint6',
'fer_joint7'
]
fer_joint1:
p: 60.0
d: 5.0
fer_joint2:
p: 60.0
d: 5.0
fer_joint3:
p: 60.0
d: 5.0
fer_joint4:
p: 60.0
d: 2.0
fer_joint5:
p: 20.0
d: 2.0
fer_joint6:
p: 10.0
d: 2.0
fer_joint7:
p: 5.0
d: 1.0
chainable_controller:
command_prefix: ''
reference_prefix: ''
joint_velocity_filter_coefficient: 0.9
pd_to_lf_transition_duration: 0.1
remove_gravity_compensation_effort: true
robot_has_free_flyer: false
32 changes: 32 additions & 0 deletions agimus_demo_03_mpc_dummy_traj/config/mpc_params.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
agimus_controller_node:
ros__parameters:
ocp:
dt: 0.01
horizon_size: 20
armature: [0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1]
gripper_weight: 500
state_weight: 5
control_weight: 0.001
max_qp_iter: 100
max_iter: 10
use_constraints: True
activate_callback: False
increasing_weights:
max: 100.0
percent: 0.9
time_reach_percent: 6
effector_frame_name: "fer_link8"
moving_joint_names:
[
"fer_joint1",
"fer_joint2",
"fer_joint3",
"fer_joint4",
"fer_joint5",
"fer_joint6",
"fer_joint7",
]
save_predictions_and_refs: True
rate: 100
package_name: "agimus_demo_03_mpc_dummy_traj"
path_to_yaml: "config/mpc_params.yaml"
35 changes: 35 additions & 0 deletions agimus_demo_03_mpc_dummy_traj/dependencies.repos
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
repositories:
vcs_repos/linear_feedback_controller_msgs:
type: git
url: https://github.com/loco-3d/linear-feedback-controller-msgs
version: 0.1.3

vcs_repos/coal:
type: git
url: https://github.com/coal-library/coal
version: v3.0.0

vcs_repos/pinocchio:
type: git
url: https://github.com/stack-of-tasks/pinocchio
version: v3.3.0

vcs_repos/colmpc:
type: git
url: https://github.com/agimus-project/colmpc
version: v0.2.0 # TODO: change to new version tag

vcs_repos/mim_solvers:
type: git
url: https://github.com/machines-in-motion/mim_solvers
version: v0.0.3

vcs_repos/franka_ros:
type: git
url: https://github.com/frankaemika/franka_ros
version: develop
Comment on lines +27 to +30
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
vcs_repos/franka_ros:
type: git
url: https://github.com/frankaemika/franka_ros
version: develop
vcs_repos/franka_ros:
type: git
url: https://github.com/frankaemika/franka_ros2
version: v0.1.15

Didn't we end up forking franka_ros2 in the end?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


vcs_repos/agimus_controller:
type: git
url: https://github.com/agimus-project/agimus_controller
version: humble-devel
Loading