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

Blocked on Wait for device to boot. during launch of robot with ros2_canopen ros2 control system #5

Open
BatisteAll opened this issue Oct 30, 2024 · 0 comments

Comments

@BatisteAll
Copy link

The Problem
Everything compiles smoothly, but when I launch the robot, the ros2 control node stays blocked on "wait for device to boot" and nothing follows. It happens after the master has been instantiated, so it happens during the activation of the first slave node corresponding to the first joint.
This is related to this issue.

Setup:

  • OS: Ubuntu 22.04
  • ROS-Distro: Humble
  • Branch/Commit: ros2_canopen Humble

To Reproduce
Here are the exact steps I follow to get the error with virtual can:

  1. mkdir ~/ros2_canopen_ws/src
  2. cd ~/ros2_canopen_ws/src
  3. git clone [email protected]:ros-industrial/ros2_canopen.git
  4. git clone [email protected]:hellantos/prbt_robot.git
  5. cd ros2_canopen
  6. git checkout humble
  7. cd ../../
  8. colcon build
  9. source install/setup.bash
  10. --> Set up the vcan0 in another terminal and set up candump as well
  11. ros2 launch prbt_robot_moveit_config moveit_planning_execution.launch.py can_interface_name:=vcan0

The log from here is the following.
I just erased the logs related to moveit that are not relevant here.

1730279258.8199034 [INFO] [launch]: All log files can be found below /home/spacefactory5/.ros/log/2024-10-30-10-07-38-809859-spacefactory5ADS-37791
1730279258.8199837 [INFO] [launch]: Default logging verbosity is set to INFO
1730279259.7005184 [INFO] [robot_state_publisher-1]: process started with pid [37795]
1730279259.7006462 [INFO] [ros2_control_node-2]: process started with pid [37797]
1730279259.7006960 [INFO] [spawner-3]: process started with pid [37799]
1730279259.7007334 [INFO] [spawner-4]: process started with pid [37801]
1730279259.7007656 [INFO] [spawner-5]: process started with pid [37803]
1730279259.7379291 [ros2_control_node-2] [WARN] [1730279259.737610266] [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.
1730279259.7382877 [ros2_control_node-2] [INFO] [1730279259.737779725] [resource_manager]: Loading hardware 'prbt_' 
1730279259.7387958 [robot_state_publisher-1] [INFO] [1730279259.738657820] [robot_state_publisher]: got segment prbt_base
1730279259.7390254 [robot_state_publisher-1] [INFO] [1730279259.738706448] [robot_state_publisher]: got segment prbt_base_link
1730279259.7390990 [robot_state_publisher-1] [INFO] [1730279259.738711379] [robot_state_publisher]: got segment prbt_flange
1730279259.7391603 [robot_state_publisher-1] [INFO] [1730279259.738714238] [robot_state_publisher]: got segment prbt_link_1
1730279259.7392194 [robot_state_publisher-1] [INFO] [1730279259.738716615] [robot_state_publisher]: got segment prbt_link_2
1730279259.7392738 [robot_state_publisher-1] [INFO] [1730279259.738718933] [robot_state_publisher]: got segment prbt_link_3
1730279259.7393293 [robot_state_publisher-1] [INFO] [1730279259.738721182] [robot_state_publisher]: got segment prbt_link_4
1730279259.7393830 [robot_state_publisher-1] [INFO] [1730279259.738723648] [robot_state_publisher]: got segment prbt_link_5
1730279259.7394361 [robot_state_publisher-1] [INFO] [1730279259.738725988] [robot_state_publisher]: got segment prbt_tool0
1730279259.7394919 [robot_state_publisher-1] [INFO] [1730279259.738728255] [robot_state_publisher]: got segment world
1730279259.7449474 [ros2_control_node-2] [INFO] [1730279259.744800638] [resource_manager]: Initialize hardware 'prbt_' 
1730279259.7452121 [ros2_control_node-2] [INFO] [1730279259.744933397] [prbt__interface]: Registering hardware interface 'prbt_'
1730279259.7452812 [ros2_control_node-2] [INFO] [1730279259.744962057] [prbt__interface]: 'prbt_' has bus config: '~/ros2_canopen_test_ws/install/prbt_robot_support/share/prbt_robot_support/config/prbt/bus.yml'
1730279259.7453394 [ros2_control_node-2] [INFO] [1730279259.744965697] [prbt__interface]: 'prbt_' has master config: '~/ros2_canopen_test_ws/install/prbt_robot_support/share/prbt_robot_support/config/prbt/master.dcf'
1730279259.7453935 [ros2_control_node-2] [INFO] [1730279259.744971116] [prbt__interface]: 'prbt_' has master bin: ''
1730279259.7454457 [ros2_control_node-2] [INFO] [1730279259.744973650] [prbt__interface]: 'prbt_' has can interface: 'vcan0'
1730279259.7464330 [ros2_control_node-2] [INFO] [1730279259.746281347] [prbt_joint_1]: Node id for 'prbt_joint_1' is '3'
1730279259.7465014 [ros2_control_node-2] [INFO] [1730279259.746305317] [prbt_joint_1]: Registered position_mode '7' for 'prbt_joint_1'
1730279259.7469022 [ros2_control_node-2] [INFO] [1730279259.746799291] [prbt_joint_2]: Node id for 'prbt_joint_2' is '4'
1730279259.7469699 [ros2_control_node-2] [INFO] [1730279259.746807279] [prbt_joint_2]: Registered position_mode '7' for 'prbt_joint_2'
1730279259.7472870 [ros2_control_node-2] [INFO] [1730279259.747186581] [prbt_joint_3]: Node id for 'prbt_joint_3' is '5'
1730279259.7473516 [ros2_control_node-2] [INFO] [1730279259.747193185] [prbt_joint_3]: Registered position_mode '7' for 'prbt_joint_3'
1730279259.7476733 [ros2_control_node-2] [INFO] [1730279259.747567243] [prbt_joint_4]: Node id for 'prbt_joint_4' is '6'
1730279259.7477398 [ros2_control_node-2] [INFO] [1730279259.747574862] [prbt_joint_4]: Registered position_mode '7' for 'prbt_joint_4'
1730279259.7480450 [ros2_control_node-2] [INFO] [1730279259.747944601] [prbt_joint_5]: Node id for 'prbt_joint_5' is '7'
1730279259.7481089 [ros2_control_node-2] [INFO] [1730279259.747950739] [prbt_joint_5]: Registered position_mode '7' for 'prbt_joint_5'
1730279259.7484236 [ros2_control_node-2] [INFO] [1730279259.748324983] [prbt_joint_6]: Node id for 'prbt_joint_6' is '8'
1730279259.7484868 [ros2_control_node-2] [INFO] [1730279259.748330805] [prbt_joint_6]: Registered position_mode '7' for 'prbt_joint_6'
1730279259.7486999 [ros2_control_node-2] [INFO] [1730279259.748412938] [resource_manager]: Successful initialization of hardware 'prbt_'
1730279259.7487700 [ros2_control_node-2] [INFO] [1730279259.748556528] [resource_manager]: 'configure' hardware 'prbt_' 
1730279259.7519283 [ros2_control_node-2] [INFO] [1730279259.751767662] [device_container]: Starting Device Container with:
1730279259.7520216 [ros2_control_node-2] [INFO] [1730279259.751793587] [device_container]: 	 can_interface_name vcan0
1730279259.7520773 [ros2_control_node-2] [INFO] [1730279259.751797598] [device_container]: 	 master_config ~/ros2_canopen_test_ws/install/prbt_robot_support/share/prbt_robot_support/config/prbt/master.dcf
1730279259.7521310 [ros2_control_node-2] [INFO] [1730279259.751802363] [device_container]: 	 bus_config ~/ros2_canopen_test_ws/install/prbt_robot_support/share/prbt_robot_support/config/prbt/bus.yml
1730279259.7525611 [ros2_control_node-2] [INFO] [1730279259.752447527] [device_container]: Loading Master Configuration.
1730279259.7529395 [ros2_control_node-2] [INFO] [1730279259.752703486] [device_container]: Load Library: ~/ros2_canopen_test_ws/install/canopen_master_driver/lib/libmaster_driver.so
1730279259.7540939 [ros2_control_node-2] [INFO] [1730279259.753923139] [device_container]: Found class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::MasterDriver>
1730279259.7541566 [ros2_control_node-2] [INFO] [1730279259.753933516] [device_container]: Instantiate class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::MasterDriver>
1730279259.7557971 [ros2_control_node-2] [INFO] [1730279259.755579908] [master]: NodeCanopenBasicMaster
1730279259.7558575 [ros2_control_node-2] [INFO] [1730279259.755656614] [device_container]: Load master component.
1730279259.7559757 [ros2_control_node-2] [INFO] [1730279259.755733552] [device_container]: Added /master to executor
1730279259.7570848 [ros2_control_node-2] [WARN] [1730279259.756887075] [master]: No timeout parameter found in config file. Using default value of 100ms.
1730279259.7571471 [ros2_control_node-2] [INFO] [1730279259.756908078] [master]: Master boot timeout set to 2000ms.
1730279259.7690110 [ros2_control_node-2] [INFO] [1730279259.768685278] [device_container]: Loading Driver Configuration.
1730279259.7691073 [ros2_control_node-2] [INFO] [1730279259.768761356] [device_container]: Found device prbt_joint_1 with driver ros2_canopen::Cia402Driver
1730279259.7692678 [ros2_control_node-2] [INFO] [1730279259.769025375] [device_container]: Load Library: ~/ros2_canopen_test_ws/install/canopen_402_driver/lib/libcia402_driver.so
1730279259.7696745 [ros2_control_node-2] [INFO] [1730279259.769523725] [device_container]: Found class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::Cia402Driver>
1730279259.7697356 [ros2_control_node-2] [INFO] [1730279259.769551602] [device_container]: Instantiate class: rclcpp_components::NodeFactoryTemplate<ros2_canopen::Cia402Driver>
1730279259.7716837 [ros2_control_node-2] [INFO] [1730279259.771472767] [device_container]: Load driver component.
1730279259.7717454 [ros2_control_node-2] [INFO] [1730279259.771589889] [device_container]: Added /prbt_joint_1 to executor
1730279259.7788882 [ros2_control_node-2] [INFO] [1730279259.778762861] [prbt_joint_1]: Non transmit timeout100ms
1730279259.7790580 [ros2_control_node-2] [WARN] [1730279259.778807838] [prbt_joint_1]: Could not polling from config, setting to true.
1730279259.7791061 [ros2_control_node-2] [WARN] [1730279259.778851563] [prbt_joint_1]: Could not read enable diagnostics from config, setting to false.
1730279259.7792001 [ros2_control_node-2] [INFO] [1730279259.778981470] [prbt_joint_1]: scale_pos_to_dev_ 57295.779513
1730279259.7792294 [ros2_control_node-2] scale_pos_from_dev_ 0.000017
1730279259.7792530 [ros2_control_node-2] scale_vel_to_dev_ 1000.000000
1730279259.7792735 [ros2_control_node-2] scale_vel_from_dev_ 0.001000
1730279259.7792923 [ros2_control_node-2] 
1730279259.7800233 [ros2_control_node-2] [INFO] [1730279259.779944135] [prbt_joint_1]: eds file ~/ros2_canopen_test_ws/install/prbt_robot_support/share/prbt_robot_support/config/prbt/prbt_0_1.dcf
1730279259.7800689 [ros2_control_node-2] [INFO] [1730279259.779957108] [prbt_joint_1]: bin file ~/ros2_canopen_test_ws/install/prbt_robot_support/share/prbt_robot_support/config/prbt/prbt_joint_1.bin
1730279259.7823596 [ros2_control_node-2] Found rpdo mapped object: index=6040 subindex=0
1730279259.7823942 [ros2_control_node-2] Found rpdo mapped object: index=6060 subindex=0
1730279259.7824168 [ros2_control_node-2] Found rpdo mapped object: index=60c1 subindex=1
1730279259.7824373 [ros2_control_node-2] Found rpdo mapped object: index=607a subindex=0
1730279259.7824562 [ros2_control_node-2] Found rpdo mapped object: index=6081 subindex=0
1730279259.7825449 [ros2_control_node-2] Found tpdo mapped object: index=6041 subindex=0
1730279259.7825727 [ros2_control_node-2] Found tpdo mapped object: index=6061 subindex=0
1730279259.7826018 [ros2_control_node-2] Found tpdo mapped object: index=6064 subindex=0
1730279259.7826216 [ros2_control_node-2] Found tpdo mapped object: index=6064 subindex=0
1730279259.7826402 [ros2_control_node-2] Found tpdo mapped object: index=606c subindex=0
1730279259.7826586 [ros2_control_node-2] Found tpdo mapped object: index=6064 subindex=0
1730279259.7826762 [ros2_control_node-2] Found tpdo mapped object: index=606c subindex=0
1730279259.7827699 [ros2_control_node-2] [WARN] [1730279259.782516258] [prbt_joint_1]: Wait for device to boot.
1730279260.2205434 [spawner-3] [INFO] [1730279260.220274738] [spawner_joint_state_broadcaster]: waiting for service /controller_manager/list_controllers to become available...
1730279260.2208011 [spawner-5] [INFO] [1730279260.220279071] [spawner_arm_controller]: waiting for service /controller_manager/list_controllers to become available...
1730279260.2241638 [spawner-4] [INFO] [1730279260.224024318] [spawner_forward_position_controller]: waiting for service /controller_manager/list_controllers to become available...
1730279269.7703915 [INFO] [static_transform_publisher-6]: process started with pid [37915]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant