UniversalRobots / Universal_Robots_ROS_Driver

Universal Robots ROS driver supporting CB3 and e-Series
Apache License 2.0
741 stars 398 forks source link

Compile error: name 'tool_contact' is not defined #683

Closed MagicBY closed 4 months ago

MagicBY commented 8 months ago

Affected ROS Driver version(s)

Universal_Robots_ROS_driver

Used ROS distribution.

Noetic

Which combination of platform is the ROS driver running on.

Linux

How is the UR ROS Driver installed.

Build the driver from source and using the UR Client Library from binary

Which robot platform is the driver connected to.

UR CB3 robot

Robot SW / URSim version(s)

none

How is the ROS driver used.

Through the robot teach pendant using External Control URCap

Issue details

Summary

I am running remoteROScontrol.urcap file, when I press the play button on the teaching pendant, the error message shows that "Compile error: name 'tool_contact' is not defined"

Steps to Reproduce

I connected the pc and CB3 robot using a WAN cable. I was able to ping the robot's IP address on my pc, proving that the connection works fine.

I disabled the Ethernet/IP or Profinet fieldbus feature

Then I launch the ur3_bringup.launch file on my pc, here is what shown on the command window. boyu@boyu:~/catkin_ws$ roslaunch ur_robot_driver ur3_bringup.launch robot_ip:=192.168.1.10 kinematics_config:=/home/boyu/catkin_ws/src/UR3_resources/ur3_calibration_lab.yaml ... logging to /home/boyu/.ros/log/986a2046-b541-11ee-a103-1d9f8af5ffd7/roslaunch-boyu-20898.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.

Using load_yaml() directly is deprecated. Use xacro.load_yaml() instead. Using load_yaml() directly is deprecated. Use xacro.load_yaml() instead. Using load_yaml() directly is deprecated. Use xacro.load_yaml() instead. Using load_yaml() directly is deprecated. Use xacro.load_yaml() instead. started roslaunch server http://boyu:43253/

SUMMARY

PARAMETERS

NODES / controller_stopper (controller_stopper/node) robot_state_publisher (robot_state_publisher/robot_state_publisher) ros_control_controller_spawner (controller_manager/spawner) ros_control_stopped_spawner (controller_manager/spawner) ur_hardware_interface (ur_robot_driver/ur_robot_driver_node) /ur_hardware_interface/ ur_robot_state_helper (ur_robot_driver/robot_state_helper)

auto-starting new master process[master]: started with pid [20909] ROS_MASTER_URI=http://localhost:11311

setting /run_id to 986a2046-b541-11ee-a103-1d9f8af5ffd7 process[rosout-1]: started with pid [20919] started core service [/rosout] process[robot_state_publisher-2]: started with pid [20926] process[ur_hardware_interface-3]: started with pid [20927] process[ros_control_controller_spawner-4]: started with pid [20928] process[ros_control_stopped_spawner-5]: started with pid [20929] process[controller_stopper-6]: started with pid [20930] process[ur_hardware_interface/ur_robot_state_helper-7]: started with pid [20940] [ INFO] [1705500383.708751576]: Initializing dashboard client [ INFO] [1705500383.711136561]: Waiting for controller manager service to come up on /controller_manager/switch_controller [ INFO] [1705500383.711543451]: Connected: Universal Robots Dashboard Server

[ INFO] [1705500383.711754486]: waitForService: Service [/controller_manager/switch_controller] has not been advertised, waiting... [ INFO] [1705500383.720178504]: Initializing urdriver [ WARN] [1705500383.721597865]: Your system/user seems not to be setup for FIFO scheduling. We recommend using a lowlatency kernel with FIFO scheduling. See https://github.com/UniversalRobots/Universal_Robots_ROS_Driver/blob/master/ur_robot_driver/doc/real_time.md for details. [INFO] [1705500383.865192]: Controller Spawner: Waiting for service controller_manager/load_controller [ INFO] [1705500383.963253002]: Negotiated RTDE protocol version to 2. [ INFO] [1705500383.964066054]: Setting up RTDE communication with frequency 125.000000 [INFO] [1705500383.977334]: Controller Spawner: Waiting for service controller_manager/load_controller [ INFO] [1705500384.999151329]: Checking if calibration data matches connected robot. [ INFO] [1705500386.095446072]: Calibration checked successfully. [ WARN] [1705500386.117677757]: Your system/user seems not to be setup for FIFO scheduling. We recommend using a lowlatency kernel with FIFO scheduling. See https://github.com/UniversalRobots/Universal_Robots_ROS_Driver/blob/master/ur_robot_driver/doc/real_time.md for details. [ INFO] [1705500386.117857204]: Loaded ur_robot_driver hardware_interface [ INFO] [1705500386.156346908]: waitForService: Service [/controller_manager/switch_controller] is now available. [ INFO] [1705500386.156364395]: Service available. [ INFO] [1705500386.156373282]: Waiting for controller list service to come up on /controller_manager/list_controllers [ INFO] [1705500386.156795790]: Service available. [INFO] [1705500386.284543]: Controller Spawner: Waiting for service controller_manager/switch_controller [INFO] [1705500386.285994]: Controller Spawner: Waiting for service controller_manager/unload_controller [INFO] [1705500386.287278]: Loading controller: pos_joint_traj_controller [INFO] [1705500386.309851]: Loading controller: joint_group_vel_controller [INFO] [1705500386.317823]: Controller Spawner: Loaded controllers: pos_joint_traj_controller, joint_group_vel_controller [ INFO] [1705500386.368584280]: Robot mode is now RUNNING [ INFO] [1705500386.369191069]: Robot's safety mode is now NORMAL [INFO] [1705500386.403471]: Controller Spawner: Waiting for service controller_manager/switch_controller [INFO] [1705500386.405073]: Controller Spawner: Waiting for service controller_manager/unload_controller [INFO] [1705500386.406506]: Loading controller: cartesian_velocity_controller --------------------> name_space: /cartesian_velocity_controller [ INFO] [1705500386.410337735]: Successfully parsed urdf file [ INFO] [1705500386.410464902]: tip_name: wrist_3_link [ INFO] [1705500386.410492706]: root_name: base_link [ INFO] [1705500386.410521676]: Number of segments: 6 [ INFO] [1705500386.410550703]: Number of joints in chain: 6 [ INFO] [1705500386.410561646]: segment(0): shoulder_link [ INFO] [1705500386.410569123]: segment(1): upper_arm_link [ INFO] [1705500386.410580072]: segment(2): forearm_link [ INFO] [1705500386.410591962]: segment(3): wrist_1_link [ INFO] [1705500386.410603545]: segment(4): wrist_2_link [ INFO] [1705500386.410616096]: segment(5): wrist_3_link [ INFO] [1705500386.410632839]: Getting limits for joint: wrist_3_joint [ INFO] [1705500386.410647538]: Getting limits for joint: wrist_2_joint [ INFO] [1705500386.410657484]: Getting limits for joint: wrist_1_joint [ INFO] [1705500386.410669049]: Getting limits for joint: elbow_joint [ INFO] [1705500386.410715862]: Getting limits for joint: shoulder_lift_joint [ INFO] [1705500386.410726855]: Getting limits for joint: shoulder_pan_joint [ INFO] [1705500386.410740150]: Getting joint handles [ INFO] [1705500386.410756451]: shoulder_pan_joint type: RotAxis [ INFO] [1705500386.410775793]: shoulder_lift_joint type: RotAxis [ INFO] [1705500386.410826328]: elbow_joint type: RotAxis [ INFO] [1705500386.410838974]: wrist_1_joint type: RotAxis [ INFO] [1705500386.410852020]: wrist_2_joint type: RotAxis [ INFO] [1705500386.410865316]: wrist_3_joint type: RotAxis [ INFO] [1705500386.410880050]: Number of joints in handle = 6 [ INFO] [1705500386.410891178]: kdl_chain.getNrOfJoints: 6 [ INFO] [1705500386.410898961]: Finished Kinematic Base init [INFO] [1705500386.413713]: Loading controller: joint_state_controller [INFO] [1705500386.421755]: Loading controller: force_torque_sensor_controller [INFO] [1705500386.429760]: Controller Spawner: Loaded controllers: cartesian_velocity_controller, joint_state_controller, force_torque_sensor_controller [INFO] [1705500386.437635]: Started controllers: cartesian_velocity_controller, joint_state_controller, force_torque_sensor_controller [ INFO] [1705500390.611482761]: Robot requested program [ INFO] [1705500390.611539799]: Sent program to robot

Then I press the play button on the teaching pendant, it showed "Compile error: name 'tool_contact' is not defined".

play

I tried to search for the variable "tool_contact" in all the files relate to the ur3_bringup.launch file, but I cannot find it. I am looking forward to advice on how to diagnose this issue and how to solve them. Thanks

Relevant log output

No response

Accept Public visibility

urrsk commented 6 months ago

You are most likely using a software version for the robot that is pretty old. Please update the robot Software to the latest version or at least one equal or later than 3.14.3, See https://github.com/UniversalRobots/Universal_Robots_Client_Library?tab=readme-ov-file#requirements

You can download the update from: https://www.universal-robots.com/download/?filters[]=98763&query=

MagicBY commented 4 months ago

It worked after I upgraded the system. Thanks @urrsk

fmauch commented 4 months ago

Glad to hear that!