Use several UR arm with one robot and UR5KinematicsPlugin
I'm building a robot which is made of four ur5 arms. So I created a folder with every packages needed (ctrl-bot_gazebo, ctrl-bot_description, ctrl-bot_moveit_config). I spend time configuring and now I can do plan planning with RVIZ+Moveit for each arm of the robot.
After days of configuration everything can work (almost everything). I can do path planning and see in gazebo the movement. When I try the UR5 alone I found that this solver is amazingly fast (less than 100ms most of the time) compared to kld_kinematics_plugin/KLDKinematicsPlugin
My problem is that I can't use the ur_kinematics/UR5KinematicsPlugin because I added a prefix to each arm (N1_, N2_, N3_, N4_). So to build my robot I load 4 times a ur5 arm with 4 different prefixes in my robot's urdf.
If I choose the ur_kinematics/UR5KinematicsPlugin for my robot I get some error : I launch roslaunch ctrl-bot_moveit_config ctrl-bot_moveit_planning_execution.launch sim:=true
Then I get this
[ERROR] [1431072866.823796592, 3808.550000000]: Kin chain provided in model doesn't contain standard UR joint 'shoulder_lift_joint'.
[ERROR] [1431072866.823849841, 3808.550000000]: Kinematics solver of type 'ur_kinematics/UR5KinematicsPlugin' could not be initialized for group 'N1_manipulator'
[ERROR] [1431072866.824097006, 3808.550000000]: Kinematics solver could not be instantiated for joint group N1_manipulator.
It seems than the solver is reverted to default because ur_kinematics expect the name without prefixes. However if I look at ur_kinematics/src/ur_moveit_plugin.cpp :
ur_joint_names_.push_back(arm_prefix_ + "shoulder_pan_joint");
ur_joint_names_.push_back(arm_prefix_ + "shoulder_lift_joint");
.......
It looks like it can be used with prefixes, but I have no clue of How to do it.
The kld_kinematics_plugin/KLDKinematicsPlugin need 3 seconds or more to compute and can fail a lot of time. Even if I enable replanning.
So my goal is to be able to use ur_kinematics solver but with my robot. I don't understand why ur_description is designed to be used with prefixes but the ur_kinematics solver is not. Maybe I'm missing something obvious.