Hi,
I am trying out “add ros_control to ur5 manipulator robot” quiz and I have successfully completed the first part of the quiz where I used the
controllers of the type:
position_controllers/JointPositionController.
In the 2nd part of the quiz I made my new package called project_controller, and followed all the steps that were covered in the earlier chapters and finally did a catkin_make with 0 errors.
Using rospack plugins gives me the following output:
rospack plugins --attrib=plugin controller_interface | grep project_controller
project_controller /home/user/catkin_ws/src/project_controller/controller_plugins.xml
But when I try to use this controller with the ur5 it fails to load it, I tested the same controller by changing the .yaml and launch files and they work perfectly fine with the rrbot .
my_controller.yaml (I tried it out with only one joint)
ur5:
joint_state_controller:
type: joint_state_controller/JointStateController
publish_rate: 50
shoulder_lift_joint_position_controller:
type: project_controller/PositionController
joint: shoulder_lift_joint
pid: {p: 100.0, i: 0.01, d: 10.0}
my launch file: (for only one joint)
<launch>
<!-- Load joint controller configurations from YAML file to parameter server -->
<rosparam file="$(find project_controller)/config/my_controller.yaml" command="load"/>
<!-- load the controllers -->
<node name="controller_spawner" pkg="controller_manager" type="spawner" respawn="false"
output="screen" ns="/ur5" args="joint_state_controller shoulder_lift_joint_position_controller"/>
<node name="robot_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher"
respawn="false" output="screen">
<remap from="/joint_states" to="/ur5/joint_states" />
</node>
</launch>
Any help or suggestions on how to solve this would be highly appreciated.
TIA
Hello @textzip ,
Do you get any error messages?
Hi @albertoezquerro , When I try to run the final launch file, the joint with the custom controller fails, other than that I did not encounter any errors.
output for `roslaunch proejct_controller quiz_control_custom.launch`
roslaunch project_controller quiz_control_custom.launch... logging to /home/user/.ros/log/a072b0de-4e68-11eb-b871-0242ac190007/roslaunch-13_xterm-1280.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://13_xterm:46153/
SUMMARY
========
PARAMETERS
* /rosdistro: kinetic
* /rosversion: 1.12.14
* /ur5/elbow_joint_position_controller/joint: elbow_joint
* /ur5/elbow_joint_position_controller/pid/d: 10.0
* /ur5/elbow_joint_position_controller/pid/i: 0.01
* /ur5/elbow_joint_position_controller/pid/p: 100.0
* /ur5/elbow_joint_position_controller/type: position_controll...
* /ur5/joint_state_controller/publish_rate: 50
* /ur5/joint_state_controller/type: joint_state_contr...
* /ur5/shoulder_lift_joint_position_controller/joint: shoulder_lift_joint
* /ur5/shoulder_lift_joint_position_controller/pid/d: 10.0
* /ur5/shoulder_lift_joint_position_controller/pid/i: 0.01
* /ur5/shoulder_lift_joint_position_controller/pid/p: 100.0
* /ur5/shoulder_lift_joint_position_controller/type: project_controlle...
* /ur5/shoulder_pan_joint_position_controller/joint: shoulder_pan_joint
* /ur5/shoulder_pan_joint_position_controller/pid/d: 10.0
* /ur5/shoulder_pan_joint_position_controller/pid/i: 0.01
* /ur5/shoulder_pan_joint_position_controller/pid/p: 100.0
* /ur5/shoulder_pan_joint_position_controller/type: position_controll...
* /ur5/wrist_1_joint_position_controller/joint: wrist_1_joint
* /ur5/wrist_1_joint_position_controller/pid/d: 10.0
* /ur5/wrist_1_joint_position_controller/pid/i: 0.01
* /ur5/wrist_1_joint_position_controller/pid/p: 100.0
* /ur5/wrist_1_joint_position_controller/type: position_controll...
* /ur5/wrist_2_joint_position_controller/joint: wrist_2_joint
* /ur5/wrist_2_joint_position_controller/pid/d: 10.0
* /ur5/wrist_2_joint_position_controller/pid/i: 0.01
* /ur5/wrist_2_joint_position_controller/pid/p: 100.0
* /ur5/wrist_2_joint_position_controller/type: position_controll...
* /ur5/wrist_3_joint_position_controller/joint: wrist_3_joint
* /ur5/wrist_3_joint_position_controller/pid/d: 10.0
* /ur5/wrist_3_joint_position_controller/pid/i: 0.01
* /ur5/wrist_3_joint_position_controller/pid/p: 100.0
* /ur5/wrist_3_joint_position_controller/type: position_controll...
NODES
/ur5/
controller_spawner (controller_manager/spawner)
/
robot_state_publisher (robot_state_publisher/robot_state_publisher)
ROS_MASTER_URI=http://13_simulation:11311
process[ur5/controller_spawner-1]: started with pid [1289]
process[robot_state_publisher-2]: started with pid [1290]
[INFO] [1609749735.490732, 0.000000]: Controller Spawner: Waiting for service controller_manager/load_controller
[INFO] [1609749735.497430, 0.000000]: Controller Spawner: Waiting for service controller_manager/switch_controller
[INFO] [1609749735.501107, 0.000000]: Controller Spawner: Waiting for service controller_manager/unload_controller
[INFO] [1609749735.505093, 0.000000]: Loading controller: joint_state_controller
[INFO] [1609749735.530526, 45.253000]: Loading controller: shoulder_pan_joint_position_controller
[INFO] [1609749735.574081, 45.296000]: Loading controller: shoulder_lift_joint_position_controller
[ERROR] [1609749736.580323, 46.302000]: Failed to load shoulder_lift_joint_position_controller
[INFO] [1609749736.581062, 46.303000]: Loading controller: elbow_joint_position_controller
[INFO] [1609749736.603331, 46.325000]: Loading controller: wrist_1_joint_position_controller
[INFO] [1609749736.622679, 46.344000]: Loading controller: wrist_2_joint_position_controller
[INFO] [1609749736.637369, 46.358000]: Loading controller: wrist_3_joint_position_controller
[INFO] [1609749736.654641, 46.376000]: Controller Spawner: Loaded controllers: joint_state_controller, shoulder_pan_joint_position_controller, elbow_joint_position_controller, wrist_1_joint_position_controller, wrist_2_joint_position_controller, wrist_3_joint_position_controller
[INFO] [1609749736.659352, 46.381000]: Started controllers: joint_state_controller, shoulder_pan_joint_position_controller, elbow_joint_position_controller, wrist_1_joint_position_controller, wrist_2_joint_position_controller, wrist_3_joint_position_controller
TIA
Hello @textzip ,
Can you please send me the package you are using to aezquerro@theconstructsim.com ? I’ll test it manually.
Best,
1 Like
same problem here. I will send you the package, please
Same issue, in the quiz and in Unit 4! Should i send my package @albertoezquerro ?
Also i had to #include string
Greetings Jan
comm
April 17, 2021, 5:00pm
8
I’m having the same issue - was this ever solved?
I’ll email my files
/K
Output:
user:~$ roslaunch quiz_control quiz_control.launch
... logging to /home/user/.ros/log/d330d484-9f9d-11eb-9f78-0242ac1b0008/roslaunch-2_xterm-1366.log
Checking log directory for disk usage. This may take a while.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://2_xterm:42627/
SUMMARY
========
PARAMETERS
* /rosdistro: noetic
* /rosversion: 1.15.9
* /ur5/joint_state_controller/publish_rate: 50
* /ur5/joint_state_controller/type: joint_state_contr...
* /ur5/shoulder_lift_joint_position_controller/joint: shoulder_lift_joint
* /ur5/shoulder_lift_joint_position_controller/pid/d: 10.0
* /ur5/shoulder_lift_joint_position_controller/pid/i: 0.01
* /ur5/shoulder_lift_joint_position_controller/pid/p: 100.0
* /ur5/shoulder_lift_joint_position_controller/type: effort_controller...
* /ur5/shoulder_pan_joint_position_controller/joint: shoulder_pan_joint
* /ur5/shoulder_pan_joint_position_controller/pid/d: 10.0
* /ur5/shoulder_pan_joint_position_controller/pid/i: 0.01
* /ur5/shoulder_pan_joint_position_controller/pid/p: 100.0
* /ur5/shoulder_pan_joint_position_controller/type: effort_controller...
* /ur5/wrist_1_joint_position_controller/joint: wrist_1_joint
* /ur5/wrist_1_joint_position_controller/pid/d: 10.0
* /ur5/wrist_1_joint_position_controller/pid/i: 0.01
* /ur5/wrist_1_joint_position_controller/pid/p: 100.0
* /ur5/wrist_1_joint_position_controller/type: effort_controller...
* /ur5/wrist_2_joint_position_controller/joint: wrist_2_joint
* /ur5/wrist_2_joint_position_controller/pid/d: 10.0
* /ur5/wrist_2_joint_position_controller/pid/i: 0.01
* /ur5/wrist_2_joint_position_controller/pid/p: 100.0
* /ur5/wrist_2_joint_position_controller/type: effort_controller...
* /ur5/wrist_3_joint_position_controller/joint: wrist_3_joint
* /ur5/wrist_3_joint_position_controller/pid/d: 10.0
* /ur5/wrist_3_joint_position_controller/pid/i: 0.01
* /ur5/wrist_3_joint_position_controller/pid/p: 100.0
* /ur5/wrist_3_joint_position_controller/type: effort_controller...
NODES
/
robot_state_publisher (robot_state_publisher/robot_state_publisher)
/ur5/
controller_spawner (controller_manager/spawner)
ROS_MASTER_URI=http://2_simulation:11311
process[ur5/controller_spawner-1]: started with pid [1374]
process[robot_state_publisher-2]: started with pid [1375]
[INFO] [1618678729.899015, 0.000000]: Controller Spawner: Waiting for service controller_manager/load_controller
[INFO] [1618678729.903587, 0.000000]: Controller Spawner: Waiting for service controller_manager/switch_controller
[INFO] [1618678729.920555, 0.000000]: Controller Spawner: Waiting for service controller_manager/unload_controller
[INFO] [1618678729.941823, 144.749000]: Loading controller: shoulder_lift_joint_position_controller
[ERROR] [1618678731.059529, 145.703000]: Failed to load shoulder_lift_joint_position_controller
[INFO] [1618678731.061830, 145.704000]: Loading controller: shoulder_pan_joint_position_controller
[ERROR] [1618678732.112516, 146.665000]: Failed to load shoulder_pan_joint_position_controller
[INFO] [1618678732.115274, 146.669000]: Loading controller: effort_controllers/JointPositionController
[ERROR] [1618678733.123342, 147.597000]: Failed to load effort_controllers/JointPositionController
[INFO] [1618678733.125484, 147.597000]: Loading controller: wrist_2_joint_position_controller
[ERROR] [1618678734.177214, 148.520000]: Failed to load wrist_2_joint_position_controller
[INFO] [1618678734.179316, 148.521000]: Loading controller: wrist_3_joint_position_controller
[ERROR] [1618678735.222761, 149.469000]: Failed to load wrist_3_joint_position_controller
[INFO] [1618678735.225697, 149.471000]: Loading controller: joint_state_controller
[INFO] [1618678735.273157, 149.512000]: Controller Spawner: Loaded controllers: joint_state_controller
[INFO] [1618678735.292543, 149.524000]: Started controllers: joint_state_controller
comm
April 22, 2021, 9:58pm
9
For anyone with the same issue, I did end up solving this.
See this post: Quiz help - failed to load joint_position_controller
/K
2 Likes
xj2106
March 16, 2022, 2:37am
10
@albertoezquerro Hello, Ezquerro. I am having the same issue. I have sent two of my pkgs to your emails. Can you please take a look at it? Thank you very much!
This topic was automatically closed after 24 hours. New replies are no longer allowed.