Hello,
I am working from the following Git Repos:
What I have done so far:
- ROS2 extraction of calibration file from our robot and located it in the UR10e Min Example package
- Setup the RVIZ file borrowing from standard UR description/xacro/urdf etc…
- Established communication with the UR10e hardware with external control running on the robot. Everything, including RVIZ, spools up correctly
- Tested the Cartesian simulation MuJoCo
Initial Goals
- Get this setup working with URSim rather than MuJoCo if possible?
- Safe initialization and interfacing with the real hardware
What I have tried:
- Launched URSim via ROS2 workflow/launch i.e. VNC browser etc…
- Run the UR10e Min Example by pointing it to the VNC/URSim IP while running “external control” in the sim
- Run the UR10e Min Example by pointing it to the real UR10e / robot via direct Ethernet link between Linux Laptop and UR10e control box
- error_scale set to 0 initially
Results and Observation so far:
- UR10e Sim does not seem to respond to anything via rqt etc… per the examples
- UR10e robot establishes connection but faults immediately after switching controllers JSTC to Cartesian motion / force controller with very aggressive initial behavior before immediately faulting
Questions:
- Is it possible to use Cartesian Controllers with URSim ?
- What is a safe approach to initializing the real hardware?
My own short comings
- Not entirely comfortable with robot frames/coordinates yet and even units. For example in RQT. It is unclear to me what the units and scale of force and torque are here?
- Is there some initial condition that the robot should be set to before starting any of these controllers ?
URSim UR10e Steps and Current Status Messages:
- Start URSim:
- Source Cartesian Controller Workspace: . ./install/setup.bash
- Launch Cartesian Controller: ros2 launch cartesian_controllers_universal_robots robot.launch.py
- Switch to Cartesian Controller: ros2 control switch_controllers --activate cartesian_force_controller
- Start RQT: rqt
@user~/git/cartesian_controllers$ ros2 launch cartesian_controllers_universal_robots robot.launch.py
Results in:
[INFO] [launch]: All log files can be found below /home/wgates/.ros/log/2024-09-21-09-52-03-010031-msi-25755
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [rviz2-1]: process started with pid [25774]
[INFO] [ur_ros2_control_node-2]: process started with pid [25776]
[INFO] [robot_state_publisher-3]: process started with pid [25778]
[INFO] [spawner-4]: process started with pid [25780]
[INFO] [spawner-5]: process started with pid [25782]
[INFO] [spawner-6]: process started with pid [25784]
[INFO] [spawner-7]: process started with pid [25786]
[INFO] [spawner-8]: process started with pid [25788]
[INFO] [spawner-9]: process started with pid [25790]
[INFO] [spawner-10]: process started with pid [25810]
[robot_state_publisher-3] [INFO] [1726937523.773917290] [robot_state_publisher]: got segment base
[robot_state_publisher-3] [INFO] [1726937523.774058794] [robot_state_publisher]: got segment base_link
[robot_state_publisher-3] [INFO] [1726937523.774076076] [robot_state_publisher]: got segment base_link_inertia
[robot_state_publisher-3] [INFO] [1726937523.774088539] [robot_state_publisher]: got segment flange
[robot_state_publisher-3] [INFO] [1726937523.774097789] [robot_state_publisher]: got segment forearm_link
[robot_state_publisher-3] [INFO] [1726937523.774106673] [robot_state_publisher]: got segment ft_frame
[robot_state_publisher-3] [INFO] [1726937523.774116756] [robot_state_publisher]: got segment shoulder_link
[robot_state_publisher-3] [INFO] [1726937523.774125803] [robot_state_publisher]: got segment tool0
[robot_state_publisher-3] [INFO] [1726937523.774135298] [robot_state_publisher]: got segment upper_arm_link
[robot_state_publisher-3] [INFO] [1726937523.774145805] [robot_state_publisher]: got segment world
[robot_state_publisher-3] [INFO] [1726937523.774157758] [robot_state_publisher]: got segment wrist_1_link
[robot_state_publisher-3] [INFO] [1726937523.774169474] [robot_state_publisher]: got segment wrist_2_link
[robot_state_publisher-3] [INFO] [1726937523.774178691] [robot_state_publisher]: got segment wrist_3_link
[ur_ros2_control_node-2] [WARN] [1726937524.338155095] [controller_manager]: 'update_rate' parameter not set, using default value.
[ur_ros2_control_node-2] [WARN] [1726937524.339007314] [controller_manager]: [Deprecated] Passing the robot description parameter directly to the control_manager node is deprecated. Use '~/robot_description' topic from 'robot_state_publisher' instead.
[ur_ros2_control_node-2] text not specified in the tf_prefix tag
[ur_ros2_control_node-2] [INFO] [1726937524.339622513] [resource_manager]: Loading hardware 'ur10e'
[ur_ros2_control_node-2] [INFO] [1726937524.343604108] [resource_manager]: Initialize hardware 'ur10e'
[ur_ros2_control_node-2] [INFO] [1726937524.343702689] [resource_manager]: Successful initialization of hardware 'ur10e'
[ur_ros2_control_node-2] [INFO] [1726937524.343996941] [resource_manager]: 'configure' hardware 'ur10e'
[ur_ros2_control_node-2] [INFO] [1726937524.344020894] [URPositionHardwareInterface]: Starting ...please wait...
[ur_ros2_control_node-2] [INFO] [1726937524.344040386] [URPositionHardwareInterface]: Initializing driver...
[ur_ros2_control_node-2] [INFO] [1726937524.345694631] [UR_Client_Library:]: SCHED_FIFO OK, priority 99
[spawner-4] [INFO] [1726937524.435793817] [spawner_joint_state_broadcaster]: waiting for service /controller_manager/list_controllers to become available...
[spawner-10] [INFO] [1726937524.444587067] [spawner_motion_control_handle]: waiting for service /controller_manager/list_controllers to become available...
[spawner-7] [INFO] [1726937524.454005415] [spawner_cartesian_compliance_controller]: waiting for service /controller_manager/list_controllers to become available...
[spawner-9] [INFO] [1726937524.456813934] [spawner_cartesian_motion_controller]: waiting for service /controller_manager/list_controllers to become available...
[spawner-6] [INFO] [1726937524.464223389] [spawner_scaled_joint_trajectory_controller]: waiting for service /controller_manager/list_controllers to become available...
[spawner-5] [INFO] [1726937524.476934121] [spawner_force_torque_sensor_broadcaster]: waiting for service /controller_manager/list_controllers to become available...
[spawner-8] [INFO] [1726937524.482148366] [spawner_cartesian_force_controller]: waiting for service /controller_manager/list_controllers to become available...
[ur_ros2_control_node-2] [INFO] [1726937524.879764442] [UR_Client_Library:]: Negotiated RTDE protocol version to 2.
[ur_ros2_control_node-2] [INFO] [1726937524.879969491] [UR_Client_Library:]: Setting up RTDE communication with frequency 500.000000
[rviz2-1] [INFO] [1726937524.938039147] [rviz2]: Stereo is NOT SUPPORTED
[rviz2-1] [INFO] [1726937524.938201709] [rviz2]: OpenGl version: 4.6 (GLSL 4.6)
[rviz2-1] [INFO] [1726937524.964816168] [rviz2]: Stereo is NOT SUPPORTED
[ur_ros2_control_node-2] [INFO] [1726937525.911400432] [URPositionHardwareInterface]: Calibration checksum: 'calib_9285162873390146301'.
[ur_ros2_control_node-2] [ERROR] [1726937526.998111048] [URPositionHardwareInterface]: The calibration parameters of the connected robot don't match the ones from the given kinematics config file. Please be aware that this can lead to critical inaccuracies of tcp positions. Use the ur_calibration tool to extract the correct calibration from the robot and pass that into the description. See [https://github.com/UniversalRobots/Universal_Robots_ROS2_Driver/blob/main/ur_calibration/README.md] for details.
[ur_ros2_control_node-2] [INFO] [1726937526.998206736] [URPositionHardwareInterface]: System successfully started!
[ur_ros2_control_node-2] [INFO] [1726937526.998244932] [resource_manager]: Successful 'configure' of hardware 'ur10e'
[ur_ros2_control_node-2] [INFO] [1726937526.998315277] [resource_manager]: 'activate' hardware 'ur10e'
[ur_ros2_control_node-2] [INFO] [1726937526.998324096] [URPositionHardwareInterface]: Activating HW interface
[ur_ros2_control_node-2] [INFO] [1726937526.998333499] [resource_manager]: Successful 'activate' of hardware 'ur10e'
[ur_ros2_control_node-2] [INFO] [1726937527.007380655] [UR_Client_Library:]: SCHED_FIFO OK, priority 99
[ur_ros2_control_node-2] [INFO] [1726937527.200522938] [controller_manager]: Loading controller 'joint_state_broadcaster'
[spawner-4] [INFO] [1726937527.218783402] [spawner_joint_state_broadcaster]: Loaded joint_state_broadcaster
[ur_ros2_control_node-2] [INFO] [1726937527.220096992] [controller_manager]: Loading controller 'cartesian_compliance_controller'
[spawner-7] [INFO] [1726937527.238883472] [spawner_cartesian_compliance_controller]: Loaded cartesian_compliance_controller
[ur_ros2_control_node-2] [INFO] [1726937527.239004678] [controller_manager]: Loading controller 'motion_control_handle'
[ur_ros2_control_node-2] [INFO] [1726937527.257827283] [controller_manager]: Loading controller 'cartesian_motion_controller'
[spawner-10] [INFO] [1726937527.259176145] [spawner_motion_control_handle]: Loaded motion_control_handle
[ur_ros2_control_node-2] [INFO] [1726937527.277629508] [controller_manager]: Loading controller 'scaled_joint_trajectory_controller'
[spawner-9] [INFO] [1726937527.278533355] [spawner_cartesian_motion_controller]: Loaded cartesian_motion_controller
[ur_ros2_control_node-2] [WARN] [1726937527.294810033] [scaled_joint_trajectory_controller]: [Deprecated]: "allow_nonzero_velocity_at_trajectory_end" is set to true. The default behavior will change to false.
[ur_ros2_control_node-2] [INFO] [1726937527.298326008] [controller_manager]: Loading controller 'force_torque_sensor_broadcaster'
[spawner-6] [INFO] [1726937527.298843148] [spawner_scaled_joint_trajectory_controller]: Loaded scaled_joint_trajectory_controller
[ur_ros2_control_node-2] [INFO] [1726937527.317690070] [controller_manager]: Loading controller 'cartesian_force_controller'
[spawner-5] [INFO] [1726937527.319023890] [spawner_force_torque_sensor_broadcaster]: Loaded force_torque_sensor_broadcaster
[ur_ros2_control_node-2] [INFO] [1726937527.337830651] [controller_manager]: Configuring controller 'joint_state_broadcaster'
[ur_ros2_control_node-2] [INFO] [1726937527.337954868] [joint_state_broadcaster]: 'joints' or 'interfaces' parameter is empty. All available state interfaces will be published
[spawner-8] [INFO] [1726937527.338770995] [spawner_cartesian_force_controller]: Loaded cartesian_force_controller
[ur_ros2_control_node-2] [INFO] [1726937527.348455437] [controller_manager]: Configuring controller 'cartesian_compliance_controller'
[ur_ros2_control_node-2] [INFO] [1726937527.352331508] [cartesian_compliance_controller]: Forward dynamics solver initialized
[ur_ros2_control_node-2] [INFO] [1726937527.352377809] [cartesian_compliance_controller]: Forward dynamics solver has control over 6 joints
[ur_ros2_control_node-2] [INFO] [1726937527.367767840] [controller_manager]: Configuring controller 'motion_control_handle'
[ur_ros2_control_node-2] [INFO] [1726937527.377825489] [controller_manager]: Configuring controller 'cartesian_motion_controller'
[ur_ros2_control_node-2] [INFO] [1726937527.381509625] [cartesian_motion_controller]: Forward dynamics solver initialized
[ur_ros2_control_node-2] [INFO] [1726937527.381553570] [cartesian_motion_controller]: Forward dynamics solver has control over 6 joints
[ur_ros2_control_node-2] [INFO] [1726937527.387810098] [controller_manager]: Configuring controller 'scaled_joint_trajectory_controller'
[ur_ros2_control_node-2] [INFO] [1726937527.388060241] [scaled_joint_trajectory_controller]: No specific joint names are used for command interfaces. Using 'joints' parameter.
[ur_ros2_control_node-2] [INFO] [1726937527.388092379] [scaled_joint_trajectory_controller]: Command interfaces are [position] and state interfaces are [position velocity].
[ur_ros2_control_node-2] [INFO] [1726937527.388124216] [scaled_joint_trajectory_controller]: Using 'splines' interpolation method.
[ur_ros2_control_node-2] [INFO] [1726937527.389307473] [scaled_joint_trajectory_controller]: Controller state will be published at 100.00 Hz.
[ur_ros2_control_node-2] [INFO] [1726937527.391797601] [scaled_joint_trajectory_controller]: Action status changes will be monitored at 20.00 Hz.
[ur_ros2_control_node-2] [INFO] [1726937527.408480558] [controller_manager]: Configuring controller 'force_torque_sensor_broadcaster'
[ur_ros2_control_node-2] [INFO] [1726937527.417865789] [controller_manager]: Configuring controller 'cartesian_force_controller'
[ur_ros2_control_node-2] [INFO] [1726937527.423138579] [cartesian_force_controller]: Forward dynamics solver initialized
[ur_ros2_control_node-2] [INFO] [1726937527.423192963] [cartesian_force_controller]: Forward dynamics solver has control over 6 joints
[spawner-4] [INFO] [1726937527.459185953] [spawner_joint_state_broadcaster]: Configured and activated joint_state_broadcaster
[spawner-6] [INFO] [1726937527.478727930] [spawner_scaled_joint_trajectory_controller]: Configured and activated scaled_joint_trajectory_controller
[spawner-5] [INFO] [1726937527.498737950] [spawner_force_torque_sensor_broadcaster]: Configured and activated force_torque_sensor_broadcaster
[INFO] [spawner-7]: process has finished cleanly [pid 25786]
[INFO] [spawner-10]: process has finished cleanly [pid 25810]
[INFO] [spawner-9]: process has finished cleanly [pid 25790]
[INFO] [spawner-8]: process has finished cleanly [pid 25788]
[INFO] [spawner-4]: process has finished cleanly [pid 25780]
[INFO] [spawner-6]: process has finished cleanly [pid 25784]
[INFO] [spawner-5]: process has finished cleanly [pid 25782]
[ur_ros2_control_node-2] [ERROR] [1726937549.817410257] [controller_manager]: Resource conflict for controller 'cartesian_force_controller'. Command interface 'shoulder_pan_joint/position' is already claimed.
user@msi:~/git/cartesian_controllers$ ros2 control list_controllers
force_torque_sensor_broadcaster force_torque_sensor_broadcaster/ForceTorqueSensorBroadcaster active
joint_state_broadcaster joint_state_broadcaster/JointStateBroadcaster active
scaled_joint_trajectory_controller ur_controllers/ScaledJointTrajectoryController inactive
motion_control_handle cartesian_controller_handles/MotionControlHandle inactive
cartesian_motion_controller cartesian_motion_controller/CartesianMotionController inactive
cartesian_force_controller cartesian_force_controller/CartesianForceController active
cartesian_compliance_controller cartesian_compliance_controller/CartesianComplianceController inactive
user@msi:~/git/cartesian_controllers$ ros2 control switch_controllers --activate cartesian_force_controller --deactivate scaled_joint_trajectory_controller
Successfully switched controllers
user@msi:~/git/cartesian_controllers$ ros2 control list_controllers
force_torque_sensor_broadcaster force_torque_sensor_broadcaster/ForceTorqueSensorBroadcaster active
joint_state_broadcaster joint_state_broadcaster/JointStateBroadcaster active
scaled_joint_trajectory_controller ur_controllers/ScaledJointTrajectoryController inactive
motion_control_handle cartesian_controller_handles/MotionControlHandle inactive
cartesian_motion_controller cartesian_motion_controller/CartesianMotionController inactive
cartesian_force_controller cartesian_force_controller/CartesianForceController active
cartesian_compliance_controller cartesian_compliance_controller/CartesianComplianceController inactive
wgates@msi:~/git/cartesian_controllers$
1 Like