Closed y-masutani closed 4 months ago
I missed the message about ros2_control_node in the launch screen output as follows
[ros2_control_node-1] [WARN] [1707454373.341672747] [rcl.logging_rosout]: Publisher already registered for provided node name. If this is due to multiple nodes with the same name then all logs for that logger name will go out over the existing publisher. As soon as any node with that name is destructed it will unregister the publisher, preventing any further logs for that name from being published on the rosout topic.
[ros2_control_node-1] [FATAL] [1707454373.352680649] [controller_manager]: System cannot communicate with servo motors. Error message: Permission denied
[ros2_control_node-1] terminate called after throwing an instance of 'std::runtime_error'
[ros2_control_node-1] what(): Failed to configure 'hsrb'
It seems to contain two problems.
How do I solve tem?
I followed the code and found that the servo's device file is /dev/ttyCTI2
.
https://github.com/hsr-project/hsrb_robot_hardware/blob/main/src/hsrb_robot_hardware/hsrb_hw.cpp#L43
ls -l /dev/ttyCTI2
crw-rw---- 1 root dialout 234, 2 2月 9 08:21 /dev/ttyCTI2
I ran the following, but it did not make any difference.
sudo adduser masutani dialout
where masutani
is my user name.
I did the following, then ros2_control_node
is not dead.
sudo chmod a+rw /dev/ttyCTI2
Is this procedure appropriate?
Was the user "masutani" created using the adduser command? If a user was created with the adduser command, the user should have the necessary permissions. https://docs.hsr.io/hsrc_user_manual_en/howto/pc_setup_for_robot.html#id10
Yes. I used adduser command to create the account.
How can I check my permission on HSR? I checked /etc/groups and tried add my account to some groups.
The added user should have the following permissions. You can check this by using the 'groups' command while logged in as that user.
dialaout, audio, video, plugdev, pulse, realtime-control, gpio
Today I used the groups command to see which groups my account belongs to.
$ groups
masutani dialout sudo audio video plugdev pulse realtime-control gpio
I checked /dev/ttyCTI2.
$ ls -l /dev/ttyCTI2
crw-rw---- 1 root dialout 234, 2 2月 13 09:24 /dev/ttyCTI2
The permissions on /dev/ttyCTI2 were restored.
But, I stopped docker.hsrb.roscore.service
, released the stop button, and executed the following command,
$ ros2 launch hsrb_bringup hsrb.launch.py
Then I confirmed that ros2_control_node did not die, that the HSR arm worked through action communication, and that the camera nodes published Image topic.
I can't tell the difference from the last time.
After the install described in issue #5, I stopped
docker.hsrb.roscore.service
, released the stop button, and executed the following command,However, an error appeared immediately.
The ros2_control_node died.
How can I check to solve this?