-
Notifications
You must be signed in to change notification settings - Fork 31
Description
Error when running task 7 solution with command below:
ros2 launch controlko_bringup rrbot.launch.py use_mock_hardware:=false
[INFO] [launch]: All log files can be found below /home/wmiii/.ros/log/2023-06-30-18-59-15-063098-wmiii-desktop-273062
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [ros2_control_node-1]: process started with pid [273065]
[INFO] [robot_state_publisher-2]: process started with pid [273067]
[ros2_control_node-1] [INFO] [1688122755.844726183] [resource_manager]: Loading hardware 'rrbot'
[ros2_control_node-1] [INFO] [1688122755.845473834] [resource_manager]: Initialize hardware 'rrbot'
[ros2_control_node-1] [INFO] [1688122755.845807885] [resource_manager]: Successful initialization of hardware 'rrbot'
[ros2_control_node-1] terminate called after throwing an instance of 'std::runtime_error'
[ros2_control_node-1] what(): Wrong state or command interface configuration.
[ros2_control_node-1] missing state interfaces:
[ros2_control_node-1]
[ros2_control_node-1] missing command interfaces:
[ros2_control_node-1] ' flange_gpios/digital_out_1 ' ' flange_gpios/digital_out_2 '
After changing info_.sensors[0] to info_.gpios[0] in the codes below and build the package, the problem was solved.
https://github.com/ros-controls/roscon2022_workshop/blob/81d162645c7d0cc0d4376fefe49e802e7380e897/controlko_hardware_interface/src/rrbot_hardware_interface.cpp#L113C1-L118C4

